diff options
-rwxr-xr-x | configure | 18 | ||||
-rw-r--r-- | configure.ac | 2 | ||||
-rw-r--r-- | configure.ac.pamphlet | 2 | ||||
-rw-r--r-- | src/ChangeLog | 5 | ||||
-rw-r--r-- | src/interp/buildom.boot | 29 | ||||
-rw-r--r-- | src/interp/clam.boot | 1 |
6 files changed, 40 insertions, 17 deletions
@@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.60 for OpenAxiom 1.2.0-2008-03-28. +# Generated by GNU Autoconf 2.60 for OpenAxiom 1.2.0-2008-03-30. # # Report bugs to <open-axiom-bugs@lists.sf.net>. # @@ -713,8 +713,8 @@ SHELL=${CONFIG_SHELL-/bin/sh} # Identity of this package. PACKAGE_NAME='OpenAxiom' PACKAGE_TARNAME='openaxiom' -PACKAGE_VERSION='1.2.0-2008-03-28' -PACKAGE_STRING='OpenAxiom 1.2.0-2008-03-28' +PACKAGE_VERSION='1.2.0-2008-03-30' +PACKAGE_STRING='OpenAxiom 1.2.0-2008-03-30' PACKAGE_BUGREPORT='open-axiom-bugs@lists.sf.net' ac_unique_file="src/Makefile.pamphlet" @@ -1399,7 +1399,7 @@ if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures OpenAxiom 1.2.0-2008-03-28 to adapt to many kinds of systems. +\`configure' configures OpenAxiom 1.2.0-2008-03-30 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1469,7 +1469,7 @@ fi if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of OpenAxiom 1.2.0-2008-03-28:";; + short | recursive ) echo "Configuration of OpenAxiom 1.2.0-2008-03-30:";; esac cat <<\_ACEOF @@ -1573,7 +1573,7 @@ fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -OpenAxiom configure 1.2.0-2008-03-28 +OpenAxiom configure 1.2.0-2008-03-30 generated by GNU Autoconf 2.60 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, @@ -1587,7 +1587,7 @@ cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by OpenAxiom $as_me 1.2.0-2008-03-28, which was +It was created by OpenAxiom $as_me 1.2.0-2008-03-30, which was generated by GNU Autoconf 2.60. Invocation command line was $ $0 $@ @@ -25757,7 +25757,7 @@ exec 6>&1 # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by OpenAxiom $as_me 1.2.0-2008-03-28, which was +This file was extended by OpenAxiom $as_me 1.2.0-2008-03-30, which was generated by GNU Autoconf 2.60. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -25806,7 +25806,7 @@ Report bugs to <bug-autoconf@gnu.org>." _ACEOF cat >>$CONFIG_STATUS <<_ACEOF ac_cs_version="\\ -OpenAxiom config.status 1.2.0-2008-03-28 +OpenAxiom config.status 1.2.0-2008-03-30 configured by $0, generated by GNU Autoconf 2.60, with options \\"`echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\" diff --git a/configure.ac b/configure.ac index 37794b37..94b25eda 100644 --- a/configure.ac +++ b/configure.ac @@ -1,6 +1,6 @@ sinclude(config/open-axiom.m4) sinclude(config/aclocal.m4) -AC_INIT([OpenAxiom], [1.2.0-2008-03-28], +AC_INIT([OpenAxiom], [1.2.0-2008-03-30], [open-axiom-bugs@lists.sf.net]) AC_CONFIG_AUX_DIR(config) diff --git a/configure.ac.pamphlet b/configure.ac.pamphlet index 4bd7cedc..e973e096 100644 --- a/configure.ac.pamphlet +++ b/configure.ac.pamphlet @@ -1078,7 +1078,7 @@ information: <<Autoconf init>>= sinclude(config/open-axiom.m4) sinclude(config/aclocal.m4) -AC_INIT([OpenAxiom], [1.2.0-2008-03-28], +AC_INIT([OpenAxiom], [1.2.0-2008-03-30], [open-axiom-bugs@lists.sf.net]) @ diff --git a/src/ChangeLog b/src/ChangeLog index 9dccb36a..b032d3f6 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2008-03-30 Gabriel Dos Reis <gdr@cs.tamu.edu> + + * interp/buildom.boot: Cache constructor instantiations. + * interp/clam.boot (haddProp): Update comment. + 2008-03-29 Gabriel Dos Reis <gdr@cs.tamu.edu> Fix SF/1849435. diff --git a/src/interp/buildom.boot b/src/interp/buildom.boot index a78a281b..d696b2bc 100644 --- a/src/interp/buildom.boot +++ b/src/interp/buildom.boot @@ -81,11 +81,17 @@ oldSlotCode: %Short -> %Short oldSlotCode n == 2 * ($FirstParamSlot + n) + Record0 args == + srcArgs := [[":",first a, devaluate rest a] for a in args] + -- if we already have this instantiation in store, just hand it back. + t := lassocShiftWithFunction(srcArgs, + HGET($ConstructorCache,"Record"), "domainEqualList") => + CDRwithIncrement t nargs := #args dom := newShell(nargs + 10) -- JHD added an extra slot to cache EQUAL methods - dom.0 := ["Record", :[[":", first a, devaluate rest a] for a in args]] + dom.0 := ["Record", :srcArgs] dom.1 := ["lookupInTable",dom, [["=",[[$Boolean,"$","$"],:oldSlotCode nargs]], @@ -103,6 +109,8 @@ Record0 args == dom.($FirstParamSlot + nargs + 3) := if nargs <= 2 then [NIL,:NIL] else newShell nargs + -- remember this instantiation for future re-use. + haddProp($ConstructorCache,"Record",srcArgs,[1,:dom]) dom RecordEqual(x,y,dom) == @@ -151,10 +159,13 @@ coerceRe2E(x,source) == -- Want to eventually have the coerce to and from branch types. Union(:args) == + srcArgs := [(a is [":",tag,d] => [":",tag,devaluate d]; devaluate a) + for a in args] + t := lassocShiftWithFunction(srcArgs,HGET($ConstructorCache,"Union"), + "domainEqualList") => CDRwithIncrement t nargs := #args dom := newShell (nargs + 9) - dom.0 := ["Union", :[(if a is [":",tag,domval] then [":",tag,devaluate domval] - else devaluate a) for a in args]] + dom.0 := ["Union", :srcArgs] dom.1 := ["lookupInTable",dom, [["=",[[$Boolean,"$","$"],:oldSlotCode nargs]], @@ -168,6 +179,7 @@ Union(:args) == dom.($FirstParamSlot + nargs) := [function UnionEqual, :dom] dom.($FirstParamSlot + nargs + 1) := [function UnionPrint, :dom] dom.($FirstParamSlot + nargs + 2) := [function Undef, :dom] + haddProp($ConstructorCache,"Union",srcArgs,[1,:dom]) dom UnionEqual(x, y, dom) == @@ -205,9 +217,12 @@ coerceUn2E(x,source) == -- Want to eventually have elt: ($, args) -> target Mapping(:args) == + srcArgs := [devaluate a for a in args] + t := lassocShiftWithFunction(srcArgs,HGET($ConstructorCache,"Mapping"), + "domainEqualList") => CDRwithIncrement t nargs := #args dom := newShell(nargs + 9) - dom.0 := ["Mapping", :[devaluate a for a in args]] + dom.0 := ["Mapping", :srcArgs] dom.1 := ["lookupInTable",dom, [["=",[[$Boolean,"$","$"],:oldSlotCode nargs]], @@ -221,6 +236,7 @@ Mapping(:args) == dom.($FirstParamSlot + nargs) := [function MappingEqual, :dom] dom.($FirstParamSlot + nargs + 1) := [function MappingPrint, :dom] dom.($FirstParamSlot + nargs + 2) := [function Undef, :dom] + haddProp($ConstructorCache,"Mapping",srcArgs,[1,:dom]) dom MappingEqual(x, y, dom) == EQ(x,y) @@ -236,7 +252,9 @@ coerceMap2E(x) == --% Enumeration Enumeration(:"args") == - nargs := #nargs + t := lassocShiftWithFunction(args,HGET($ConstructorCache,"Enumeration"), + "domainEqualList") => CDRwithIncrement t + nargs := #args dom := newShell(nargs + 9) -- JHD added an extra slot to cache EQUAL methods dom.0 := ["Enumeration", :args] @@ -255,6 +273,7 @@ Enumeration(:"args") == dom.($FirstParamSlot + nargs) := [function EnumEqual, :dom] dom.($FirstParamSlot + nargs + 1) := [function createEnum, :dom] dom.($FirstParamSlot + nargs + 2) := [function EnumPrint, :dom] + haddProp($ConstructorCache,"Enumeration",args,[1,:dom]) dom EnumEqual(e1,e2,dom) == diff --git a/src/interp/clam.boot b/src/interp/clam.boot index 0f6b17d4..ff119529 100644 --- a/src/interp/clam.boot +++ b/src/interp/clam.boot @@ -522,7 +522,6 @@ addToConstructorCache(op,args,value) == ['haddProp,'$ConstructorCache,MKQ op,args,['CONS,1,value]] haddProp(ht,op,prop,val) == - --called inside functors (except for union and record types ??) --presently, ht always = $ConstructorCache statRecordInstantiationEvent() if $reportInstantiations = true or $reportEachInstantiation = true then |