2007-04-09 C. Scott Ananian * Support/jutil.jar: New jutil jar file with better assertions in WorkSet: if the objects' hashcodes are changing out from under us we should be able to see it now. 2007-04-07 C. Scott Ananian * Backend/Runtime1/method-root.properties: VMMain.run() is invoked via Thread.run(). * Support/cpvm.jar, Support/reflect-thunk.jar: Update cpvm.jar and reflect-thunk.jar to match runtime. 2007-04-05 C. Scott Ananian * Analysis/Transactions/SyncTransformer.java: Ensure the 'removetrans' option actually removes all the calls to readT/writeT. Print out a summary of the options to SyncTransformer so we can be sure we didn't mistype some command-line arg. 2007-04-03 C. Scott Ananian * Analysis/Transactions/SyncTransformer.java: Fix bogus assertion (didn't update it when I added the new removetrans option). * Backend/Runtime1/method-root.properties, Backend/Runtime1/transact-root.properties: Add the 8859-1 decoders to the transaction roots, as they can be invoked in transactional context under certain circumstances (since they're demand loaded). Also add IllegalMonitorStateException to the roots. * Analysis/Transactions/SyncTransformer.java: Add option to strip out the transactions from the code, so we can see the non-transactional overhead. * Analysis/DomTree.java: Add a cast to work around a javac bug. * Support/jutil.jar: Add more assertions to WorkSet (although the crash we were seeing was probably a JVM bug, not our fault). 2007-03-31 C. Scott Ananian * Analysis/Transactions/SyncTransformer.java: Fix use of FieldOracle (now matches thesis). 2007-03-23 C. Scott Ananian * Analysis/Instr/WeightedSet.java, Support/jutil.jar, Util/MapComparator.java, Util/SortedMapComparator.java: Update to latest version of JUtil. * IR/Quads/Translate.java: Don't merge code paths with different active MONITORENTER instructions. This ensures that each MONITOREXIT is dominated by a single MONITORENTER, which makes synchronization transformations (including transactions) much much easier. * Analysis/Transactions/SyncTransformer.java: Add option to partially turn on the smarter check oracles. * bin/run-java: Emit debugging stuff to stderr, not stdout. * Analysis/Transactions/HoistingCheckOracle.java: Don't allow hoisting over a MONITOREXIT. * Main/Transactions.java: If the harpoon.trans.memopt flag is given, apply memory optimization when building transactionally. * Analysis/Quads/QuadClassHierarchy.java, Backend/Runtime1/init-safe.properties, Backend/Runtime1/method-root.properties: Updates for classpath 0.08's new threading code (see corresponding update for Runtime). 2007-03-13 C. Scott Ananian * Backend/PreciseC/TreeToC.java: Work around bug in gcc-3.4 (and other versions?) which refuses to accept an aliased symbol as a constant in a field declaration. 2007-03-12 C. Scott Ananian * bin/build-precisec: gcc 4.0 and later break FLEX. Don't waste time right now trying to figure out why. * bin/run-java: reflect-thunk.jar has moved in the Runtime. * Support/precisec-makefile.template: Add -fno-unit-at-a-time to precisec makefile to keep gcc from reordering things. * Backend/PreciseC/TreeToC.java: Suppress 'packed' attribute on byte-sized data types to avoid a warning in gcc 4.1. Add 'used' attribute to data structures to try to avoid pruning by gcc 4.1. 2007-02-07 C. Scott Ananian * bin/build-arm-hack, bin/build-arm-pnk, bin/build-precisec, bin/build-roles, bin/build-spec, bin/run-java: Our various build scripts actually have bash dependencies. 2006-01-09 salcianu * Analysis/PA2/AllocSync/AllocSyncOneMethod.java, Analysis/PA2/IntraProc.java, Analysis/PA2/WPPointerAnalysisCompStage.java: small changes for debug * Analysis/PA2/WPPointerAnalysis.java: fixing a bug 2006-01-07 salcianu * Analysis/PA2/AllocSync/WPAllocSyncCompStage.java, Analysis/PA2/Mutation/WPMutationAnalysisCompStage.java: small changes * Backend/Runtime1/init-safe.properties: fixing a small error * bin/build-precisec: if KEEP_ARCHIVE is off, make sure to delete the dir with the generated sources; I assume the .a archive and the sources for it are both relevant for debugging, but irrelevant otherwise * bin/alt-build-spec: changes in Alex\'s script * Support/_202_jess-root-set: commented out an irrelevant line * Backend/Runtime1/init-safe.properties: another change that weas required for classpath-0.08 * Main/SAMain.java: add the initcheck version of each root method to the root set; if we know that a method may be invoked via reflection, then we have to assume that it may be invoked from the initializers. This change makes sure the initcheck version of these methods gets produced. Specjvm98 with classpath could not compile without this change: its static initializers do use reflection ... * Backend/Runtime1/method-root.properties: more comments * Analysis/Quads/InitializerTransform.java: added a public method to get the CHECKED version of a method; used from SAMain to add to the root set a few initcheck methods that may be called via reflection from the static initializers * Analysis/ClassHierarchy.java: small javadoc change * Support/_999_checkit-root-set-classpath: _999_checkit would not compile otherwise 2006-01-05 salcianu * bin/alt-build-spec: fixing a small error * Support/glibj-0.08.zip: new version of glib-0.08.zip that goes around some bug in the InitializerTransform (IT): IT does not handle reflection in static initializers; ideally we need to have a property file with methods invoked via refelction from the static initializers * Support/jpaul.jar: upgraded to a newer version of jpaul * bin/alt-build-spec: Alternative script for building the specjvm98 applications. I'm actually very curious how we were able to compile these applications using the old script (while using the classpath / not sunjdk library). Here is some info, taken from the comments at the beginning of that script: # Alternative build script for the SPECJvm98 applications Unlike in # the original script, the entry point for each application $s (e.g., # _200_check) is the class spec.benchmarks.$s.Main # # MOTIVATION: the original script causes a lot of unused awt classes # to be compiled ... and the Flex runtime does not support any # graphics. In particular, the produced executable fails during the # execution of *all* class initializers, when the static initializers # of some (otherwise unused) awt classes are invoked. 2005-12-10 salcianu * Util/LightBasicBlocks/SCCLBBFactory.java, Analysis/CallGraph.java, Analysis/MemOpt/Util.java, Analysis/MetaMethods/MetaCallGraph.java, Analysis/MetaMethods/MetaCallGraphImpl.java, Analysis/PA2/AllocSync/LoopDetector.java, Analysis/PA2/WPPointerAnalysis.java, Analysis/PointerAnalysis/PointerAnalysis.java, Support/jpaul.jar: many small changes to accomodate a class name change in jpaul's interface: j. Bloch's talk to MIT did not remain without consequences: next day Adam submitted 10 name change suggestions 2005-12-01 salcianu * Analysis/DataFlow/InstrSolver.java, Analysis/MemOpt/Util.java, Analysis/MetaMethods/MetaCallGraphImpl.java, Analysis/PA2/PAUtil.java, Analysis/PA2/WPPointerAnalysis.java, Analysis/PointerAnalysis/Debug.java, Analysis/PointerAnalysis/MAInfo.java, Analysis/PointerAnalysis/PointerAnalysis.java, Analysis/PointerAnalysis/Stats.java, Analysis/Quads/DeepInliner/DeepInliner.java, Support/jpaul.jar: new jpaul version; there were many suggestions from Adam Kiezunm and I apply them one by one 2005-11-30 salcianu * Support/jpaul.jar: newer version of jpaul.jar * Analysis/PA2/GraphOptimizations.java, Analysis/PA2/MapRelPAEdgeSet.java, Analysis/PA2/Mutation/MutationNFA.java, Analysis/PA2/Mutation/PURITY-README.html, Analysis/PointerAnalysis/LightMap.java: Small changes having to do with changes in the names of a few jpaul methods (thanks to Adam Kiezun for suggesting them). * Main/Purity.java, Analysis/PA2/Mutation/PURITY-README.html: small changes * Analysis/PA2/Mutation/PURITY-README.html: added info on getting the source code 2005-11-21 salcianu * Analysis/Quads/QuadClassHierarchy.java: Fixing an embarassing bug (I think introduced by me while "cleaning" up the code a few weeks ago): from the caller perspective, there is no point changing a value of a parameter if you don't return it ... 2005-11-06 salcianu * Analysis/PA2/Mutation/WPMutationAnalysisCompStage.java: Small change to some recently added code, to make sure that Flex can continue to analyze itself (some newly added code invoked a method that is not in GNU Classpath 0.08, nor in our additions to it). * Analysis/PA2/Mutation/PURITY-README.html, Analysis/PA2/Mutation/flex-self-test: missing link fixed * Support/jpaul.jar: new jpaul lib * Main/Purity.java: new version * Util/Options/Option.java: Additional test to prevent the creation of options with a name that contains space: there is more than enough naming flexibility even without space :) * Analysis/PA2/Flags.java, Analysis/PA2/Mutation/PURITY-README.html, Analysis/PA2/Mutation/WPMutationAnalysisCompStage.java, Analysis/PA2/Mutation/flex-self-test, Analysis/PA2/Mutation/make-purity-kit, Analysis/PA2/Mutation/purity-test, Analysis/PA2/WPPointerAnalysisCompStage.java: 1. Adding an option suggested by Michael Ernst: --daikon-purity-file It instructs the purity analysis to putput a file containing the names of all pure methods. 2. Per David Saff's suggestion, changed the purity analyis kit to use "suppJars" instead of "aux" as the name of the subdir with the auxiliary .jars required by the analysis implementation (jutil.jar and jpaul.jar). It turns out that Windows has big problems with directories names "aux"; that's a shame for the Windows authors ... 2005-10-25 salcianu * Analysis/PA2/Mutation/purity-test: smal change in a testing script * Analysis/ClassHierarchy.java, Analysis/PA2/PAUtil.java, ClassFile/HClass.java, Support/jpaul.jar: yet another minor change in jpaul.jar 2005-10-24 salcianu * Support/jpaul.jar: new version of jpaul * Analysis/PA2/PAUtil.java, Analysis/PA2/WPPointerAnalysis.java: removing some forgotten debugging code 2005-10-15 salcianu * Analysis/ClassHierarchy.java, Analysis/PreciseGC/WriteBarrierQuadPass.java, Analysis/Quads/QuadClassHierarchy.java, ClassFile/HClass.java: Moved ClassHierarchy.parents(HClass) into HClass.parents() The set of parents of a class is a class-local information, and this method belongs to the HClass class. However, children is a whole-program info, and it remains in the ClassHierarchy class. 2005-10-14 salcianu * Analysis/ClassHierarchy.java: Added Javadoc: now, it should be clear what callable methods and usable/reachable classes are * Analysis/ClassHierarchy.java: better Javadoc 2005-10-13 salcianu * Analysis/Quads/QuadClassHierarchy.java: small changes * Analysis/Quads/QuadClassHierarchy.java: rearranged a bit the code from discoverInstantiatedClass and fixed the comments * Analysis/Quads/QuadClassHierarchy.java: identation and naming changes * Analysis/PA2/Mutation/PURITY-README.html: small change * Main/SAMain.java: irrelevant: changed justification 2005-10-09 salcianu * Analysis/PA2/Mutation/PURITY-README.html: even more doc 2005-10-08 salcianu * Analysis/PA2/Mutation/PURITY-README.html: improved doc * Analysis/PA2/Mutation/PURITY-README.html, Analysis/PA2/Mutation/PURITY-README.txt, Analysis/PA2/Mutation/make-purity-kit: Transformed the README for the purity analysis tool from a .txt into a .html. 2005-10-06 salcianu * ClassFile/HClass.java: adding more comments * ClassFile/HClass.java: adding javadoc * Analysis/PA2/Mutation/purity-test: fixing silly typo 2005-10-05 salcianu * Analysis/PA2/Mutation/PURITY-README.txt, Analysis/PA2/Mutation/flex-self-test, Analysis/PA2/Mutation/purity-test, Main/Purity.java, Util/Timer.java: new version of the purity tool * Support/jpaul.jar: tiny change: removal of an annoying debug message * ClassFile/ImplMagic.java: better caching for the ImplMagic HClass implem. * IR/Bytecode/OpConstant.java, IR/RawClass/ConstantClass.java: better warning message * Main/SAMain.java: better timing * Analysis/PA2/Flags.java, Analysis/PA2/Mutation/WPMutationAnalysisCompStage.java, Analysis/PA2/Mutation/flex-self-test, Analysis/PA2/Mutation/make-purity-kit, Analysis/PA2/Mutation/purity-test, Analysis/PA2/PAUtil.java, Analysis/PA2/Stats.java, Analysis/PA2/WPPointerAnalysis.java: Small changes everywhere: more accurate timing etc. * Analysis/PA2/WPPointerAnalysisCompStage.java: Notice how we do the cg computation between HClass.enterImmutableEpoch(); and HClass.exitImmutableEpoch(); It feels good to be fast :) I will now reattempt to self-analyze flex: last time I had to stop the call graph construction after more than 3 hours ... * Analysis/Quads/CallGraphImpl.java: The promised commit of CallGraphImpl: actually, it doesn't contain anything to motivate the huge speed (25+x) I've encountered. The speed-up is done externally, by entering into an immutability Epoch for HClass'es. However, a small optimization: factored out of the loop some potentially expensive computation, especially HMethod.getDescriptor() that, you guessed it!, does not always use caching, because HMethods are mutable. * ClassFile/HClass.java: Caching support added to HClass. If you ever profiled harpoon.Analysis.Quads.CallGraphImpl in isolation, you may have noticed how slow it is (for Jolden BH, more than 69secs; for comparison, pointer analysis itself takes 28secs). After investigating the issue, I've identified the problem: the ultra-hyper-super-slow method HClass.getMethod(String name, String descriptor) that does a linear search over all methods declared in a class. Naturally, if something is slow and you call it in many places, you try to add caching or some better search datastruct (it is trivial to build a key tree that allows the search of a word in a huge dictionary in time linear in the length of the searched word). However, there is a catch: in Flex, HClass and HMethod are mutable, so caching would be incorrect ... [ Darko, in case you read this, I think you once complained about the purely functional datastructs used in some MSR compiler infrastructure. I think having all the important datastructs purely functional was the best decision that MSR group ever did. Please send them my greetings :) ] I think the mutability of HClass and HMethod (and the fact that the internal representation of such classes is completely exposed - witness the non-private, non-final, package-level "String name;" in ClassFile/HClassCls.java) is a design mistake (especially when you combine this mutational feature" combined with the lazy, on-demand code factories). However, it seems too hard to fix now and I strated feeling really motivated to graduate soon! As an alternative, I've added the possibility of defining "immutablity epochs" for HClass objects: in such an epoch, all HClass'es are guaranteed to stay unchanged, and caching makes sense. If one wants to do a mutation on HClass'es, the current epoch (if any) is terminated, which renders all the HClass caches I've added irrelevant (thanks to an epoch numbering system, these caches will get thrown away without being used in the next immutability epoch). The way this mechanism is supposed to be used is HClass.enterImmutableEpoch(); /* Big computation that does not mutate HClass'es. E.g. call graph computation (not just the creation of the harpoon.Analysis.Quads.(Caching)CallGraph - that doesn't perform too much computation - instead, a sequence of callee computations that actually does something */ HClass.exitImmutableEpoch(); Javadoc for these new static methods will be added soon (repeating some of the things from this commit message). Very soon, a commit on the CallGraphImpl class will show a clear example of using this new feature. * Support/jpaul.jar: Updated version of the jpaul library, with a high-performance work-queue (unlike a work-set, a work-queue does not enforce the set property; same element can be in the queue multiple times). 2005-10-02 salcianu * Analysis/PA2/Mutation/PURITY-README.txt: incremented version number 2005-10-01 salcianu * Analysis/PA2/Mutation/PURITY-README.txt, Analysis/PA2/Mutation/make-purity-kit: small changes * Analysis/PA2/Mutation/flex-self-test, Analysis/PA2/Mutation/flex-self-test.sh: file rename * Support/glibj-0.08-extra.jar: newer version of our gnu cp additions; make sure Collection is a subinterface of Iterable 2005-09-30 salcianu * Support/reflect-thunk.jar: New reflect-thunk.jar with the latest changes in AccessibleObject.java from the Harpoon Runtime. You should now be able to ask Flex to parse and analyze itself using the Analysis/PA2/flex-self script * Support/glibj-0.08.zip: Added the .zip file with the GNU Classpath 0.08 implem. of the Java standard library to our Support file. This way, Flex users (if any) can simply checkout the compiler and start doing some analysis. No need to go through the pain of compiling classpath if you only need to do some analysis. I agree, for actually building executables, one needs the native libraries from Classpath too, but not all Flex applications involve compilation. * IR/Bytecode/OpConstant.java, IR/RawClass/ConstantClass.java: Improvisational hack to allow Flex to parse itself. Here is a brioef overview of the problem: the ldc_w bytecode instruction can be used to load a Class constant (not just an integer or a string). Somehow, Flex will try to construct an IR.Bytecode.OpConstant object; this failed in the old version because ConstantClass was not a subclass of ConstantValue. Not being an expert in this part of the compiler, I've improvized something, with the help of a few clearly marked changes in the two files below. At run time, the first time each of the modifications are invoked, a very clear warning will be printed, but Flex will continue running. Analysis-wise, it seems that everything is OK; no idea about the code generator. I agree that this is ugly. The best way to solve it would be to read the Java bytecode spec again and properly implement the current hackish improvisations. For easy reference, I attach here a (still unreplied) email to Scott about the bug that triggered this hack. It's interesting that this bug was triggered only now: the ldc_w specification I've read online is from '99, and it speaks about class constants (unsupported in our infrastructure). To: cananian@mit.edu Subject: More info on the most recent bug report Date: Tue, 27 Sep 2005 10:05:53 -0400 From: "Alexandru D. Salcianu" Hello Scott! After a bit of debugging, I've discovered that the problem (see my previous email atttached at the end of this one) occurs while Flex build the IR.Bytecode for the class initializer (i.e., ) of class net.cscott.jutil.PersistentTreeNode. I've used javap to look into the structure of the corresponding .class file: javap -c -p -verbose net.cscott.jutil.PersistentTreeNode | less (with an appropriate CLASSPATH in my env.) Here is the problematic code static {}; Code: Stack=4, Locals=8, Args_size=0 0: ldc_w #69; //class net/cscott/jutil/PersistentTreeNode 3: invokevirtual #70; //Method java/lang/Class.desiredAssertionStatus:()Z 6: ifne 13 9: iconst_1 10: goto 14 13: iconst_0 14: putstatic #23; //Field $assertionsDisabled:Z and here is a small fragment from the constant pool: const #68 = Method #279.#280; // java/io/PrintStream.println:(Ljava/lang/String;)V const #69 = class #281; // net/cscott/jutil/PersistentTreeNode const #70 = Method #282.#283; // java/lang/Class.desiredAssertionStatus:()Z Unfortunately, harpoon.IR.Bytecode.OpConstant does not support class constants: it works only with ConstantValues and ConstantClass is not a ConstantValue ... Making ConstantClass a ConstantValue requires defining an appropriate value() method. So, in Flex, how do I construct the java.lang.Class for a given string class name? I could use the system class loader, but I strongly doubt this is the correct way: (1) it bypasses the Linker and it doesn't load from harpoon.class.path, and (2) I don't think it's consistent with the way Flex supports reflection. Any ideas? Thanks, Alex PS: I'm a busy person myself and I fully understand that you don't have too much time. Still, at least a short reply from time to time would be appropriate, at least to inform me that my emails do not disappear in a black-hole :) ------- Forwarded Message To: cananian@mit.edu Subject: Flex problem with JDK 1.5 Date: Mon, 26 Sep 2005 22:03:56 -0400 From: "Alexandru D. Salcianu" Hi Scott! I'm trying to get the purity tool I've built using Flex to analyze itself (or at least to parse itself in the first stage). Here is an error I get: [LOADING ./aux/jutil.jar/net/cscott/jutil/Default$EmptyMap$EmptyMapSet.class] [LOADING ./aux/jutil.jar/net/cscott/jutil/Default$2.class] [LOADING ./aux/jutil.jar/net/cscott/jutil/UnmodifiableIterator.class] [LOADING ./aux/jutil.jar/net/cscott/jutil/PersistentMap$1.class] Exception in thread "main" java.lang.Error: Unknown constant pool entry: CONSTANT_Class: net/cscott/jutil/PersistentTreeNode {281} at harpoon.IR.Bytecode.OpConstant.(OpConstant.java:69) at harpoon.IR.Bytecode.InGen.(InGen.java:180) at harpoon.IR.Bytecode.Code.getElementsL(Code.java:127) at harpoon.IR.Bytecode.Code.getTryBlocks(Code.java:239) at harpoon.IR.Quads.Translate.trans(Translate.java:536) at harpoon.IR.Quads.QuadWithTry.(QuadWithTry.java:38) at harpoon.IR.Quads.QuadWithTry$2.convert(QuadWithTry.java:94) at harpoon.IR.Quads.CloneSynthesizer.convert(CloneSynthesizer.java:63) at harpoon.ClassFile.CachingCodeFactory.convert(CachingCodeFactory.java:58) at harpoon.ClassFile.CachingCodeFactory.convert(CachingCodeFactory.java:58) at harpoon.Analysis.Transformation.MethodMutator$1.convert(MethodMutator.java:67) at harpoon.ClassFile.CachingCodeFactory.convert(CachingCodeFactory.java:58) at harpoon.Analysis.Quads.QuadClassHierarchy.(QuadClassHierarchy.java:202) at harpoon.Main.SAMain$BuildQuadForm.real_action(SAMain.java:565) at harpoon.Main.CompilerStageEZ.action(CompilerStageEZ.java:37) at harpoon.Main.SAMain.main(SAMain.java:118) at harpoon.Main.Purity.main(Purity.java:82) salcianu@retezat:~/purity-kit$ You'll find the code that generates the error at http://www.mit.edu/~salcianu/purity-kit-crash.tgz The .tgz uncompresses into a directory called purity-kit; it contains a script called crash.sh that will illustrate the problem (before using it, you'll need to edit it to indicate the place where the JDK 1.5 rt.jar is. After that, just urn the edited crash.sh Let me know if you gave any insight into this error! Alex * Analysis/PA2/Mutation/flex-self-test.sh: script that tests Flex by running the purity analysis on itself * ClassFile/CachingCodeFactory.java, ClassFile/ImplMagic.java, Main/Purity.java: no changes: occasional whitespaces added * IR/Bytecode/Code.java, Main/SAMain.java: 1. Fixed the class Javadoc for SAMain: it contained some ancient phrase about StrongArm. Those days are gone! 2. Added a new version "--verbose-bytecode-method" that allows us to see which methods are actually parsed by Flex from bytecode. I've found this option quite useful while struggling to add the GNU Classpath 0.08 extra classes to allow Flex to parse itself. * Support/glibj-0.08-extra.jar: small changes: making sure all java files have the right copyright notice - GNU GPL * Support/glibj-0.08-extra.jar: jar with several class implementations that allow Flex to parse and analyze itself (when using this jar and GNU Classpath 0.08). Contains a pretty detailed README.txt that explains what those classes are and how to edit them. It's unclear whether Flex can actually generate a correct executable of itself, as after 4 weeks of frustrating work, I'm still unable to use Flex to compile anything with GNU Classpath... DON'T RUSH into using Flex to analyze itself! There are a few more commits that I have to do, after I clear out the mess around those edits. Once that is done, I'll tag the files with something like flex_self_parse_gnu_cp_0_08 such that we have a checkpoint. 2005-09-29 salcianu * Analysis/PA2/Mutation/make-purity-kit, Analysis/PA2/Mutation/purity-test: small changes in the scripts associated with the purity analysis kit * Main/Purity.java: Better way to obtain the root dir of the purity kit * Main/Settings.java: better javadoc * ClassFile/ImplMagic.java: adding some more empty lines for clarity * ClassFile/HClassSyn.java: small changes * Analysis/AbstractClassFixupRelinker.java: better assertion message * Analysis/Quads/SCC/SCCAnalysis.java: Code restructuring to go around some JDK 1.5.0 bug. All versions of Sun JDK 1.5.0 I've tried (_02, _4, and _05) generate incorrect code for SCCAnalysis: they generate byecode that references an anonymous inner classes (SCCAnalysis$1) that is never written to disk by the javac compiler (SCCAnalysis$2/3/4 luckier - they get written to the disk). This error surfaced when I was trying to parse Flex with itself. It seems that JDK 1.5.0 was confused by the many static inner classes of SCCAnalysis. Without changing the semantics or the protection level (package), I've placed almost all such classes outside SCCAnalysis. Now, Flex seems able to parse itself + GNU classpath 0.08. Unclear if Flex can compile itself down to native code: I didn't succeed in making Flex generate ANY executable with GNU classpath-0.08. 2005-09-28 salcianu * Analysis/Quads/QuadClassHierarchy.java: During recent debugging, I had to investigate QuadClassHierarchy (no bug was found in it, but understamding it was essential for finding the real bugs). I took this opportunity to make the code easier to read and understand; in particular, the long constructor has been split into several methods. * Analysis/ClassHierarchy.java: Small change performed while debugging one of the previously mentioned bugs: the Javadoc of this class lacks a clear definition of usable/reachable class (reachable is not transitive subclassing). I propose such a definition in a TODO comment. Hopefully, this comment will motivate people to improve the Javadoc for ClassHierarchy. * ClassFile/HMethodImpl.java: Better hashCode - the last commit made Flex really slow. Current version is faster than classical version, the one before my most recent commit: instead of computing the method descriptor (by doing a bunch of appends to a StringBuffer), we use the hashCodes of the parameters and the hashCode of the return type. I remember that Wes once noticed that Flex spends most of its time constructing HMethod descriptors. QUESTION: can't we cash the hashCode and the descriptor of an HMethod? The speed improvements would be HUGE! * ClassFile/HMethodImpl.java: Changed the equals method of HMethodImpl. In Java, two otherwise identical methods with different return types are DISTINCT (in particular, they have a distinct descriptor). In case there are any doubts, please run javap harpoon.IR.Assem.Instr\$4 and notice the two get(int) methods (one returns an Object, the other an Instr). These methods are created by the compiler, in "corner cases" (that's oure codename for "situations that expose bugs); e.g., refinement of the return type in a subclass. The old "equals" did not reflect this, preventing Flex from parsing itself: while constructing HClass'es, Flex had the impression that some classes have duplicate methods. This was another highly unpleasant bug ... * IR/Quads/CALL.java: Better assertion messages * IR/Quads/Quad.java: New method: toLongString - provides more info than the usual toString * ClassFile/ImplMagic.java: Quick fix for an UNUSUALLY NASTY BUG: different implementation of HClass do not agree on the definition of equals. For HClassProxy, equals means equality of the string descriptor. For every single other HClass (sub)class I've seen (and there are many of them: HClass, HClassImpl, HClassCls, HClassSyn, and, last but not least!, the informatively named ImplMagic$MagicClass), so, for all of other HClass'es, equals is inherited from Object, i.e., object identity. As a consequence, the equals relation on HClass^2 is NOT symmetric, leading to a wide range of ugly bugs related to the use of HClass'es in collections ... javac should definitely contain Bill Pugh's detector of easy bugs / suspicious code (such as defining hashCode without defining equals, which would have caught this problem). A couple of years ago, after a similar debug marathon, I though about such a tool; Bill Pugh was faster. Currently, I've just added an equals method in ImplMagic$MagicClass. This is a temporary fix: the best way would be to implement equals and hashCode at the level of HClass. Is there any reason why two HClass'es with the same descriptor should not be equal? 2005-09-27 salcianu * Analysis/PA2/Flags.java, Analysis/PA2/Mutation/PURITY-README.txt: small changes left uncommited * IR/Bytecode/OpConstant.java: more informative error message; such that we know the method that we parse when the error occurs 2005-09-22 salcianu * .cvsignore, Analysis/PA2/Mutation/WPMutationAnalysisCompStage.java: Many small changes done while making the purity analysis tool. * Main/Purity.java: Convenient entry point for the pointer analysis (as executed in the pointer analysis kit generated by Analysis/PA2/Mutation/make-purity-kit). Minimal arguments, does not need any special property or environment settings, so it's well-suited for programmatic use of the analysis. The "minimal arguments" feature has a downside: the class is pretty rigid as to where each required file is on the disk; you should not attempt to use it outside the purity analysis kit. * Analysis/PA2/Mutation/PURITY-README.txt, Analysis/PA2/Mutation/make-purity-kit, Analysis/PA2/Mutation/purity-test: Files for creating a purity analysis kit. They seem to work; a first version (0.00 - everything has a beginning!) of the kit has been created. It's available from http://www.mit.edu/~salcianu/purity2 (the final 2 is important). 2005-09-21 salcianu * Analysis/PA2/Flags.java, Analysis/PA2/Mutation/WPMutationAnalysisCompStage.java, Analysis/PA2/PAUtil.java, Analysis/PA2/Stats.java, Analysis/PA2/WPPointerAnalysis.java: more changes on PA stats: adding command line option (off by default) * .cvsignore, Analysis/PA2/Mutation/MAUtil.java, Analysis/PA2/Mutation/WPMutationAnalysisCompStage.java, Analysis/PA2/PAUtil.java, Analysis/PA2/Stats.java, Analysis/PA2/WPPointerAnalysis.java, GNUmakefile, Util/Timer.java: adding statistics 2005-09-20 salcianu * Analysis/PA2/Flags.java, Analysis/PA2/InterProcConsGen.java, Analysis/PA2/IntraProc.java: fixing a small bug 2005-09-19 salcianu * Support/jpaul.jar: new version of jpaul.jar 2005-09-18 salcianu * Analysis/PA2/AllocSync/AllocSyncOneMethod.java, Analysis/PA2/AllocSync/WPAllocSyncCompStage.java, Analysis/PA2/Mutation/WPMutationAnalysisCompStage.java, Analysis/PA2/InterProcConsGen.java, Analysis/PA2/PAUtil.java, Analysis/PA2/PointerAnalysis.java, Analysis/PA2/WPPointerAnalysis.java: Technical changes * Main/SAMain.java, Main/Settings.java: better mesages 2005-09-16 salcianu * Analysis/IOEffectAnalysis.java, Analysis/PA2/InterProcConsGen.java, Analysis/PA2/quasi-safe.sunjdk.properties, Analysis/io-methods.classpath-0.08.properties, Analysis/io-methods.sunjdk.properties: adding properties for IOEffectAnalysis * Main/Settings.java: better error message * Main/SAMain.java, Main/Settings.java, Support/jpaul.jar: New code to check that the right version of classpath is on harpoon.class.path. Currently, the user specifies which standard library implem. he wants to use (sunjdk or classpath-VER, where VER is also user-specified, with teh default being classpath-0.08). Next, Flxe uses some heuristics to check that the right std. lib is on harpoon.class.path (currently, we grab the constant content of the field gnu.classpath.Configuration; for sunjdk, we just assume it's correct). In the future, we may consider not requiring any command line option about the std lib, and just look on the classpath. The reason I'm not inclined to do so yet is that we currently support just two versions of classpath, and I feel that the user must be VERY AWARE of what he's using. * Analysis/PA2/PAUtil.java: Forgotten commit. * Analysis/PA2/Flags.java, Analysis/PA2/SpecialInterProc.java: deleting comments; verbosity made conditional 2005-09-15 salcianu * GNUmakefile: finally managed to inform the makefile about the newly added properties * Analysis/PA2/SpecialInterProc.java, Analysis/PA2/quasi-safe.classpath-0.08.properties: add code to use the full info from quasi-safe properties * Instrumentation/AllocationStatistics/AllocationInstrCompStage.java: fixing the enabling condition 2005-09-14 salcianu * GNUmakefile: changes to take into account the new quasi-safe properties files * bin/run-java: make sure we start with an empty set of javaopts; external entities can pass additional options as comman line options; I dislike hidden passing of args via env vars, properties etc. * bin/build-precisec: Simplifications: 1. The previous special processing to add some of my options is gone 2. I couldn't find any meaning for the -Dsample=value option. I deleted it. * Analysis/PA2/SpecialInterProc.java: reading quasi-safe methods from a property file, instead of initializing them by hand * Analysis/PA2/AllocSync/WPAllocSyncCompStage.java: fixing typo * Analysis/PA2/Flags.java: setting two common defaults * Main/RegularCompilerStageEZ.java: unnecessary now * Main/MZFCompilerStage.java: From now on, using the mzf stage will require explicitly activating it using the "--mzf" command option. Ideally, all the (MANY!) properties should be converted to command line options, and each of them should be enough for turning on the ENABLED flag (that is currently done by "--mzf"). After this change, people running only compilation will no longer have to wonder "why is the mzf stage invoked?" * Main/CodeGenerator.java: small change * Main/SAMain.java: small changes; mainly to take into account that certain stages should be executed only if we generate code (default case) and not for pure analyses * Main/Settings.java: Providing a place for truly global settings, such as the standard library implementation we use (currently, one of sunjdk or classpath-0.xx). I think the compiler should be VERY aware of what standard library it is using, and pick the appropriate property files (see the quasi-safe.*.properties files from Analysis/PA2). The distinction between different stdlibs should be done based on a command line option (and different classpaths) instead of cvs branches If we use branches, how are we going to distribute the compiler? as a CVS repository? Multiple distributions? (one for each supported stdlib?) * Analysis/PA2/quasi-safe.sunjdk.properties: quasi-safe for sunjdk * Analysis/PA2/quasi-safe.classpath-0.08.properties: file with quasi-safe methods; the first paragraphs of comments explain what such a method is 2005-09-13 salcianu * Analysis/PA2/IntraProc.java: Change the semantics of a method from pointer analysis to fix a bug eomDirGblEsc should return all externally-visible globally lost nodes - some of the direct gbl esc nodes may not be visible from outside; eomAllGblEsc returns even the nodes that are not reachable from params/return - these are the nodes compressed into GBL Maybe the name of the method should be changed too at some point * Analysis/PA2/Mutation/WPMutationAnalysisCompStage.java: changes in the statistics gathering code * Analysis/PA2/SpecialInterProc.java: better protection against missing methods in an analysis optimization * Analysis/IOEffectAnalysis.java, Analysis/PA2/Mutation/MutationAnalysis.java: Making the code more resilient against certain missing methods (the methods may not be there simply because they are not invoked by the analyzed program). * Analysis/PA2/InterProcConsGen.java: adding missing constraint 2005-09-12 salcianu * Main/CodeGenerator.java: Print longer description for the compiled methods. If the user dislikes compiler output, there is a special command line option for making it non-verbose. * bin/run-java: If CLASSPATH_HOME is not set by the user, set it to ${FLEX_DIR}/../classpath-install. If this directory does not exist, or for whatever reason the classpath .zip is not there, the usual processing resumes: try classpath-config, look for the usual location for the installed debian package. Also made sure that if .zip is found, the script fails loudly, instead of continuing. * Analysis/Quads/InitializerTransform.java: At Scott's suggestion, make sure that an error encountered while reading the init-safe property file results in a Runtime Exception being thrown by teh compiler. Normally, this will cause the entire compiler to die. Alternatively, a top level class may decide to catch the exception, print some informative message, and try something else. 2005-09-08 salcianu * Analysis/Quads/InitializerTransform.java: Small changes to make sure that one problematic line in the root set file does not cause Flex to skip the rest of the file: now, Flex prints a warning message, and continues with the other lines from the file. 2005-09-07 salcianu * Support/jpaul.jar: latest jpaul.jar * Analysis/IOEffectAnalysis.java, Analysis/PA2/Mutation/MAUtil.java, Analysis/PA2/Mutation/MLabel.java, Analysis/PA2/Mutation/MutRegExpSimplifier.java, Analysis/PA2/Mutation/MutationAnalysis.java, Analysis/PA2/Mutation/WPMutationAnalysisCompStage.java, Support/jpaul.jar: added simple analysis to detect IO effects - separated from the pointer/mutation analysis; there was no link between them anyway 2005-09-06 salcianu * Analysis/PA2/Mutation/MutRegExpSimplifier.java, Analysis/PA2/Mutation/MutationAnalysis.java, Analysis/PA2/Mutation/MutationNFA.java, Analysis/PA2/Mutation/WPMutationAnalysisCompStage.java: adding a simplifier to make regexps nicer 2005-09-05 salcianu * Analysis/PA2/InterProcConsGen.java, Analysis/PA2/Mutation/MutationAnalysis.java, Analysis/PA2/Mutation/WPMutationAnalysisCompStage.java, Analysis/PA2/PAUtil.java, Analysis/PA2/SpecialInterProc.java, Analysis/PA2/WPPointerAnalysisCompStage.java, Support/jpaul.jar: more changes in the mutation analysis - mostly output formatting * Analysis/PA2/Flags.java, Analysis/PA2/InterProcAnalysisResult.java, Analysis/PA2/IntraProc.java, Analysis/PA2/PAUtil.java: small changes in the pa v.2 code * Analysis/PA2/Mutation/MAUtil.java, Analysis/PA2/Mutation/MutationAnalysis.java, Analysis/PA2/Mutation/MutationNFA.java, Analysis/PA2/Mutation/ParamInfo.java, Analysis/PA2/Mutation/WPMutationAnalysisCompStage.java: Ported "safe parameter" detection (as described in the VMCAI'05 paper) to the new implementation of the pointer analysis. Hopefully, it is now robust enough to be used by other people too. * Analysis/PA2/Mutation/MLabel.java, Analysis/PA2/Mutation/MutationAnalysis.java, Analysis/PA2/Mutation/NoAnalysisResultException.java, Analysis/PA2/Mutation/WPMutationAnalysisCompStage.java: Added some classes for the mutation analysis. 2005-09-02 salcianu * Analysis/PA2/AllocSync/WPAllocSyncCompStage.java, Analysis/PA2/Mutation/WPMutationAnalysisCompStage.java, Support/jpaul.jar, Analysis/PA2/WPPointerAnalysis.java, Analysis/PA2/WPPointerAnalysisCompStage.java: Changes to accomodate the latest reorganization of the pa compiler changes. * Main/CodeGenerator.java, Main/SAMain.java: Reorganized the compiler stages attached to the pointer analysis. Added a new option "--no-code-gen" for situations where only analysis is desired, without any code generation (e.g., purity analysis). If you don't use this option, the compiler works a before. * Analysis/PA2/CallConstraint.java, Analysis/PA2/GraphOptimizations.java, Analysis/PA2/Mutation/MutationNFA.java, Analysis/PA2/Mutation/WPMutationAnalysisCompStage.java, Analysis/PA2/SpecialInterProc.java, Analysis/PA2/WPMutationAnalysisCompStage.java, Analysis/PA2/WPPointerAnalysis.java, Analysis/PA2/WVar.java: reorganization of code for the mutation analysis 2005-09-01 salcianu * Analysis/PA2/Mutation/MutationNFA.java, Analysis/PA2/NodeRepository.java, Analysis/PA2/PAEdgeSet.java, Analysis/PA2/PAUtil.java, Analysis/PA2/WPMutationAnalysisCompStage.java, Analysis/PA2/WVar.java, Analysis/PA2/WriteConstraint.java: adding more code for the purity/mutation analysis 2005-08-31 salcianu * Analysis/CallGraph.java, Analysis/PA2/Flags.java, Analysis/PA2/GraphOptimizations.java, Analysis/PA2/SpecialInterProc.java, Analysis/PA2/TypeFilter.java, Analysis/PA2/WPMutationAnalysisCompStage.java, Analysis/PA2/WPPointerAnalysisCompStage.java, Main/SAMain.java, Support/jpaul.jar: today's edits 2005-08-30 salcianu * Analysis/PA2/AllocSync/WPAllocSyncCompStage.java, Analysis/PA2/CallConstraint.java, Analysis/PA2/DSFactories.java, Analysis/PA2/Flags.java, Analysis/PA2/GraphOptimizations.java, Analysis/PA2/IPResTupleImpl.java, Analysis/PA2/InterProcAnalysisResult.java, Analysis/PA2/InterProcConsGen.java, Analysis/PA2/IntraProc.java, Analysis/PA2/PAUtil.java, Analysis/PA2/WPPointerAnalysis.java, Analysis/PA2/WPPointerAnalysisCompStage.java, Support/jpaul.jar: ported mutation analysis to new pointer analysis implem 2005-08-29 salcianu * Analysis/PA2/AllocSync/WPAllocSyncCompStage.java, Analysis/PA2/Flags.java, Analysis/PA2/InterProcConsGen.java, Analysis/PA2/IntraProc.java, Analysis/PA2/MapRelPAEdgeSet.java, Analysis/PA2/WPPointerAnalysis.java, Analysis/PA2/WPPointerAnalysisCompStage.java, Support/jpaul.jar: Latest changes in the Pointer Analysis v2 (PA2) implementation. Optimizations that trade precision for speed: 1. Consider as unanalyzable the calls with too many callees (currently, the threshold is set at 15). 2. Consider as unanalyzable the intra-scc calls from too big SCCs As a result, the pointer analysis of javac takes less than 5 minutes (down from more than 2hours in the TOPLAS submission - old implem., and the results are actually better). 2005-08-26 salcianu * Analysis/PA2/MapRelPAEdgeSet.java, GNUmakefile, Support/RegExps.jar, Support/jpaul.jar, bin/run-java: The code from RegExps.jar has been integrated (in a highly improved form) in the jpaul library (Support/jpaul.jar). No need for a separate .jar now. 2005-08-18 salcianu * Analysis/PA2/DSFactories.java, Analysis/PA2/MapRelPAEdgeSet.java, Support/jpaul.jar: small changes 2005-08-17 salcianu * Analysis/EventDriven/ToAsync.java, Analysis/MetaMethods/MetaAllCallers.java, Analysis/MetaMethods/MetaCallGraph.java, Analysis/MetaMethods/MetaCallGraphAbstr.java, Analysis/MetaMethods/MetaCallGraphImpl.java, Analysis/MetaMethods/SmartCallGraph.java, Instrumentation/AllocationStatistics/AllocationNumberingStub.java, Support/jpaul.jar, Util/TypeInference/TypeInference.java, IR/Quads/SSIRename.java: Changes to accomodate the switch from harpoon.Util.DataStructs to jpaul.DataStructs * Analysis/PointerAnalysis/AbstrPAEdgeSet.java, Analysis/PointerAnalysis/AbstrRelation.java, Analysis/PointerAnalysis/AbstrRelationMapBased.java, Analysis/PointerAnalysis/ActionRepository.java, Analysis/PointerAnalysis/ComputeInterProcMuClosure.java, Analysis/PointerAnalysis/Debug.java, Analysis/PointerAnalysis/EdgeOrdering.java, Analysis/PointerAnalysis/InterProcPA.java, Analysis/PointerAnalysis/InterThreadPA.java, Analysis/PointerAnalysis/LightMap.java, Analysis/PointerAnalysis/LightPAEdgeSet.java, Analysis/PointerAnalysis/LightRelation.java, Analysis/PointerAnalysis/MAInfo.java, Analysis/PointerAnalysis/Matching.java, Analysis/PointerAnalysis/PAEdge.java, Analysis/PointerAnalysis/PAEdgeSet.java, Analysis/PointerAnalysis/PAEscapeFunc.java, Analysis/PointerAnalysis/PANode.java, Analysis/PointerAnalysis/PASync.java, Analysis/PointerAnalysis/PAThreadMap.java, Analysis/PointerAnalysis/ParIntGraph.java, Analysis/PointerAnalysis/PointerAnalysis.java, Analysis/PointerAnalysis/PointsToGraph.java, Analysis/PointerAnalysis/Relation.java, Analysis/PointerAnalysis/RelationEntryVisitor.java, Analysis/PointerAnalysis/RelationImpl.java: To make sure harpoon.Analysis.PointerAnalysis continues to compile, several classes from the now disappeared harpoon.Util.DataStructs have been moved here: they are a few differences between these classes and those from jpaul.DataStructs and I could not do all the changes. Which would also be senseless: Analysis.PointerAnalysis will dissapear in a few weeks, as PA2 become more mature. * Analysis/CallGraph.java, Analysis/DataFlow/InstrSolver.java, Analysis/MemOpt/ComputeAnAe.java, Analysis/MemOpt/Util.java, Analysis/MetaMethods/MetaCallGraph.java, Analysis/MetaMethods/MetaCallGraphImpl.java, Analysis/PointerAnalysis/EdgesNCallees.java, Analysis/PointerAnalysis/MethodHole.java, Analysis/PointerAnalysis/PointsToGraph.java, Util/LightBasicBlocks/CachingSCCLBBFactory.java, Util/LightBasicBlocks/SCCLBBFactory.java: Changes to accomodate the switch from harpoon.Util.Graphs to jpaul * Analysis/PointerAnalysis/Debug.java, Analysis/PointerAnalysis/InterProcPA.java, Analysis/PointerAnalysis/MAInfo.java, Analysis/PointerAnalysis/ODInformation.java, Analysis/PointerAnalysis/ODInterProcPA.java, Analysis/PointerAnalysis/ODMAInfo.java, Analysis/PointerAnalysis/ODNodeStatus.java, Analysis/PointerAnalysis/ODParIntGraph.java, Analysis/PointerAnalysis/ODParIntGraphPair.java, Analysis/PointerAnalysis/ODPointerAnalysis.java, Analysis/PointerAnalysis/PointerAnalysis.java, Analysis/PointerAnalysis/Stats.java: Removed ODPointerAnalysis and the attached files. Nobody used this in many, many years, and it's a nuisance every time we change something. If it's really necessary, anybody can check into an older version of the compiler. * bin/run-java: self-explanatory changes * Support/jpaul.jar: jpaul.jar added as any binary file should be: with -kb:) * Support/jpaul.jar: remove jpaul.jar; it will be added again with the -kb option 2005-08-16 salcianu * Support/jpaul.jar: Sorry for this: jpaul.jar 2.1 should finally be in now. * Analysis/PA2/AllocSync/ASFlags.java, Analysis/PA2/AllocSync/AllCallers.java, Analysis/PA2/AllocSync/AllCallersImpl.java, Analysis/PA2/AllocSync/AllocSyncOneMethod.java, Analysis/PA2/AllocSync/WPAllocSyncCompStage.java, Analysis/PA2/CallConstraint.java, Analysis/PA2/CloneCallConstraint.java, Analysis/PA2/DSFactories.java, Analysis/PA2/GraphOptimizations.java, Analysis/PA2/IntraProc.java, Analysis/PA2/LoadConstraint1.java, Analysis/PA2/LoadConstraint2.java, Analysis/PA2/StaticStoreConstraintF.java, Analysis/PA2/StoreConstraint.java, Analysis/PA2/StoreConstraintF.java, Analysis/PA2/TypeFilterConstraint.java, Analysis/PA2/WPPointerAnalysisCompStage.java, Support/jpaul.jar: 1. Commit the new version of jpaul.jar (2.1) 2. Various changes here and there to make sure the code compiles with the new version. 2005-08-09 salcianu * Main/SAMain.java: Added an option to trigger loader verbosity: --verbose-load; causes the loader to show where it loads each class from. * Analysis/PA2/AllocSync/WPAllocSyncCompStage.java: small addition (a method that creates the right pipeline of compiler stages: pointer analysis + stack alloc. client - invoked from SAMain). * Main/SAMain.java: Changes in the top-level compiler driver to invoke PA v.2 and its stack allocation client (stack allocation is really great for debugging pa). * Analysis/PA2/AllocSync/ASFlags.java, Analysis/PA2/AllocSync/AllocSyncOneMethod.java, Analysis/PA2/AllocSync/Debug.java, Analysis/PA2/AllocSync/LoopDetector.java, Analysis/PA2/AllocSync/WPAllocSyncCompStage.java: Stack allocation and sync. removal client of the pointer analysis. For the moment, only the stack allocation (as locks are becoming thinner, sync removal doesn't have very much priority on my TODO list). * Analysis/PA2/AnalysisPolicy.java, Analysis/PA2/CallConstraint.java, Analysis/PA2/CloneCallConstraint.java, Analysis/PA2/DSFactories.java, Analysis/PA2/EVar.java, Analysis/PA2/EdgeSetVar.java, Analysis/PA2/FVar.java, Analysis/PA2/Flags.java, Analysis/PA2/FullAnalysisResult.java, Analysis/PA2/GraphOptimizations.java, Analysis/PA2/IPResTupleImpl.java, Analysis/PA2/IVar.java, Analysis/PA2/InterProcAnalysisResult.java, Analysis/PA2/InterProcConsGen.java, Analysis/PA2/IntraProc.java, Analysis/PA2/LVar.java, Analysis/PA2/LoadConstraint1.java, Analysis/PA2/LoadConstraint2.java, Analysis/PA2/MapRelEdgeSetFactory.java, Analysis/PA2/MapRelPAEdgeSet.java, Analysis/PA2/NodeRepository.java, Analysis/PA2/NodeSetVar.java, Analysis/PA2/OVar.java, Analysis/PA2/PAEdgeSet.java, Analysis/PA2/PANode.java, Analysis/PA2/PAUtil.java, Analysis/PA2/PointerAnalysis.java, Analysis/PA2/SpecialInterProc.java, Analysis/PA2/StaticStoreConstraintF.java, Analysis/PA2/StoreConstraint.java, Analysis/PA2/StoreConstraintF.java, Analysis/PA2/TypeFilter.java, Analysis/PA2/TypeFilterConstraint.java, Analysis/PA2/WPPointerAnalysis.java, Analysis/PA2/WPPointerAnalysisCompStage.java: New implementation of the pointer analysis, using the jpaul analysis library. More to come. * GNUmakefile, Support/RegExps.jar, Support/jpaul.jar: Some of my code uses two libraries I wrote: jpaul and RegExps (in time, RegExps will be added to jpaul). I've added these libraries as .jar's into Support, and changed GNUmakefile to make sure the code from the repository compiles OK. * Analysis/Quads/DeepInliner/package.html: small change * Analysis/Quads/DeepInliner/DeepInliner.java, Analysis/Quads/DeepInliner/InlineChain.java, Analysis/Quads/DeepInliner/OneLevelInliner.java, Analysis/Quads/DeepInliner/package.html: Package with inling related code. The main goal is inlining arbitrary-length call paths, but it also contains contains code for inlining just one call. * ClassFile/Loader.java: The printing of the "[LOADING " messages is now controlled by a static flag (off by default). A command line flag may turn it on, if desired. * Util/Timer.java: To ease its use, a Timer gets started as soon as it is created. Old code, that manually started the Timer, should not be affected. * Util/Util.java: Added a small method to retrieve the method whose code a quad is part of. * Analysis/EventDriven/ContCodeNoSSA.java: Small change to make sure flex compiles. * Analysis/Quads/CallGraphImpl.java: CallGraphImpl.java * IR/Quads/Quad.java, IR/Quads/QuadSSI.java: unimportant changes * IR/Quads/QuadNoSSA.java: Bug fix: propagate the allocation info when converting QuadRSSx into QuadNoSSA. * IR/Quads/RSSxToNoSSA.java: Made the code more readable: 1. Embellish identation 2. Make use of the JDK 1.5 for construct 3. Eliminate useless fields: object fields should be used to store things that are relevant for the object state, not just as a quick way of passing around frequent params ... 2005-01-20 C. Scott Ananian * Support/jutil.jar, Analysis/Instr/RegAlloc.java: Update to the latest version of JUtil (just re-org of the MultiMapFactory interface). 2004-07-02 C. Scott Ananian * Analysis/Transactions/SyncTransformer.java: Current transactions impl doesn't support nested transactions. 2004-07-01 C. Scott Ananian * Backend/Runtime1/ObjectBuilder.java, Backend/Runtime1/TreeBuilder.java, IR/Tree/ToTree.java, Main/Transactions.java: Revert more arraybloat code. * IR/Tree/ToTree.java, Main/Transactions.java, Analysis/Transactions/BitFieldNumbering.java, Analysis/Transactions/SyncTransformer.java, Analysis/Transactions/TreeDataFilter.java, Analysis/Transactions/TreePostPass.java, Backend/Runtime1/DataReflection1.java, Backend/Runtime1/DataStrings.java, Backend/Runtime1/ObjectBuilder.java, Backend/Runtime1/TreeBuilder.java, Analysis/SizeOpt/MostlyZeroFinder.java: Update Transactions implementation to match SPIN model. Get rid of arraybloat and readflags. * Support/jutil.jar: Update JUtil with a version compiled to work with JDK1.5b2 and which eliminates some old workarounds for buggy early versions of JSR-14 compilers. * Runtime/Transactions/TransactionAbortException.java: Replace string concatenation with explicit use of StringBuffer to be compatible with minilib, as javac 1.5 now uses StringBuilder to implement concatenation. * Backend/PreciseC/TreeToC.java: Suppress a gcc warning about labels at end of compound statements being deprecated by inserting a null statement (read, semicolon). * Analysis/Maps/ExecMapProxy.java, Analysis/ReachingDefsAltImpl.java, Util/SortedMapComparator.java, Analysis/Quads/CollectSyncStats.java, Analysis/Quads/ComponentOfReducer.java: Minor updates to support JDK1.5b2: remove some work-arounds needed for earlier versions of the compiler; add a parameter to an implementation of SecurityManager (not needed iff this class is compiled with -source 1.4, which I don't want to do), remove parameterizations from right-hand sides of instanceof (in AugSetFactory, done by making a surrounding class static so that it doesn't inherit the parameters of the parent). We also work-around a new bug in the ternary ? operator, in Util/SortedMapComparator. 2004-06-28 C. Scott Ananian * Main/Transactions.java, Analysis/Transactions/SyncTransformer.java, Analysis/Transactions/TreePostPass.java: Revert 2003-12-08 commit which "hack[ed] and chop[ped] out the readflags and array bloat stuff". This gives us a working version to grab the pces04 benchmarks with. * Runtime/Transactions/TransactionAbortException.java: Replace string concatenation with explicit use of StringBuffer to be minilib-friendly with JDK1.5 (which otherwise would use StringBuilder to implement string concatenation). * IR/Tree/ToTree.java, Main/Transactions.java, Analysis/Transactions/BitFieldNumbering.java, Analysis/Transactions/NOTES, Analysis/Transactions/SyncTransformer.java, Analysis/Transactions/TRANS-ALG.txt, Analysis/Transactions/TreeDataFilter.java, Analysis/Transactions/TreePostPass.java, Backend/Runtime1/DataReflection1.java, Backend/Runtime1/DataStrings.java, Backend/Runtime1/ObjectBuilder.java, Backend/Runtime1/TreeBuilder.java: Branch csa-ecoop04 (transactions work) updated to CVS head. * Analysis/Transactions/NOTES, Analysis/Transactions/TRANS-ALG.txt: New file. * Analysis/SizeOpt/MostlyZeroFinder.java: Branch csa-ecoop04 (transactions work) updated to CVS head. 2004-06-25 C. Scott Ananian * Analysis/Transactions/AltArrayTransformer.java: The beginnings of code to substitute an alternate array implementation for the standard java one. Imported from csa-ecoop04 branch. Big problems with such an approach: how does it communicate with JNI code? [we give new implementations to the JNI array-access methods?] How does it communicate with ObjectBuilder? [esp for strings] * Runtime/AltArray/ArrayImplJavaType.jt, Runtime/AltArray/ChunkArrayJavaType.jt, Runtime/AltArray/SimpleArrayJavaType.jt: Array implementations should have a length() method. [Change imported from csa-ecoop04 branch.] * Backend/Runtime1/DataReflectionMemberList.java: Update javadoc to explicitly mention that we emit reflection tables for Constructor objects. Add a more-sophisticated 'isConstructor' test that correctly recognizes constructors split by the initializer transform. * Backend/Runtime1/class-root.properties, Backend/Runtime1/method-root.properties: Some updates to the root sets for classpath 0.08, having to do with gnu.java.security.provider.Gnu. 2004-05-26 C. Scott Ananian * Backend/Runtime1/init-safe.properties, Support/cpvm.jar: Update to classpath 0.08. * Backend/Runtime1/DataReflection1.java: Support Class.constructor cache field of classpath 0.08. * bin/run-java: CLASSPATH home should point to the *installed* home of classpath, not the uninstalled location of the sources (this makes it consistent with the Runtime configuration, which also points to the installed prefix). 2004-04-22 C. Scott Ananian * Backend/Runtime1/init-safe.properties: Update to classpath 0.08. 2004-04-21 C. Scott Ananian * GNUmakefile: Tag properties files for classpath 0.07. Classpath 0.08 has been released now. 2004-04-05 C. Scott Ananian * GNUmakefile: Update the canonical web host. * Backend/Runtime1/init-safe.properties: More fixes for classpath 0.07. * Backend/Runtime1/init-safe.properties: Updates to support classpath v0.07. 2004-03-19 C. Scott Ananian * Analysis/PointerAnalysis/ParIntGraph.java: PAField isn't checked in. 2004-03-06 salcianu * Util/LightBasicBlocks/LightBasicBlock.java, Analysis/MetaMethods/MetaCallGraphImpl.java, Analysis/PointerAnalysis/Debug.java, Analysis/PointerAnalysis/MAInfo.java, Analysis/PointerAnalysis/ODMAInfo.java, Analysis/PointerAnalysis/ODPointerAnalysis.java, Analysis/PointerAnalysis/ParIntGraph.java, Analysis/PointerAnalysis/PointerAnalysis.java, Analysis/PointerAnalysis/Stats.java, Analysis/MemOpt/Util.java, Analysis/DataFlow/InstrSolver.java: Small changes throughout the code. SCComponent internals has been changed to not use TreeSet: it requires a well-defined Comparator, and coming up with one that works for any objects it's non trivial. The new implementation uses harpoon.Util.ArraySet for small strongly connected components and HashSets for the others. 2004-03-05 salcianu * Analysis/PointerAnalysis/Debug.java, Analysis/PointerAnalysis/ODPointerAnalysis.java, Analysis/PointerAnalysis/PointerAnalysis.java, Analysis/PointerAnalysis/PointerAnalysisCompStage.java, Analysis/PointerAnalysis/Stats.java: More cleaning * Util/LightBasicBlocks/CachingSCCLBBFactory.java, Util/LightBasicBlocks/SCCLBBFactory.java, Analysis/MetaMethods/MetaCallGraphImpl.java, Analysis/PointerAnalysis/Debug.java, Analysis/PointerAnalysis/MAInfo.java, Analysis/PointerAnalysis/ODMAInfo.java, Analysis/PointerAnalysis/ODPointerAnalysis.java, Analysis/PointerAnalysis/PointerAnalysis.java, Analysis/PointerAnalysis/Stats.java, Analysis/MemOpt/Util.java: more code cleaning + GJ 2004-03-04 salcianu * Util/LightBasicBlocks/CachingSCCLBBFactory.java, Util/LightBasicBlocks/SCCLBBFactory.java, Util/BasicBlocks/CachingSCCBBFactory.java, Util/BasicBlocks/SCCBBFactory.java, Analysis/MemOpt/Util.java, Analysis/MetaMethods/MetaCallGraph.java, Analysis/MetaMethods/MetaCallGraphImpl.java, Analysis/PointerAnalysis/Debug.java, Analysis/PointerAnalysis/MAInfo.java, Analysis/PointerAnalysis/ODMAInfo.java, Analysis/PointerAnalysis/ODPointerAnalysis.java, Analysis/PointerAnalysis/PointerAnalysis.java, Analysis/PointerAnalysis/Stats.java, Analysis/PointerAnalysis/SyncElimination.java, Analysis/CallGraph.java: 1. Code cleaning in the harpoon.Util.Graphs package - the code of one class from that package was recently qualified as "crazy mess", so I had to do some cleaning. Unfortunately, I was unable to get the generic types working so I put the generic types only as comments. The GJ errors I got are very un-informative; e.g., "Type error; expected Vertex[]; found Vertex[] and so on. As the graph package is used in many places, I would be happy to have it GJized at some point. We now have a pretty decent digraph library: directed graphs, component graphs, topologically sorted component graphs, navigators, dfs etc. 2. Modified some files to cope with changes from harpoon.Util.Graphs 3. Deleted the unused harpoon.Analysis.PointerAnalysis.SyncElimination. 2004-02-09 C. Scott Ananian * bin/cvsblame.pl: Remove '-l' option to cvs command, since the latest versions of cvs no longer support it. 2004-02-08 C. Scott Ananian * GNUmakefile: Refer to the JDK 1.5.0 version of the standard doc API. * Util/Collections/package.html: Try to make the migration to JUtil clearer in the docs. * GNUmakefile: bin/jsr14-2.0 has been removed. * GNUmakefile, bin/find-gj, bin/jsr14-2.0, bin/run-java: Better support for locating a Java 1.5 compiler. The script bin/find-gj is now responsible, and checks jikes, javac, $JSR14DISTR/scripts/javac, etc. The bin/run-java script will also use bin/find-gj to invoke $JSR14DISTR/scripts/java if necessary. * IR/Assem/Instr.java, Tools/Annotation/Java12.cup, Analysis/Quads/DispatchTreeTransformation.java, Analysis/Quads/MemoryOptimization.java, Analysis/Quads/QuadClassHierarchy.java, Backend/Runtime1/DataClaz.java, ClassFile/Relinker.java, Analysis/LowQuad/Loop/LoopOptimize.java, Analysis/PointerAnalysis/ActionRepository.java, Analysis/PointerAnalysis/MAInfo.java, Analysis/PointerAnalysis/ODMAInfo.java, Analysis/PointerAnalysis/SyncElimination.java: More automatic for-conversions; these classes had some cases which fooled the bin/replace-for.perl script and so had to be reviewed manually. * IR/Properties/UseDefer.java: Don't throw away parameterization. 2004-02-07 C. Scott Ananian * Analysis/Instr/AppelRegAlloc.java, Analysis/Instr/AppelRegAllocClasses.java, Analysis/Instr/AppelRegAllocStd.java, Analysis/Instr/LocalCffRegAlloc.java: Generic-ify some register allocator classes. Also do some for-conversion. * Analysis/Quads/AbstrCallGraph.java, Analysis/CallGraph.java: Generic-ify Alex's Graph classes. SCComponent was skipped, for the most part, because it's a crazy mess, and because some arrays would have to be turned into Lists for the parameterized types to work right. * Util/TypeInference/ArrayInfo.java, Util/TypeInference/TypeInference.java, Util/Options/Option.java, Util/Collections/AbstractGraph.java, Util/Graph.java, Instrumentation/AllocationStatistics/AllocationNumberingStub.java, Instrumentation/AllocationStatistics/AllocationStatistics.java, Instrumentation/AllocationStatistics/InstrumentAllocs.java, Instrumentation/AllocationStatistics/InstrumentAllocs2.java, Interpret/Tree/OffsetMap32.java, Main/CompStagePipeline.java, Main/SAMain.java, Main/Sizer.java, IR/Quads/Pattern.java, IR/Quads/Prune.java, IR/Quads/Quad.java, IR/Quads/QuadSSI.java, IR/Quads/ReHandler.java, IR/Quads/ResilientUnHandler.java, IR/Quads/SSIRename.java, IR/Quads/TESTER.java, IR/Quads/Translate.java, IR/Quads/UnHandler.java, IR/Tree/ToTree.java, ClassFile/HClassArraySyn.java, ClassFile/Loader.java, IR/Jasmin/Jasmin.java, Backend/RuntimeTiny/CompleteClazNumbering.java, Backend/RuntimeTiny/DataClazTable.java, Backend/RuntimeTiny/TinyClassFieldMap.java, Backend/StrongARM/AccelRFInfo.java, Backend/StrongARM/Code.java, Backend/Generic/GCInfo.java, Backend/Generic/MaxMunchCG.java, Backend/PreciseC/Frame.java, Backend/PreciseC/TreeToC.java, Backend/Runtime1/DataGC.java, Backend/Runtime1/DataInitializers.java, Backend/Runtime1/DataInterfaceList.java, Backend/Runtime1/DataReflection1.java, Backend/Runtime1/DataReflection2.java, Backend/Runtime1/DataReflectionMemberList.java, Backend/Runtime1/ObjectBuilder.java, Backend/Analysis/BasicGCInfo.java, Backend/Analysis/ClassFieldMap.java, Backend/Analysis/InitializerOrdering.java, Backend/Analysis/MakeGCThreadSafe.java, Backend/CSAHack/FlowGraph/AssemFlowGraph.java, Backend/CSAHack/RegAlloc/DerivationGenerator.java, Backend/CSAHack/RegAlloc/RegAlloc.java, Backend/CSAHack/RegAlloc/Spiller.java, Analysis/Tree/AlignmentAnalysis.java, Analysis/Tree/DominatingMemoryAccess.java, Analysis/Tree/TreeFolding.java, Analysis/TypeInference/IntraProc.java, Analysis/SizeOpt/BitWidthAnalysis.java, Analysis/SizeOpt/ConstructorClassifier.java, Analysis/SizeOpt/Field2Method.java, Analysis/SizeOpt/FieldReducer.java, Analysis/SizeOpt/MZFChooser.java, Analysis/SizeOpt/MZFCompressor.java, Analysis/SizeOpt/MZFExternalize.java, Analysis/SizeOpt/MZFWidenType.java, Analysis/SizeOpt/MostlyZeroFinder.java, Analysis/SizeOpt/ProfileParser.java, Analysis/SizeOpt/SizeCounters.java, Analysis/Transactions/CloneImplementer.java, Analysis/Transactions/GlobalFieldOracle.java, Analysis/Transactions/SyncTransformer.java, Analysis/Transactions/TreeDataFilter.java, Analysis/Transactions/TreePostPass.java, Analysis/Quads/CachingCallGraph.java, Analysis/Quads/CallGraphImpl2.java, Analysis/Quads/CollectSyncStats.java, Analysis/Quads/DefiniteInitOracle.java, Analysis/Quads/FieldSyncOracle.java, Analysis/Quads/InitializerTransform.java, Analysis/Quads/NewMover.java, Analysis/Quads/QuadInterferenceGraph.java, Analysis/Quads/SSIToSSAMap.java, Analysis/Quads/SmallMethodInliner.java, Analysis/Realtime/CheesyPACheckRemoval.java, Analysis/Realtime/PACheckRemoval.java, Analysis/Realtime/ThreadToRealtimeThread.java, Analysis/RoleInference/RoleInference.java, Analysis/PointerAnalysis/AbstrPAEdgeSet.java, Analysis/PointerAnalysis/AllocSyncOptCompStage.java, Analysis/PointerAnalysis/ComputeInterProcMuClosure.java, Analysis/PointerAnalysis/Debug.java, Analysis/PointerAnalysis/EdgeOrdering.java, Analysis/PointerAnalysis/EdgesNCallees.java, Analysis/PointerAnalysis/InterProcPA.java, Analysis/PointerAnalysis/InterThreadPA.java, Analysis/PointerAnalysis/LightPAEdgeSet.java, Analysis/PointerAnalysis/Matching.java, Analysis/PointerAnalysis/MethodHole.java, Analysis/PointerAnalysis/NodeRepository.java, Analysis/PointerAnalysis/ODInformation.java, Analysis/PointerAnalysis/ODInterProcPA.java, Analysis/PointerAnalysis/ODParIntGraph.java, Analysis/PointerAnalysis/ODPointerAnalysis.java, Analysis/PointerAnalysis/PAEdge.java, Analysis/PointerAnalysis/PAEscapeFunc.java, Analysis/PointerAnalysis/PARTJSupportCompStage.java, Analysis/PointerAnalysis/PASync.java, Analysis/PointerAnalysis/PAThreadMap.java, Analysis/PointerAnalysis/ParIntGraph.java, Analysis/PointerAnalysis/PointerAnalysis.java, Analysis/PointerAnalysis/PointerAnalysisCompStage.java, Analysis/PointerAnalysis/PointsToGraph.java, Analysis/PointerAnalysis/Stats.java, Analysis/PreciseGC/AllocationHoisting.java, Analysis/PreciseGC/DynamicWBInserter.java, Analysis/PreciseGC/DynamicWBQuadPass.java, Analysis/PreciseGC/MRAFactory.java, Analysis/PreciseGC/RCTransformer.java, Analysis/PreciseGC/WriteBarrierStats.java, Analysis/Quads/ArrayUnroller.java, Analysis/MemOpt/AddMemoryPreallocation.java, Analysis/MemOpt/ComputeAnAe.java, Analysis/MemOpt/IAStatistics.java, Analysis/MemOpt/IncompatibilityAnalysis.java, Analysis/MemOpt/MultiMapUtils.java, Analysis/MemOpt/PreallocData.java, Analysis/MemOpt/PreallocOpt.java, Analysis/MemOpt/SSILiveness.java, Analysis/MemOpt/Util.java, Analysis/MetaMethods/FakeMetaCallGraph.java, Analysis/MetaMethods/MetaAllCallers.java, Analysis/MetaMethods/MetaCallGraphAbstr.java, Analysis/MetaMethods/MetaCallGraphImpl.java, Analysis/MetaMethods/SmartCallGraph.java, Analysis/Loops/LoopFinder.java, Analysis/LowQuad/Loop/MyLowQuadNoSSA.java, Analysis/EventDriven/CloningVisitor.java, Analysis/EventDriven/ToAsync.java, Analysis/GraphColoring/OptimisticGraphColorer.java, Analysis/GraphColoring/SimpleGraphColorer.java, Analysis/Instr/AppelRegAllocClasses.java, Analysis/Instr/AppelRegAllocFsk.java, Analysis/Instr/BasePointerPreservingUseDefer.java, Analysis/Instr/Check.java, Analysis/Instr/GraphColoringRegAlloc.java, Analysis/Instr/RegAlloc.java, Analysis/Instr/RegAllocOpts.java, Analysis/Instr/RegFile.java, Analysis/Instr/SpillHeuristics.java, Analysis/Instr/Verify.java, Analysis/DataFlow/BackwardDataFlowBasicBlockVisitor.java, Analysis/DataFlow/ForwardDataFlowBasicBlockVisitor.java, Analysis/DataFlow/LiveTemps.java, Analysis/DataFlow/LiveVars.java, Analysis/DataFlow/ReachingDefs.java, Analysis/DataFlow/ReachingHCodeElements.java, Analysis/DynamicSyncRemoval/SyncRemover.java, Analysis/AbstractClassFixupRelinker.java, Analysis/AllCallers.java, Analysis/Companions/DataFlowSolver.java, Analysis/Companions/SingularFinder.java, Analysis/DomFrontier.java, Analysis/EdgesIterator.java, Analysis/Place.java, Analysis/Reachable.java, Analysis/ReachingDefsAltImpl.java, Analysis/ReachingDefsCachingImpl.java, Analysis/ReachingDefsImpl.java, Analysis/SESE.java, Analysis/SSxReachingDefsImpl.java, Analysis/UseDef.java, Analysis/UseDefChecker.java: Bulk convert all code to the new for-each statement syntax, using the bin/replace-for.perl script: bin/munge . | bin/replace-for.perl | bin/unmunge It's not perfect --- it doesn't detect when the Iterator.remove() method is used, for example --- but it does a pretty good job. * bin/replace-for.perl: Allow 'final' modifier; allow specifying full package name of Iterator and Arrays. Fix the non-parameterized case: you must include an explicit cast from Object; the sugar won't do it for you (too bad!). * Tools/Annotation/Java12.cup, Tools/PatMat/CodeGeneratorGenerator.java, Tools/PatMat/Spec.java, bin/annotate.perl, bin/replace-jutil.perl, bin/run-java, Temp/LabelList.java, Temp/Temp.java, Temp/TempFactory.java, Support/gjlib2.jar, Support/jutil.jar, Support/gjlib.jar, Main/CHStats.java, Main/CallGraph.java, Main/CodeGenerator.java, Main/CompStagePipeline.java, Main/CompilerStageEZ.java, Main/CompilerState.java, Main/EDMain.java, Main/EDXMain.java, Main/EventDriven.java, Main/JMain.java, Main/Lint.java, Main/SAMain.java, ClassFile/HClass.java, ClassFile/HClassArray.java, ClassFile/HClassImpl.java, ClassFile/HClassProxy.java, ClassFile/HCode.java, ClassFile/Linker.java, ClassFile/Loader.java, ClassFile/Relinker.java, Instrumentation/AllocationStatistics/InstrumentAllocs.java, Instrumentation/AllocationStatistics/InstrumentAllocs2.java, Interpret/Tree/InterpreterOffsetMap.java, Interpret/Tree/OffsetMap32.java, Backend/Sparc/RegFileInfo.java, Backend/StrongARM/AccelRFInfo.java, Backend/StrongARM/Code.java, Backend/StrongARM/CodeGen.spec, Backend/StrongARM/InstrBuilder.java, Backend/StrongARM/RegFileInfo.java, Backend/PreciseC/Frame.java, Backend/PreciseC/IdentifyNoHandler.java, Backend/PreciseC/TreeToC.java, Backend/Runtime1/DataInterfaceList.java, Backend/RuntimeTiny/Runtime.java, Backend/Sparc/CodeGen.spec, Backend/Generic/InstrBuilder.java, Backend/Generic/MaxMunchCG.java, Backend/Generic/RegFileInfo.java, Backend/MIPS/Code.java, Backend/MIPS/CodeGen.spec, Backend/MIPS/RegFileInfo.java, Backend/Maps/CHFinalMap.java, Backend/Analysis/ClassFieldMap.java, Backend/Analysis/InitializerOrdering.java, Backend/Analysis/InterfaceMethodMap.java, Backend/CSAHack/RegAlloc/DerivationGenerator.java, Backend/CSAHack/RegAlloc/RegAlloc.java, Util/Collections/AbstractGraph.java, Util/Collections/AbstractHeap.java, Util/Collections/AbstractMapEntry.java, Util/Collections/AggregateMapFactory.java, Util/Collections/AggregateSetFactory.java, Util/Collections/BinaryHeap.java, Util/Collections/BinaryTree.java, Util/Collections/BinomialHeap.java, Util/Collections/BitSetFactory.java, Util/Collections/CollectionFactory.java, Util/Collections/CollectionWrapper.java, Util/Collections/DisjointSet.java, Util/Collections/Environment.java, Util/Collections/Factories.java, Util/Collections/FibonacciHeap.java, Util/Collections/GenericInvertibleMap.java, Util/Collections/GenericInvertibleMultiMap.java, Util/Collections/GenericMultiMap.java, Util/Collections/Graph.java, Util/Collections/HashEnvironment.java, Util/Collections/Heap.java, Util/Collections/IntervalTree.java, Util/Collections/InvertibleMap.java, Util/Collections/InvertibleMultiMap.java, Util/Collections/LinearMap.java, Util/Collections/LinearSet.java, Util/Collections/ListFactory.java, Util/Collections/ListWrapper.java, Util/Collections/MapFactory.java, Util/Collections/MapSet.java, Util/Collections/MapWrapper.java, Util/Collections/MultiMap.java, Util/Collections/MultiMapFactory.java, Util/Collections/MultiMapSet.java, Util/Collections/PairMapEntry.java, Util/Collections/PersistentEnvironment.java, Util/Collections/PersistentMap.java, Util/Collections/PersistentMapFactory.java, Util/Collections/PersistentSet.java, Util/Collections/PersistentSetFactory.java, Util/Collections/PersistentTreeNode.java, Util/Collections/RedBlackTree.java, Util/Collections/ReverseIterator.java, Util/Collections/ReverseListIterator.java, Util/Collections/SetFactory.java, Util/Collections/SetWrapper.java, Util/Collections/SnapshotIterator.java, Util/Collections/TestMap.java, Util/Collections/TestSet.java, Util/Collections/UniqueStack.java, Util/Collections/UniqueVector.java, Util/Collections/UnmodifiableIterator.java, Util/Collections/UnmodifiableListIterator.java, Util/Collections/UnmodifiableMultiMap.java, Util/Collections/WorkSet.java, Util/BitString.java, Util/CloneableIterator.java, Util/CombineIterator.java, Util/Default.java, Util/EnumerationIterator.java, Util/FilterIterator.java, Util/HClassUtil.java, Util/Indexer.java, Util/IteratorEnumerator.java, Util/ListComparator.java, Util/MapComparator.java, Util/ReferenceUnique.java, Util/SortedMapComparator.java, Util/Tuple.java, Util/Util.java, IR/Tree/Code.java, IR/Tree/ExpList.java, IR/Tree/ToTree.java, IR/Tree/ToTreeHelpers.java, IR/Tree/Tree.java, IR/Tree/TreeFactory.java, IR/Tree/TreeGrapher.java, IR/Tree/TreeUseDefer.java, IR/Properties/CFGrapher.java, IR/Properties/UseDefer.java, IR/Quads/Code.java, IR/Quads/HANDLER.java, IR/Quads/HandlerSet.java, IR/Quads/Pattern.java, IR/Quads/Peephole.java, IR/Quads/Prune.java, IR/Quads/Quad.java, IR/Quads/RSSxToNoSSA.java, IR/Quads/ReHandler.java, IR/Quads/ReHandlerToSSA.java, IR/Quads/ResilientUnHandler.java, IR/Quads/SSIRename.java, IR/Quads/SSIToSSA.java, IR/Quads/TESTER.java, IR/Quads/ToNoSSA.java, IR/Quads/Translate.java, IR/Quads/UnHandler.java, IR/Bytecode/Liveness.java, IR/Jasmin/Jasmin.java, IR/LowQuad/DerivationMap.java, IR/Assem/Code.java, IR/Assem/Instr.java, IR/Assem/InstrGroup.java, IR/Assem/InstrLABEL.java, Analysis/TypeInference/InterProc.java, Analysis/Transactions/AnalysisCheckOracle.java, Analysis/Transactions/DominatingCheckOracle.java, Analysis/Transactions/GlobalFieldOracle.java, Analysis/Transactions/HoistingCheckOracle.java, Analysis/Transactions/SyncTransformer.java, Analysis/Transactions/TreeDataFilter.java, Analysis/Transformation/MethodSplitter.java, Analysis/Tree/AlgebraicSimplification.java, Analysis/Tree/AlignmentAnalysis.java, Analysis/Tree/CacheEquivalence.java, Analysis/Tree/DominatingMemoryAccess.java, Analysis/Tree/JumpOptimization.java, Analysis/Tree/TreeFolding.java, Analysis/RoleInference/RoleInference.java, Analysis/SizeOpt/BitWidthAnalysis.java, Analysis/SizeOpt/ConstructorClassifier.java, Analysis/SizeOpt/Field2Method.java, Analysis/SizeOpt/FieldReducer.java, Analysis/SizeOpt/MZFChooser.java, Analysis/SizeOpt/MZFCompressor.java, Analysis/SizeOpt/MZFExternalize.java, Analysis/SizeOpt/MZFWidenType.java, Analysis/SizeOpt/MostlyZeroFinder.java, Analysis/SizeOpt/ProfileParser.java, Analysis/SizeOpt/SizeCounters.java, Analysis/Quads/SCC/SCCAnalysis.java, Analysis/Quads/SCC/SCCOptimize.java, Analysis/Realtime/CheckAdder.java, Analysis/Realtime/ClassReplacer.java, Analysis/Realtime/QuantaChecker.java, Analysis/Realtime/Realtime.java, Analysis/PreciseGC/MRAFactory.java, Analysis/PreciseGC/WriteBarrierQuadPass.java, Analysis/Quads/ArrayCopyInliner.java, Analysis/Quads/ArrayUnroller.java, Analysis/Quads/BasicCSE.java, Analysis/Quads/CallGraphImpl.java, Analysis/Quads/CallGraphImpl2.java, Analysis/Quads/CoalescingToNoSSA.java, Analysis/Quads/ComponentOfReducer.java, Analysis/Quads/DeadCode.java, Analysis/Quads/DefiniteInitOracle.java, Analysis/Quads/FieldSyncOracle.java, Analysis/Quads/InitializerTransform.java, Analysis/Quads/MayReadOracle.java, Analysis/Quads/MemoryOptimization.java, Analysis/Quads/MethodTraceFactory.java, Analysis/Quads/NewMover.java, Analysis/Quads/Nonvirtualize.java, Analysis/Quads/QuadClassHierarchy.java, Analysis/Quads/QuadInterferenceGraph.java, Analysis/Quads/QuadLiveness.java, Analysis/Quads/SSIToSSAMap.java, Analysis/Quads/SmallMethodInliner.java, Analysis/Quads/TypeSwitchRemover.java, Analysis/Quads/Unreachable.java, Analysis/Quads/Virtualize.java, Analysis/MemOpt/IncompatibilityAnalysis.java, Analysis/MemOpt/MultiMapUtils.java, Analysis/MemOpt/MyGraphColorer.java, Analysis/MemOpt/SSILiveness.java, Analysis/Partition/Profile.java-old, Analysis/PointerAnalysis/ActionRepository.java, Analysis/PointerAnalysis/MAInfo.java, Analysis/PointerAnalysis/ODInterProcPA.java, Analysis/PointerAnalysis/ODMAInfo.java, Analysis/PointerAnalysis/PointerAnalysis.java, Analysis/PointerAnalysis/PointerAnalysisCompStage.java, Analysis/PointerAnalysis/PointsToGraph.java, Analysis/PointerAnalysis/SyncElimination.java, Analysis/Loops/LoopFinder.java, Analysis/Loops/Loops.java, Analysis/LowQuad/Loop/AllInductions.java, Analysis/LowQuad/Loop/BasicInductions.java, Analysis/LowQuad/Loop/LoopAnalysis.java, Analysis/LowQuad/Loop/LoopInvariance.java, Analysis/LowQuad/Loop/LoopMap.java, Analysis/LowQuad/Loop/LoopOptimize.java, Analysis/Maps/ExecMapProxy.java, Analysis/GraphColoring/AbstractGraph.java, Analysis/GraphColoring/Graph.java, Analysis/GraphColoring/GraphImpl.java, Analysis/GraphColoring/OptimisticGraphColorer.java, Analysis/GraphColoring/SimpleGraphColorer.java, Analysis/GraphColoring/SparseGraph.java, Analysis/GraphColoring/SparseNode.java, Analysis/Instr/AppelRegAlloc.java, Analysis/Instr/AppelRegAllocClasses.java, Analysis/Instr/AppelRegAllocFsk.java, Analysis/Instr/AppelRegAllocStd.java, Analysis/Instr/EqTempSets.java, Analysis/Instr/GraphColoringRegAlloc.java, Analysis/Instr/HTempMap.java, Analysis/Instr/LocalCffRegAlloc.java, Analysis/Instr/RegAlloc.java, Analysis/Instr/SpillHeuristics.java, Analysis/Instr/Verify.java, Analysis/Instr/WeightedSet.java, Analysis/DynamicSyncRemoval/SyncRemover.java, Analysis/EnvBuilder/EnvBuilder.java, Analysis/EventDriven/AsyncCode.java, Analysis/EventDriven/CloningVisitor.java, Analysis/EventDriven/EventDriven.java, Analysis/EventDriven/LockRemove.java, Analysis/EventDriven/ToAsync.java, Analysis/Counters/EpilogMutator.java, Analysis/Counters/RuntimeMethodCloner.java, Analysis/DataFlow/BackwardDataFlowBasicBlockVisitor.java, Analysis/DataFlow/CachingLiveTemps.java, Analysis/DataFlow/DataFlowBasicBlockVisitor.java, Analysis/DataFlow/ForwardDataFlowBasicBlockVisitor.java, Analysis/DataFlow/InstrSolver.java, Analysis/DataFlow/LiveTemps.java, Analysis/DataFlow/LiveVars.java, Analysis/DataFlow/ReachingDefs.java, Analysis/DataFlow/ReachingHCodeElements.java, Analysis/DataFlow/ReversePostOrderEnumerator.java, Analysis/DataFlow/Solver.java, Analysis/DataFlow/SpaceHeavyLiveTemps.java, Analysis/DataFlow/TreeSolver.java, Analysis/Companions/DataFlowSolver.java, Analysis/Companions/QuadFlowGraph.java, Analysis/Companions/SingularFinder.java, Analysis/Companions/StaticValue.java, Analysis/AbstractClassFixupRelinker.java, Analysis/BasicBlock.java, Analysis/ClassHierarchy.java, Analysis/CycleEq.java, Analysis/DomFrontier.java, Analysis/DomTree.java, Analysis/EdgesIterator.java, Analysis/FCFGBasicBlock.java, Analysis/GenericContextFactory.java, Analysis/Place.java, Analysis/PointsToAnalysis.java, Analysis/Reachable.java, Analysis/ReachingDefsAltImpl.java, Analysis/ReachingDefsCachingImpl.java, Analysis/ReachingDefsImpl.java, Analysis/SESE.java, Analysis/SSxReachingDefsImpl.java, Analysis/UseDef.java, GNUmakefile, gj-files, gj-files-2: Discard multi-stage compile: as of this commit, all code in FLEX builds with the 2.4a1 version of the JSR14 compiler, or, equivalently the 1.5.0b1 JDK. Removed gj-files, gj-files-2, Support/gjlib.jar, and Support/gjlib2.jar, as they are unnecessary now that all of our code can be compiled with a single compiler. Most code in harpoon.Util.Collections (and some in harpoon.Util) has been split out into a separate 'JUtil' package, available from: http://cscott.net/Projects/JUtil/ A binary .jar of JUtil is in Support/jutil.jar. Some javadoc and makefile rules have been changed to indicate this; there has also been a large-scale search-and-replace on 'import' statements to migrate to JUtil's package. [bin/annotate.perl might not work on the sinjdoc-generated JUtil documentation yet; this should be fixed.] Most of the necessary changes to upgrade to the latest JSR14 spec occurred in the JUtil package, as collections implementations were most heavily affected by the addition of variance to the type system. The 'Worklist' interface was not migrated to JUtil, and JUtil's 'WorkSet' does not implement it. We've added a bridge implementation of WorkSet (Util/Collections/WorkSet.java) which does implement Worklist to aid migration; in some places we've also changed 'Worklist' in interfaces to 'WorkSet' (see DataFlowBasicBlockVisitor.java, for example). [WorkSet is generally unnecessary now that the JDK includes java.util.LinkedHashSet, but is included for backward-compatibility.] The CombineIterator constructor is slightly different in JUtil as well, since arrays of parameterized types are no longer allowed; Main/EDMain.java and Main/EDXMain.java contain corresponding adjustments. Other changes required by the latest JSR14 compiler: The latest compiler does not allow creation of generic arrays ('new E[]' where E is a type variable); we've followed the strategy used by java.util.ArrayList of explicitly casting a 'new Object[]' to an 'E[]'. [Analysis/GenericContextFactory.java'] Mutually-recursive classes required a little bit of tweaking, as the scope rules changed such that inner classes are not in-scope at type-variable declaration time. [Analysis/PointsToAnalysis.java, Util/Collections/AbstractGraph.java, Util/Collections/Graph.java] Arrays of parameterized types are verboten; all instances of these were changed to Lists of the parameterized type. [Analysis/Quads/ArrayUnroller.java, Analysis/Quads/MemoryOptimization.java, Analysis/Quads/QuadLiveness.java] There is another slight JSR14-compiler bug [reported to Sun] with 'instanceof' comparisons of variables whose type is parameterized. An explicit type cast to the raw type is required to work around this. [Analysis/Maps/ExecMapProxy.java] Another minor bug [reported to Sun] exists with type-resolution in constructor invocations; a few places in FLEX require explicit casts on the constructor's arguments to work around this. [Analysis/BasicBlock.java, Analysis/DomTree.java, Analysis/Reachable.java, Analysis/ReachingDefsAltImpl.java, Analysis/ReachingDefsImpl.java, Analysis/SSxReachingDefsImpl.java, Analysis/RoleInference/RoleInference.java] Some classes were slightly generified to play nicely with other generified code. [Analysis/PointerAnalysis/PointerAnalysisCompStage, Backend/MIPS/CodeGen.spec, Backend/Sparc/CodeGen.spec, Backend/StrongARM/CodeGen.spec, IR/Quads/Code.java, IR/Quads/SSIRename.java, Temp/LabelList.java, Util/ListComparator.java, Util/MapComparator.java, Util/SortedMapComparator.java] We gave more-specific types to clone() methods. [ClassFile/HCode.java, Temp/Temp.java, Util/CloneableIterator.java] In one case, a work-around for an earlier versions of the JSR14 compiler was removed. [IR/Assem/InstrGroup.java] * bin/replace-for.perl: Extend the 'replace-for' script to handle for-Iterator loops masquerading as while loops as well (which is found in some old crufty bits of FLEX). * Support/gjlib2.jar, IR/Tree/ToTreeHelpers.java, IR/Tree/TreeGrapher.java, Support/gjlib.jar, IR/Bytecode/Instr.java, IR/Properties/CFGraphable.java, IR/Properties/CFGrapher.java, IR/Quads/Quad.java, Analysis/Tree/JumpOptimization.java, Backend/Analysis/BasicGCInfo.java, IR/Assem/Instr.java, IR/Assem/InstrGroup.java, IR/Assem/InstrLABEL.java, Analysis/DataFlow/ReachingDefs.java, Analysis/Loops/LoopFinder.java, Analysis/Transactions/HoistingCheckOracle.java, Analysis/BasicBlock.java, Analysis/EdgesIterator.java: Removed edge/pred/succ methods from CFGrapher/CFGraphable; these have been deprecated for a while, and are replaced with edgeC/predC/succC. The edge/pred/succ methods can't be ported to Java 1.5 because of their use of arrays of parameterized types. Also changed the signature for edgeC/predC/succC from Collection to List, because various bits of old code used the array returned by edge/pred/succ as a list (i.e. depended on the consistent order of the items in the array). This required some cascading changes to the code. Updated gjlib and gjlib2 after these changes. * Util/ArrayIterator.java: Extended ArrayIterator to make it implement ListIterator, not just Iterator. 2004-01-30 C. Scott Ananian * Util/Collections/package.html: Tweak Util.Collections package documentation a bit. * Analysis/BasicBlock.java: Remove unused deprecated methods. * Support/jutil.jar, GNUmakefile, bin/replace-jutil.perl: Add JUtil package to FLEX. * Analysis/MemOpt/IncompatibilityAnalysis.java, Analysis/MemOpt/MultiMapUtils.java, Analysis/MemOpt/SSILiveness.java, Analysis/AbstractClassFixupRelinker.java: Remove "import *" statements. 2004-01-13 C. Scott Ananian * bin/replace-for.perl: Extend the script to better handle wildcard types. 2004-01-12 C. Scott Ananian * Support/gjlib2.jar, Support/gjlib.jar: Update gjlib.jar/gjlib2.jar. * bin/jsr14-2.0: Un-hard-code /home/cananian. 2003-12-07 C. Scott Ananian * Analysis/Transactions/SyncTransformer.java, Analysis/Transactions/TreePostPass.java, Main/Transactions.java: Hack and chop out the readflags and array bloat stuff. * Analysis/Transactions/AltArrayTransformer.java: New file. * Analysis/Transactions/AltArrayTransformer.java, gj-files: Start implementation of transformation code that will rewrite array accesses to chunk (etc) them. * Runtime/AltArray/ArrayImplJavaType.jt, Runtime/AltArray/ChunkArrayJavaType.jt, Runtime/AltArray/SimpleArrayJavaType.jt: Tweak AltArray implementation to support two other operations done on arrays: ALENGTH and COMPONENTOF. 2003-12-01 C. Scott Ananian * IR/Tree/ToTree.java: Fix multi-dim array initialization with array bloat. 2003-11-14 C. Scott Ananian * Backend/Runtime1/DataReflection1.java: Static class objects should have appropriate read flags. * Analysis/Transactions/BitFieldNumbering.java, Analysis/Transactions/SyncTransformer.java: Added explicit fields to each object to hold transaction list and reader list. Ignore these when doing the bitfieldnumbering. * Analysis/Transactions/TreeDataFilter.java: Reserve enough space for 64-bit archs. * Analysis/Transactions/BitFieldNumbering.java, Analysis/Transactions/SyncTransformer.java, Analysis/Transactions/TreePostPass.java, Backend/Runtime1/DataStrings.java, Backend/Runtime1/ObjectBuilder.java, Backend/Runtime1/TreeBuilder.java, Main/Transactions.java, Analysis/SizeOpt/MostlyZeroFinder.java: Change array representation to allow for 1 bit-per-element read flags. All read flags are at the start of the array to make alignment simple; we can think about re-doing to representation to distribute the bits among the elements later. BitFieldNumbering no longer reserves space in object for the array flags. Also made read flags 64-bit safe (untested). BitFieldNumbering now allocates longs instead of ints on 64-bit platforms. Prototypes of C interface functions have changed; tweak TreePostPass to match. DataStrings needs to know about the read flags for java.lang.String, since they're not bundled into Object any more. ObjectBuilder needs to emit appropriate read flags when it emits arrays. TreeBuilder pads the array size appropriately to allow for flags. * Backend/PreciseC/TreeToC.java: Fix the following former bug in TreeToC: // XXX: another buglet here: the ToTree transformation can // create dead code by converting CJUMP(0, iffalse, iftrue) to // JUMP(iffalse) (similarly with non-zero constants). If this // happens, then eventually we'll try to translate the dead // code. If there is a CALL in the dead code, then we'll ask // the LiveVars about it, and the LiveVars will assert because // the CALL is not found in its basic block set. We should // probably attempt to skip translation of executable (ie non-data) // Trees which are not live. --CSA 13-mar-2003 We fix this by adding a call to Reachable, which identifies (un)reachable code in the Tree form. We then avoid translating unreachable trees. This is a little bit tricky because we don't want to skip SEQ, DATUM, LABEL, ALIGN, etc; or sub-expressions, like the dest and source trees of MOVE for example. I've got a conditional which I think does the trick; a slight side-effect is that gcc now complains about "labels at the end of compound statements". I don't think the warning is serious. * Analysis/Reachable.java: Overly-strict assertion: predecessors of PHI nodes will not be visited before the PHI node is visited. 2003-11-11 C. Scott Ananian * gj-files, Analysis/Reachable.java: Added a simple reachability analysis, used to work around a bug in PreciseC/TreeToC, to wit: // the ToTree transformation can // create dead code by converting CJUMP(0, iffalse, iftrue) to // JUMP(iffalse) (similarly with non-zero constants). If this // happens, then eventually we'll try to translate the dead // code. If there is a CALL in the dead code, then we'll ask // the LiveVars about it, and the LiveVars will assert because // the CALL is not found in its basic block set. We should // probably attempt to skip translation of executable (ie non-data) // Trees which are not live. --CSA 13-mar-2003 2003-11-05 C. Scott Ananian * Analysis/Transactions/SyncTransformer.java: Allow compiling a non-transactional (locking) binary with all the transactional transformations, to allow a more fair apples-to-apples comparison. * bin/build-spec: Prevent concurrent spec builds from overwriting each other's root set. 2003-11-04 salcianu * Main/SAMain.java: extra option info * Analysis/PointerAnalysis/PointerAnalysisCompStage.java: changed default call graph 2003-11-02 C. Scott Ananian * Analysis/Transactions/SyncTransformer.java: Fix problem with noNestedTransactions. 2003-10-30 C. Scott Ananian * Analysis/Transactions/SyncTransformer.java, Analysis/Transactions/TreePostPass.java: Add ISCA functionality to SyncTransformer: allow use of hardware transaction mechanism; also add facility to log transactional/ non-transactional reads and writes for analysis of transaction size, etc. 2003-10-28 salcianu * Analysis/MemOpt/PreallocOpt.java: Old change * Analysis/PointerAnalysis/ComputeInterProcMuClosure.java, Analysis/PointerAnalysis/MAInfo.java, Analysis/PointerAnalysis/PAAllocSyncCompStage.java, Analysis/PointerAnalysis/PointerAnalysis.java: Long-overdue code cleanup: 1. remove useless file 2. manual dead-code elimination 2003-10-27 C. Scott Ananian * Backend/PreciseC/TreeToC.java: Match a fix to runtime: The ISO C99 standard actually defines uint32_t, uint64_t as int types, instead of the legacy u_int32_t, u_int64_t, etc. Replace all occurences of u_intXX_t with uintXX_t to avoid problems, especially on MIPS/IRIX/R6000, where u_int64_t appears not to be defined (but uint64_t is). 2003-10-26 salcianu * Analysis/PointerAnalysis/PointerAnalysis.java: Old changes for the TOPLAS paper * Analysis/PointerAnalysis/NodeRepository.java: Old changes * Analysis/PointerAnalysis/ComputeInterProcMuClosure.java, Analysis/PointerAnalysis/InterProcPA.java: Old changes * Analysis/PointerAnalysis/MAInfo.java, Analysis/PointerAnalysis/PAEscapeFunc.java: Old changes wiating to be commited * Analysis/PointerAnalysis/PointerAnalysisCompStage.java: typo 2003-10-21 C. Scott Ananian * IR/Tree/ToTree.java, Backend/Runtime1/ObjectBuilder.java: Fixed (last?) two 64-bit bugs in FLEX backend: a) add proper padding after length when building arrays in ObjectBuilder b) add an alignment hint in ToTree (for TreeToC) about the last element of a constant initialization table. Otherwise the structure containing this element might be arbitrarily aligned (to 4- or 8-bytes). Also committed a helpful assertion info message in ToTree which has been sitting in my sources for a while. 2003-10-20 C. Scott Ananian * Backend/RuntimeTiny/DataClazTable.java, Backend/RuntimeTiny/ObjectBuilder.java, Backend/Runtime1/DataClaz.java, Backend/Runtime1/DataConfigChecker.java, Backend/Runtime1/DataGC.java, Backend/Runtime1/DataInitializers.java, Backend/Runtime1/DataJavaMain.java, Backend/Runtime1/DataReflection1.java, Backend/Runtime1/DataReflection2.java, Backend/Runtime1/DataReflectionMemberList.java, Backend/Runtime1/DataStaticFields.java, Backend/Runtime1/ObjectBuilder.java, Backend/Runtime1/StubCode.java: Fix pervasive 64-bit alignment problems: we should align all structures containing pointers to a pointer-size boundary. This means ALIGN(8) instead of ALIGN(4) on 64-bit platforms. * Support/gjlib.jar, Support/gjlib2.jar: Update gjlib.jar and gjlib2.jar to keep up with source code and gj-files changes. * gj-files: Add some Runtime stuff to gj-files, as they've acquired dependencies. * Backend/RuntimeTiny/Runtime.java, Backend/Runtime1/DataClaz.java, Backend/Runtime1/DataReflection2.java, Backend/Runtime1/DataReflectionMemberList.java, Backend/Runtime1/Runtime.java, Backend/Runtime1/TreeBuilder.java: Add appropriate padding to our data structures so that pointers are all appropriately aligned on 64-bit platforms. We rearrange the claz data structure slightly in the process (even for 32-bit platforms), so you must update your Runtime concurrently with this update to Code. We also update RuntimeTiny so that the extra information it adds to the claz structure is also 64-bit clean; these updates have not been tested. You're wasting a lot of space by using 64-bit pointers, anyway, so RuntimeTiny will probably be the least of your concerns. * Analysis/Tree/AlgebraicSimplification.java, IR/Tree/BINOP.java: Some 64-bit fixes: even when pointers are long, we allow INT offsets. This requires some silent coercions during algebraic simplification and BINOP evaluation. 2003-10-08 C. Scott Ananian * Backend/PreciseC/TreeToC.java: Add comments to some constants to make it easier to pick our strings in the C source. Work around a structure alignment issue on MIPS by emitting aligned(4) on all structures missing an explicit alignment tag. On most archs this will do nothing, as 4 is the default structure alignment. However, on MIPS this will prevent the structure from being 8-byte aligned. * GNUmakefile: Distribute Support/minilib.jar, Support/cpvm.jar, and Support/reflect-thunk.jar (all GPLed sources). 2003-10-06 C. Scott Ananian * Backend/PreciseC/TreeToC.java: Fix alignment problem on IRIX builds. 2003-10-03 C. Scott Ananian * Backend/Runtime1/minilib.transact-root.properties: Fix transactions root set for minilib. * Analysis/Transactions/ArrayCopyImplementer.java: Classpath/minilib move System.arraycopy to VMSystem.arraycopy. Handle it there as well, and don't die if System (or VMSystem) is not a valid class in your path. * Analysis/PointerAnalysis/InterProcPA.java: Handle cut-down class libraries more gracefully. * Support/minilib.jar: Updated minilib with integer i/o. * Support/minilib.jar: Update "minilib" standard library. * IR/Bytecode/OpConstant.java: Don't require that the standard library have all wrapper classes: the minilib library doesn't. * Backend/Runtime1/minilib.init-safe.properties, Backend/Runtime1/minilib.method-root.properties: Add Console methods to init-safe list. Re-add NoSuchMethodError and NoSuchFieldError to minilib. * Backend/Runtime1/minilib.class-root.properties, Backend/Runtime1/minilib.init-safe.properties, Backend/Runtime1/minilib.method-root.properties: Update minilib property files to reflect the much-reduced size of the minilib library compared to classpath. * Backend/Runtime1/init-safe.properties: In classpath 0.06, the getClass() method belongs to Object, not VMObject. Also, currentTimeMillis() belongs to VMSystem, not System. * Backend/Runtime1/Runtime.java: "minilib" support when -Dharpoon.runtime1.minilib is true (bin/run-java will take care of this for you). "with_classpath_needed" goes in the configuration set, as minilib uses the same native libraries as classpath. * Backend/Runtime1/minilib.class-root.properties, Backend/Runtime1/minilib.init-safe.properties, Backend/Runtime1/minilib.method-root.properties, Backend/Runtime1/minilib.transact-root.properties, Backend/Runtime1/minilib.transact-safe.properties: Copy runtime properties for minilib from those from classpath 0.06. * bin/run-java, Support/minilib.jar: Add preliminary "minilib" support, for compiling applications with a drastically cut down standard library. 2003-09-25 C. Scott Ananian * bin/build-precisec: Add extra support for saving alex's pre-analysis results with the option --alex-save to build-precisec. * Backend/Runtime1/init-safe.properties: File.lengthInternal() is in classpath 0.06, and needs to be init-safe. 2003-09-16 C. Scott Ananian * GNUmakefile: Different versions of property files for classpath 0.04/0.05/0.06 and CVS head. 2003-09-11 C. Scott Ananian * GNUmakefile: Add more useful scripts to the .tgz distribution (and srcdoc). 2003-09-05 C. Scott Ananian * Main/Javap.java: Some work on '-c' option (bytecode disassembly). * Main/Javap.java: Fix how constructors and static initializers are printed. * IR/RawClass/AttributeCode.java: More javadoc typo fixes. * Main/Javap.java: Implement the '-l' option; work on '-c' and '-verbose'. * IR/RawClass/Attribute.java, IR/RawClass/AttributeCode.java, IR/RawClass/AttributeConstantValue.java, IR/RawClass/AttributeExceptions.java, IR/RawClass/AttributeInnerClasses.java, IR/RawClass/AttributeLineNumberTable.java, IR/RawClass/AttributeLocalVariableTable.java, IR/RawClass/AttributeSignature.java, IR/RawClass/AttributeSourceFile.java, IR/RawClass/AttributeSynthetic.java, IR/RawClass/Constant.java, IR/RawClass/ConstantDouble.java, IR/RawClass/ConstantLong.java: Slightly refactor the RawClass classfile parser. This package might need to be substantially redone after Java 1.5 is released, which will have classfile format changes. 1) Don't use magic constants: define attribute name fields in the appropriate attribute class, and use the fields instead. 2) Assert that the attribute names are appropriate. 3) Make constant.entrySize() public, so that constant_pools arrays can be interpreted from outside this package. 4) Fix a minor javadoc typo in the Constant class. 2003-08-28 C. Scott Ananian * Main/Javap.java: Add skeleton code showing desired format/location of output generated by -l, -c, and -verbose. * Main/Javap.java: Implement '-public', '-protected', '-package', and '-private' command-line options. * Main/Javap.java: Parse more javap options; implement '-s' and '-help' options, multiple class names on command-line. 2003-08-27 C. Scott Ananian * Main/Javap.java: Add some doc on the Varargs attribute from the GJ forum. 2003-07-28 C. Scott Ananian * Tools/Annotation/Java12.cup: Factor out scope pushenv/popenv into an action on a null production. This avoids creating a separate action case for every pushenv/popenv call. * Tools/Annotation/Lex/Keyword.java, Tools/Annotation/Lex/Lexer.java, Tools/Annotation/Lex/Separator.java, Tools/Annotation/Java12.cup: Update Annotation tool grammar to Java 1.5 (prototype 2.2). This is the 28-Jul-2003 release of the CUP Java Grammar. * IR/Quads/Pattern.java, IR/Quads/ReHandler.java: Java 1.5 has made 'enum' a reserved keyword -- it can't be used as a variable name. Rename these variables in existing code _enum_ instead. * Analysis/Transactions/SyncTransformer.java: Add an option to flatten all nested transactions into a single top-level transaction. * Analysis/Partition/Main.java, Analysis/PointerAnalysis/InterThreadPA.java: Java 1.5 has made 'enum' a reserved keyword -- it can't be used as a variable name. Rename these variables in existing code _enum_ instead. 2003-07-24 wbeebee * Analysis/Realtime/realtime-method.properties: Added new doneInit to the RTJ rootset. 2003-07-23 C. Scott Ananian * Main/Javap.java: Support varargs methods (JSR-201/prototype 2.2 feature). * Main/Javap.java: Update to understand and emit GJ prototype 2.2 variance syntax. * GNUmakefile, gj-files, Support/gjlib.jar: Update makefile/gj-files to support JDK 1.4.2, which is slightly more picky about interoperating with GJ code than was JDK 1.4.1. We should work with both now. Also commit a workaround which always builds all of the GJ files, because the v1.3 GJ compiler tends to go nuts about Map.Entry otherwise. 2003-07-22 C. Scott Ananian * Analysis/Transactions/SyncTransformer.java: Keep allocation information up-to-date during the transformation. * Analysis/Transactions/CloneImplementer.java: Add allocation information to the generated clone() implementations. 2003-07-22 wbeebee * Support/locale-root-set-classpath: More stuff to compile and run ATR. 2003-07-21 C. Scott Ananian * Support/gjlib.jar: Update gjlib.jar after transactions branch merge. * GNUmakefile: 'make cvs-update-classpath-0.05' will ensure you are using the properties files appropriate for classpath 0.05. CVS HEAD tracks classpath HEAD, which is probably not what you want for stable development. * Backend/Runtime1/transact-root.properties, Main/CodeGenerator.java, Main/Transactions.java, Runtime/Transactions/CommitRecord.java, Analysis/Transactions/BitFieldNumbering.java, Analysis/Transactions/CloneImplementer.java, Analysis/Transactions/HoistingCheckOracle.java, Analysis/Transactions/MethodGenerator.java, Analysis/Transactions/SyncTransformer.java, Analysis/Transactions/TreeDataFilter.java, Analysis/Transactions/TreePostPass.java, gj-files: Merge trans-11-jul-2003 branch with HEAD. The branch contained my reimplementation of the transactions transformation, which is now stable enough to replace the previous implementation. * Analysis/Transactions/SyncTransformer.java: Disable the currently-broken SmartCheckOracle and some questionable uses of the field oracle. * Analysis/Transactions/SyncTransformer.java, Backend/Runtime1/transact-root.properties, Main/Transactions.java: Allow specification of "transaction root methods" via a property file. These are method roots which may be invoked in the context of a transaction, necessitating the addition of "with transaction" versions of each of the given methods to the prior root set. * Backend/Runtime1/transact-root.properties: New file. * Analysis/Transactions/BitFieldNumbering.java: An extra assert for more-informative debugging. * Analysis/Transactions/CloneImplementer.java, gj-files: Bug fix: eagerly cache object fields to implement clone() method, so that later field additions aren't reflected in implementation of clone(). The problem here was that SyncTransformer was adding transaction-specific fields to the object, which CloneImplementer was then incorrectly trying to read and write (and then SyncTransformer was trying to transform those reads and writes, etc, etc). Eager generation of the clone method fixes the problem (as does eager caching of the information required for generation, which is the technique we actually use). 2003-07-16 C. Scott Ananian * Analysis/Transactions/SyncTransformer.java: New method prototype for setWriteFlags(). 2003-07-15 C. Scott Ananian * Analysis/Transactions/TreeDataFilter.java: New file. * Analysis/Transactions/SyncTransformer.java, Analysis/Transactions/TreeDataFilter.java, Main/CodeGenerator.java, Main/Transactions.java, Runtime/Transactions/ImplHelper.java, gj-files: New redirection method which adds transaction information to the JNI environment, instead of calling specially-named versions of JNI methods. Also add information about bit field numbering to the runtime reflection information, so that the JNI support code can do the Right Thing at field read/writes with the environment's transaction. TreeDataFilter is a pretty big hack. But not *too* evil. * Runtime/Transactions/CommitRecord.java: Never give up on the top-level transaction. * Backend/Runtime1/init-safe.properties: Note the proper fix to the java.lang.Thread.start/initDone hack. * Main/Sizer.java: Update Sizer to work with realistic root set. * Analysis/Transactions/SyncTransformer.java: Bug fix: TypeMap doesn't give exact information for the component type of an array, since all sub-integer types are squashed into HClass.Int. So use the AGET's own idea of the type when TypeMap reports a primitive component type. * Analysis/Transactions/SyncTransformer.java: Oops: one-line bug fix. This was a cut-and-paste error. * Analysis/Transactions/MethodGenerator.java, Analysis/Transactions/SyncTransformer.java, Analysis/Transactions/TreePostPass.java: Make Transactions.MethodGenerator.generatedMethodSet from a method into a field. Add stubs for the generated methods in SyncTransformer (perhaps move this into MethodGenerator?) so that (even though they are unreferenced and unused) they don't cause link errors in the output. * Analysis/Transactions/SyncTransformer.java: Doc updates. * Analysis/Transactions/TreePostPass.java: Bugfix to TreePostPass: use the correct native-C function names. * Analysis/Transactions/SyncTransformer.java, Analysis/Transactions/TreePostPass.java: Factor out read and write field checks into native code. Refactor TreePostPass to remove duplicate code. 2003-07-14 C. Scott Ananian * Backend/Runtime1/TreeBuilder.java, Backend/Runtime2/TreeBuilder.java: Refactor harpoon.Backend.Runtime2.TreeBuilder._call_FNI_Monitor so that we don't duplicate code from Runtime1. Also add a mechanism to Runtime2 to allow skipping the runtime check-before-monitor, because the DynamicSyncRemoval stage already does this. (You still need the runtime2 check if you're not compiling with DynamicSyncRemoval, of course.) * Analysis/Transactions/SyncTransformer.java, Analysis/Transactions/TreePostPass.java: Bulk update of FLEX transactions code to support modified Runtime function signatures. Also, more flexible Tree-rewriting system to transform the java calls into (inline-able) native calls. * Analysis/Transactions/BitFieldNumbering.java: GJ-ize BitFieldNumbering; also add a publically-readable set of all the new 'bitfield' fields that have been added, so that we can recognize them in the TreePostPass. 2003-07-11 C. Scott Ananian * Analysis/Transactions/HoistingCheckOracle.java, Analysis/Transactions/MethodGenerator.java, Analysis/Transactions/SyncTransformer.java, Analysis/Transactions/TreePostPass.java: Enable TreePostPass optimization of C native methods implementing transactional/non-transactional reads: replace field references by proper offsets, etc. Extends MethodGenerator to keep a reverse map around; extends SyncTransformer to keep some additional information about methods and fields around and to pass it to TreePostPass. A comment about behavior with sigma functions added to HoistingCheckOracle. * gj-files: Compile TreePostPass with GJ compiler, like all the other files in Analysis/Transactions. * Analysis/DynamicSyncRemoval/TreeCallOpt.java, Main/DynamicSyncRemoval.java: In accordance with the last commit, rename the special DynamicSyncRemoval helper method from DYNSYNC_isNoSync to EXACT_isNoSync. This means an explicit entry in TreeToC is no longer required. Also, move the configuration checking code back where it used to be, since we *do* require the Runtime to be appropriately considered, even if all the calls to our "special" method end up inlined away in tree form. (This is because the compiler will still emit reflection references and JNI stubs for the no-longer-used method, since the inlining happens too late in the compilation for anyone to notice that it has suddenly gone unused. Hence we need to have the Runtime include symbols which match the generated references and stubs.) * Backend/PreciseC/TreeToC.java: Instead of letting entries to 'exactproto' proliferate, simply allow any method name which starts with 'EXACT_' (which no JNI or FLEX-generated method will do) to be an 'exactproto' method. This means that calls will be emitted in a form which allows C-compiler inlining and FLEX won't try to guess a reasonable prototype for the function (you are responsible for declaring it yourself, in some way via precisec.h). * Analysis/Transactions/SyncTransformer.java: Hoist read operations out into native code, using the MethodGenerator. * IR/Quads/SSIToSSA.java: Create reverse mappings in SSIToSSA so that it can be used to generate an HCodeAndMaps showing the correspondence between SSI and SSA form. * ClassFile/HCodeAndMaps.java: Make HCodeAndMaps non-final so that users can extend it to add additional correspondence information if they like. * Analysis/Transactions/MethodGenerator.java: A helper class for the transactions transformation which creates new native helper methods. * Analysis/Quads/TypeInfo.java, Analysis/UseDef.java, Support/gjlib.jar, gj-files: GJ-ized TypeInfo and UseDef; also removed some unused methods from UseDef. 2003-07-10 C. Scott Ananian * IR/Quads/UnHandler.java: Work around broken java compilers (I think it's jikes at fault here) which don't guarantee that every MONITORENTER is matched by a MONITOREXIT. Technically, the MONITOREXIT could fail with an exception (in FLEX, a null pointer exception, but in other places also any one of a number of runtime exceptions) at which point the MONITOREXIT should *continue to be retried* until it succeeds. Jikes allows execution to leave the method without releasing the held lock. We work around this by assuming, for Flex's sake, that MONITOREXIT will never fail -- not even by a NullPointerException. This is not true for arbitrary bytecode but *ought* to be true for bytecode generated by legal Java programs; any NullPointerException should be thrown before the MONITORENTER on the lock, and the compiler should guarantee that the MONITORENTER and MONITOREXIT are using the same value. This means that in *our* IR, at least, MONITORENTER and MONITOREXIT are always properly matched, even if they aren't in the buggy input bytecode. Sigh. You can use -Dharpoon.all.monitorexits.are.safe=true if, for some reason, you want to disable this workaround and are confident that your input bytecode is valid. * Backend/Runtime1/transact-safe.properties: The DynamicSyncImpl.isNoSync() check function is transactions-safe. * Support/gjlib.jar: Updating gjlib.jar. * Analysis/DynamicSyncRemoval/SyncRemover.java: Properly propagate AllocationInformation when we clone parts of a method. * Main/DynamicSyncRemoval.java, Analysis/DynamicSyncRemoval/TreeCallOpt.java: Don't require special runtime configuration unless we actually require the special native functions. 2003-07-09 C. Scott Ananian * Backend/Runtime2/TreeBuilder.java, Analysis/DynamicSyncRemoval/TreeCallOpt.java: Factor out 'fetchHash' from Runtime2.TreeBuilder, which allows us to use it in DynamicSyncRemoval.TreeCallOpt to make a more efficient synchronization test (no method call required). * Analysis/DynamicSyncRemoval/SyncRemover.java, Analysis/DynamicSyncRemoval/TreeCallOpt.java, Backend/PreciseC/TreeToC.java, Runtime/DynamicSyncImpl.java: Reverse the sense of the dynamic synchronization removal check. A tiny bit more efficient this way; also consistent with the AllocationProperties name and the runtime2 implementation. * Analysis/DynamicSyncRemoval/SyncRemover.java, Analysis/DynamicSyncRemoval/TreeCallOpt.java, Backend/PreciseC/TreeToC.java, Runtime/DynamicSyncImpl.java: Complete the dynamic synchronization removal code: a) Move the function prototype used to harpoon.Runtime.DynamicSyncImpl It shouldn't be in the transactions package. b) Fix the PHI placement in the SyncRemoval transformation. c) Add DYNSYNC_isSync to TreeToC's list of exactproto functions, so that it can be inlined. * IR/Quads/Translate.java: A real bug fix: protect the MONITOREXIT with a handler, in case some exception is thrown while executing it. This ensures that every exit from the method will *always* go through the MONITOREXIT, even if there's a null-pointer exception or some such while evaluating the MONITOREXIT. (In this case, you're likely to infinite loop by retrying the MONITOREXIT, but this is better than leaving the method with locks still held.) * IR/Quads/Print.java: Minor bug fix to IR/Quads/Print.java: I don't think this bug could ever actually be seen, because the HEADER quad would *always* be followed by its default successor. But still... * bin/replace-for.perl: Commit a script that's been lying around my tree to autoconvert code to use the new foreach syntax. Unfortunately, Sun hasn't yet released a compiler that can properly compile this syntax, so we're not auto-converting anything yet. Maybe next month. (I wrote this back at FCRC in June.) * Main/Graph.java, Main/JMain.java, Main/Main.java, Main/Options.java, Main/Run.java: Add the dynamic synchronization removal pass to Main/Options, so that it can be invoked by harpoon.Main.Main. This required passing a linker around, so a number of the utility classes in harpoon.Main had to be touched. * Analysis/DynamicSyncRemoval/SyncRemover.java, Analysis/DynamicSyncRemoval/TreeCallOpt.java, Analysis/DynamicSyncRemoval/package.html, Main/DynamicSyncRemoval.java, Main/SAMain.java, gj-files: New dynamic synchronization removal pass. This duplicates code between MONITORENTER and MONITOREXIT and adds a check at the top to determine whether it is going to take the synchronized path or the unsynchronized pass. This transformation helps the Transactions code take advantage of sync removal better than the only-style implementation (which buries the check in the implementation of fni_monitorEnter) does. * Analysis/SizeOpt/MostlyZeroFinder.java: Fix comments which had gotten out-of-sync with the implementation. * Util/Options/Option.java, Main/CompStagePipeline.java, Main/CompilerStage.java, Main/CompilerStageEZ.java, Main/CompilerState.java, Main/SAMain.java, Support/gjlib.jar, Support/gjlib2.jar, gj-files: GJization. 2003-07-08 C. Scott Ananian * Main/SAMain.java: Fixed a bug in Alex's factory-ification of allocation strategies: sometimes we need to use a slightly different version of a strategy depending on which backend is chosen. In this case, the C calling semantics don't allow an *external* stack allocation function (because the memory would be allocated on the stack of the allocation function itself and then destroyed when the allocation function returned) so we have to inline a call to alloca when using the precise-c backend. Our native code backends don't have this problem, because we do magic, so we stack allocate with the (external) NSTK_alloc() function. * Support/precisec-no-sect-makefile.template: Work around AIX problems with large numbers of files on the command-line by building and linking object files in chunks of 100 files. This, regrettably, makes the Makefile more complicated. But AIX will do that to ya. * GNUmakefile: Move from .lcs. to .csail. domains. 2003-07-07 C. Scott Ananian * bin/build-precisec: Because I'm lazy: make --alex Do The Right Thing for compiling with Alex's analysis and stack allocation. Not as tweakable as Alex's own build scripts, but what could be simpler than bin/build-precisec --alex Hello HIC ? And it even works! 2003-07-04 C. Scott Ananian * Support/precisec-no-sect-makefile.template: Shorten the filenames of the SECTION_*.o objects (to just *.o) to work around losing OSes which impose limits on the maximum command-line length. Compiling _200_check in the SPECjvm98 benchmarks otherwise overflows the 24k byte command-line limit on AIX. * bin/build-spec, bin/run-java: It's been long enough: classpath is now the default FLEX class library. Alex (and others?), use export USE_SUN_JDK=1 in your environment if you want to keep using the Sun libraries. * IR/Tree/ToTree.java: Last AIX fixes: inline tables (switch jump tables, array initialization tables) need padding afterwards on AIX, because the compiler is not smart enough to correctly align the code afterwards. In particular, function pointers seem to be implemented via an indirection in AIX, and the function pointer indirection is misaligned after an inline table. With these changes, "Hello, world" (finally!) works on PowerPC AIX. 2003-07-03 C. Scott Ananian * Support/precisec-makefile.template, Support/precisec-no-sect-makefile.template: Improve the precisec makefile templates: 1) automatically determine whether -fno-zero-initialized-in-bss is required, and include it in CFLAGS if it is. 2) both styles of precisec build now link all the object files together into one Java.o file, and then wrap this in Java.a for backwards and mutual compatibility. The .o file is tagged INTERMEDIATE, which ought to encourage 'make' to clean it up. * Backend/PreciseC/TreeToC.java: More tweaks to allow the NO_SECTION_SUPPORT build: coalesce back-to-back labels (since gcc frowns on zero-length structures; we also assert that we're not generating these anymore), fix CODETABLEs (should always be static), and add a note about -fno-zero-initialized-in-bss. * Backend/Runtime1/DataReflection1.java, Backend/Runtime1/DataReflection2.java, Backend/Runtime1/DataReflectionMemberList.java: Always place a DATUM following a label, to prevent empty structures from showing up in the PreciseC backend. Not only will empty structures be moved to .bss (although -fno-zero-initialized-in-bss will prevent that), gcc has odd ideas about their alignment and size. * Main/SAMain.java, bin/build-precisec: It's been long enough: let's admit that harpoon.alloc.strategy=bdw really is and ought to be the default. Keep the default value in place for flexc_options in bin/build-precisec, just to show people where java property options ought to go. * Backend/PreciseC/TreeToC.java, GNUmakefile, Main/CodeGenerator.java, Support/precisec-no-sect-makefile.template: Support architectures/operating systems which don't allow multiple sections in object files. AIX is one of these losers; old "a.out" ports of Linux used to be another. 2003-06-24 C. Scott Ananian * Support/gjlib2.jar: New gjlib2.jar with Alex's recently-committed serialization changes. 2003-06-24 salcianu * Util/Collections/PersistentMap.java: make PersistentMap serializable 2003-06-20 C. Scott Ananian * Backend/Runtime1/transact-safe.properties: Methods which are transaction-safe for classpath 0.05. * Analysis/Transactions/CloneImplementer.java: Tweak the CloneImplementer so that it works with GNU classpath as well as the Sun JDK. (Classpath has an additional VMObject.clone() method we need to deal with.) * Analysis/Quads/NewMover.java: Fix a bug in NewMover which could cause it to move NEWs too far, trampling on redefinitions of the variables involved in the NEW. Seen in the .class$ methods generated by the jikes compiler for class literal references (Foo.class). 2003-06-19 C. Scott Ananian * IR/Tree/ToTree.java: New versions of gcc decide to super-optimize our PreciseC output, moving all-zero structures to the .bss segment from the .data segment. We depend on the sequential ordering of some of these structures (the ones implementing multi-part tables of various kinds, especially array initialization tables) and gcc causes us to break. In particular, the SPEC 222_mpegaudio benchmark breaks in spec.benchmarks._222_mpegaudio.nb.(). Now we trim zero elements from the start and end of array initializers (since the array is given to us zero'ed out anyway), ensuring that gcc doesn't move those bits around on us. * Backend/Runtime1/init-safe.properties, Backend/Runtime1/method-root.properties: Small tweaks to properties files for classpath 0.05. Committing on the classpath_0_05 branch; the main branch continues to follow classpath CVS. * Backend/Runtime1/transact-safe.properties: transact-safe properties for classpath. This version is empty; we'll create appropriate transact-safe properties for classpath 0.05 on the classpath_0_05 branch, and then merge then into head when/if the properties are updated for classpath CVS. * Support/gjlib.jar: Update gjlib.jar, since I added files to gj-files. * IR/Assem/InstrJUMP.java, gj-files: Add some additional files to gj-files to work around a bug in the Java 1.4.2-beta compiler --- for once, not a GJ compiler bug! I don't recommend using 1.4.2-beta at this time; keep using 1.4.1_03 instead. 2003-06-17 C. Scott Ananian * Support/gjlib.jar, Support/gjlib2.jar, gj-files: Updated the bootstrapping lists and jars. * Analysis/Context.java, Analysis/GenericContextFactory.java, Analysis/PointsToAnalysis.java: Finally check in the GJ-ized Context-related classes. * Analysis/Transactions/SyncTransformer.java: GJ-ize SyncTransformer. 2003-06-16 C. Scott Ananian * Util/Collections/BinaryHeap.java: Remove unnecessary 'import' statements, which confuse the 1.3 prototype GJ compiler. 2003-06-14 C. Scott Ananian * Util/Collections/TestSet.java: Added test for PersistentSet to TestSet class. * Util/Collections/PersistentSetFactory.java: Add a fast (ln N * ln M) implementation of containsAll for PersistentSets. * Util/Collections/PersistentTreeNode.java: Bug fix in persistent tree iterator: hasNext was returning an inverted result. 2003-06-10 C. Scott Ananian * Support/gjlib2.jar, Util/Collections/PersistentSetFactory.java, gj-files-2: Added 'PersistentSetFactory' analog to 'PersistentMapFactory'. Both are based on the persistent randomized treaps implemented in the PersistentTreeNode class. * Support/gjlib.jar, Support/gjlib2.jar: Update gjlibs. [forgot to 'cvs update' before my last check-in, so perhaps the earlier commit missed some of Alex's recent changes.] * Analysis/Instr/RegAlloc.java: Add a missing typecast. * GNUmakefile, Support/gjlib2.jar, bin/find-gj, bin/jsr14-2.0, gj-files, gj-files-2: Extend FLEX make process to support the v2 JSR-14 prototype compiler, which has fewer and different bugs than the v1.x prototype. We now require three compilers to build FLEX from scratch, which is decidedly non-ideal -- but the goal is to move back to two compilers by getting rid of either the v1.x or the non-JSR-14 compiler. * Util/Collections/PersistentMap.java, Util/Collections/PersistentMapFactory.java, Util/Collections/PersistentSet.java, Util/Collections/PersistentTreeNode.java: Bug fixes for PersistentTreeNode: allow null keys (assuming the comparator's okay with this). PersistentTreeNode: add 'putAll' method for quick merging of treaps. Reworked PersistentMap/PersistentSet to work with updated PersistentTreeNode interface. Added 'PersistentMapFactory' class which uses PersistentTrees to implement a map which maximally reuses space using hash-consing, and also allows constant-time set equality testing. * IR/Assem/InstrCALL.java, IR/Assem/InstrMEM.java: Fix impedance mismatch between non-GJ-ized InstrCALL and InstrMEM and their GJ-ized superclass. 2003-06-08 C. Scott Ananian * Util/Collections/PersistentTreeNode.java: Final stage of the PersistentTreeNode restructuring: parameterize the allocation function --- which also requires adding an extra recursive parameter to the PersistentTreeNode class. Provide a sample implementation, 'WithValue', with illustrates how to extend the base class with a 'value' field, as well as to cache map hash codes. * Util/Collections/PersistentTreeNode.java: Stage 3 of check-in: make the 'value' field in the base class optional; virtualize all existing uses of it. * Util/Collections/PersistentTreeNode.java: Stage 2 of the commit: define an appropriate iterator method over treaps of PersistentTreeNode. Because the trees are persistent, we don't have to worry about concurrent updates. * Util/Collections/PersistentTreeNode.java: Stage 1 of the PersistentTreeNode update: a) javadoc for the full functionality (not all implemented in stage 1 check-in) b) add heapKey double-hashing code, and tweak code so that all trees are treaps. This keeps them balanced. c) Some primitive debug and self-test methods. 2003-06-05 salcianu * Analysis/PointerAnalysis/ArtificialTempFactory.java: deleted unused class * Support/gjlib.jar: newer gjlib.jar * Analysis/PointerAnalysis/AllocSyncOptCompStage.java, Analysis/PointerAnalysis/InterProcPA.java, Analysis/PointerAnalysis/MAInfo.java, Analysis/PointerAnalysis/ParIntGraph.java, Analysis/PointerAnalysis/PointerAnalysis.java, Analysis/MetaMethods/FakeMetaCallGraph.java: small changes 2003-06-04 salcianu * Support/gjlib.jar: new gjlib.jar * Instrumentation/AllocationStatistics/AllocationInstrCompStage.java, Instrumentation/AllocationStatistics/AllocationNumbering.java: small changes * Analysis/Realtime/CheesyPACheckRemoval.java, Analysis/Realtime/PACheckRemoval.java: Small changes to comply with the changes in the PointerAnalysis constructor. * Analysis/PointerAnalysis/AbstrPAEdgeSet.java, Analysis/PointerAnalysis/AllocSyncOptCompStage.java, Analysis/PointerAnalysis/ComputeInterProcMuClosure.java, Analysis/PointerAnalysis/Debug.java, Analysis/PointerAnalysis/InterProcPA.java, Analysis/PointerAnalysis/LightPAEdgeSet.java, Analysis/PointerAnalysis/MAInfo.java, Analysis/PointerAnalysis/NodeRepository.java, Analysis/PointerAnalysis/ODPointerAnalysis.java, Analysis/PointerAnalysis/PAEdgeSet.java, Analysis/PointerAnalysis/PAEscapeFunc.java, Analysis/PointerAnalysis/PANode.java, Analysis/PointerAnalysis/ParIntGraph.java, Analysis/PointerAnalysis/ParIntGraphPair.java, Analysis/PointerAnalysis/PointerAnalysis.java, Analysis/PointerAnalysis/PointerAnalysisCompStage.java, Analysis/PointerAnalysis/PointsToGraph.java: Many, many changes from the past weeks of debugging. In addition to debugging, I also did some optimizations. Most importantly, when computing the summary of a method, all nodes that escape globally (i.e., are reachable from a static field and/or a native method) are compressed into the special LOST node. Other important change: edges that are inconsistent with the type declarations are not allowed. This improved the precision A LOT! (e.g., it allowed us to remove 96% syncs for JLex!) The code is still ridden with debug stuff. It will get better after I manage to process javac (the only SpecJVM that still eludes me ...) * Analysis/MetaMethods/FakeMetaCallGraph.java: unimportant changes * Analysis/MetaMethods/MetaCallGraph.java, Analysis/MetaMethods/MetaCallGraphAbstr.java: Made sure MetaCallGraphs are DiGraphs too. This way, getting all the callable methods comes from free (DiGraph has methods for reachability). * Analysis/Quads/AbstrCallGraph.java: Added some default (but still safe) implementation for getRunMethods(). * Analysis/CallGraph.java: Made sure that CallGraph appropriately subclasses harpoon.Util.Graphs.DiGraph * Backend/Runtime2/TreeBuilder.java: added curly braces for clarity * IR/Tree/SEQ.java: changed comment 2003-05-31 wbeebee * Main/Options.java: Added none to pass through bytecode through harpoon.Main.Main because javac produced bad bytecode and I want a working Javap. 2003-05-30 C. Scott Ananian * Main/Javap.java: Fix bug parsing array signatures with variance. Confirmed with Neal Gafter that this is the proper parsing, even though the prototype JSR-14 compiler is buggy in this regard. * Main/Javap.java: Correct for bug in JSR-14 spec for signatures of nested parameterized types. * Main/Javap.java: Extends JavaP to handle new variance specifications in JSR-14. 2003-05-29 C. Scott Ananian * Util/Collections/PersistentTreeNode.java: Noticed bug in PersistentTreeNode.isSame(). This method was unused, though, so the bug wasn't hurting anyone. 2003-05-22 wbeebee * Backend/Runtime1/init-safe.properties: Fix to eliminate dependency on ipaq servo controller when compiling normal Classpath programs with FLEX... 2003-05-21 wbeebee * Backend/Runtime1/init-safe.properties: Updated to match classpath, added ipaq.IPaqServoController.setup() to compile embedded servo controller. 2003-05-15 C. Scott Ananian * Analysis/Companions/SingularFinder.java: Trim the amount of information stored per-method. * Util/Collections/PersistentTreeNode.java: Efficiency hack: == implies isSame(). * Analysis/Companions/SingularFinder.java: Complete implementation of SingularFinder. Some restructuring/efficiency work still to be done. * Analysis/Companions/QuadFlowGraph.java: Add useC() and defC() methods to the QNodes in QuadFlowGraph in order to separate the uses/defs associated with the phis/sigmas with the other uses and defs in the node. * Util/Collections/BinomialHeap.java, Util/Collections/PersistentTreeNode.java: Revert workaround for old (pre-1.3 prototype) GJ compiler brokenness. Thankfully, the GJ compiler hasn't been broken this way anymore for a while. 2003-05-12 salcianu * Analysis/MemOpt/ComputeAnAe.java: allowing Flex to compile again. 2003-05-12 C. Scott Ananian * Analysis/Companions/SingularOracle.java: Pairwise singularity is no longer important, as it's not the building block for mutual singularity any more. In the new formulation, mutual singularity is the building block, and even single-point singularity is expressed in terms of the mutual singularity of a singleton set. * Analysis/Companions/QuadFlowGraph.java, gj-files: Add QuadFlowGraph class, which is a variant of the usual flow graph exported by the IR.Quads Code, Quad, and Edge classes in that additional nodes are added before PHIs and after SIGMAs in order to make the expression of dataflow equations more straightforward. * Analysis/Companions/DataFlowSolver.java: Generalize DataFlowSolver to work over arbitrary Graphs, not just Graphs made up of HCodeElements and HCodeEdges. 2003-05-10 salcianu * bin/run-java: Small change to allow us to pass an explicit stack size for the JVM: just define and export FLEXSTACK. Similar to FLEXMEM (this one is for heap space). * Util/LightBasicBlocks/LightBasicBlock.java: All functionality from Reachability.java was moved into DiGraph.java. 2003-05-09 C. Scott Ananian * Analysis/Companions/SingularFinder.java: Quick fix to make FLEX compile: didn't catch this because my local copy of SingularFinder is much modified. * Support/gjlib.jar: Update gjlib.jar after gj-izing and tweaking class hierarchy. * IR/Bytecode/Code.java, gj-files: GJ-ize Bytecode.Code, which allows it to be a Graph. * IR/Assem/Code.java, IR/Quads/Code.java: Assem.Code and Quad.Code are Graphs. * Util/Collections/Graph.java: Distinguish "operations on Graphs" from "things that are Graphs". Things that are graphs need not implement every graph-theoretic algorithm which could be applied to graphs. * Util/Collections/package.html: Update harpoon.Util.Collections package documentation. * IR/Assem/Instr.java, IR/Bytecode/Instr.java, IR/Properties/CFGEdge.java, IR/Properties/CFGraphable.java, IR/Quads/Quad.java: CFGraphable now extends Graph.Node, and CFGEdge extends Graph.Edge. * gj-files: Update to gj-file to go with the previous commit's package renaming; a separate commit so that it doesn't get the RENAME tag of the previous commit. * Util/Collections/AbstractGraph.java, Util/Collections/Graph.java, Util/Collections/MutableGraph.java, Analysis/Companions/AbstractGraph.java, Analysis/Companions/Graph.java, Analysis/Companions/MutableGraph.java: Moved graph abstraction to harpoon.Util.Collections package, which is more appropriate. [This is a different (node-based, not navigator-oriented) abstraction than Alex's in harpoon.Util.Graphs. Use which you like.] @RENAME: Analysis/Companions Util/Collections@ * Analysis/Companions/MutableGraph.java: Javadoc update. * gj-files, Analysis/Companions/AbstractGraph.java, Analysis/Companions/Graph.java, Analysis/Companions/MutableGraph.java: Split Graph into MutableGraph and Graph, and get rid of the 'value' field in Nodes -- if it is necessary, the user's subclass of node will include it. Rename Graph.Node.pred/succ to precC and succC for compatibility with CFGraphable. Now CFGraphable can extend Node.Graph and CFGEdge can extend Node.Edge to allow CFGs to be treated as Graphs w/o restricting Graphs to control-flow graphs. Appropriate changes to AbstractGraph, which now extends MutableGraph. * IR/Properties/CFGEdge.java, IR/Quads/Edge.java, Support/gjlib.jar, Analysis/MemOpt/IncompatibilityAnalysis.java, Analysis/MemOpt/SSILiveness.java, Analysis/PointerAnalysis/MAInfo.java, Analysis/PointerAnalysis/ODMAInfo.java, IR/Assem/InstrEdge.java, IR/Bytecode/Instr.java, Analysis/DataFlow/SpaceHeavyLiveTemps.java: Remove redundant toCFG() and fromCFG() methods, since to() and from() are allowed to have the properly-narrowed covariant return type. Change users to use just plain to() and from(). [to() used to return a HCodeElement, while toCFG() returned a CFGraphable. Now they both return the appropriate subclass of HCodeElement&CFGraphable; i.e. IR.Quads.Edge.to() returns a Quad.] 2003-05-08 C. Scott Ananian * Analysis/Companions/DataFlowSolver.java: Silly scott -- compile before you commit. Added a forgotten import statement. * Analysis/Companions/DataFlowSolver.java, gj-files: A *simple* parameterized dataflow solver. * IR/Bytecode/Instr.java, Support/gjlib.jar, gj-files: GJ-ize harpoon.IR.Bytecode.Instr so that it can implement the a properly-parameterized CFGraphable interface. Add it to gj-files, along with some subclasses, and rebuild gjlib.jar. * IR/Assem/Instr.java, IR/Assem/InstrEdge.java, IR/Quads/Edge.java, IR/Quads/Quad.java, IR/Properties/CFGEdge.java, IR/Properties/CFGraphable.java: Change the parameterization of CFGraphable/CFGEdge to use mutually recursive type variable bounds, to make the relation between CFGEdge and CFGraphable clear. (That is, if an implementation G of CFGraphable returns edge class E, then the to()/from() methods of E will return specific instances of of G, not generic instances of CFGraphable.) Tweak Quad, Edge, Instr, and InstrEdge classes to provide the new correct parameterization. 2003-05-08 wbeebee * Backend/Runtime1/method-root.properties: To compile ATR under GNU Classpath 2003-05-07 C. Scott Ananian * Analysis/Companions/AbstractGraph.java, Analysis/Companions/Graph.java: Added javadoc. * Analysis/Companions/AbstractGraph.java: Add javadoc. * Util/Collections/AggregateMapFactory.java: Add a null-check to entrySet.add() to allow AggregateMaps to pass the tests in TestMap. Also tweak some of the access modifiers. * Support/gjlib.jar, gj-files: Update gj-files with newly added sources and rebuild gjlib.jar. * Util/Collections/TestMap.java: Fix TestMap class to avoid ClassCastException thrown by JSR-14-compiled implementations of Map.entrySet(). Not sure if this is a bug in the tester or in the JSR-14 implementation. * Util/Collections/LinearSet.java: Added constructor taking a collection which is required to allow LinearSet to be tested by the TestSet class. * Util/Collections/LinearMap.java: More implementation of constructor taking a Map. Fix implementation of entrySet() to pass tests in TestMap and disallow the inadvertent creation of MultiMaps (multiple value entries for one key). * Util/Collections/BitSetFactory.java: Fix BitStringSet implementation of hashCode() and equals() to conform with specification for Set implementations. This allows this class to pass the Set tests in the TestSet class. * Analysis/Companions/SingularFinder.java: Implementation of the SingularFinder interface. Destined to be quickly rewritten. * Analysis/Companions/SingularOracle.java: Interface description for the singular value analysis. * Analysis/Companions/StaticValue.java: A static value is a pair of a variable and a use point. * GNUmakefile: The 'gjdoc' tool has changed names: it is now 'sinjdoc' (for "sinjdoc is not javadoc", of course --- it's better!). * Analysis/Companions/package.html: Described the (current and future) contents of this package. 2003-05-06 salcianu * gj-files: Moved some files in gj-files in the section # not GJ-ized, but we need to co-compile these to satisfy dependencies. 2003-05-06 C. Scott Ananian * Util/Collections/AggregateSetFactory.java: Improve efficiency still further by removing the Map.Entry objects from the representation of AggregateSet. We also create a new 'Header' superclass which removes unused fields from the Header object; this is a bit of over-optimization, likely, but it does serve to elucidate the code. Fixed a bug in the EntryList.add() method where we weren't checking that the next field was non-null. * Util/Collections/WorkSet.java: Add a comment about the preconditions necessary to make this method work (prevents erroneous reuse of the code where these conditions don't hold). * gj-files: Re-alphabetized gj-files. * Support/gjlib.jar: Forgot to add a new gjlib.jar with the files I recently added to gj-files. This .jar should contain Alex's updates as well. 2003-05-06 salcianu * Support/gjlib.jar: new gjlib.jar to help you compile the latest version of Flex 2003-05-06 C. Scott Ananian * Analysis/Companions/AbstractGraph.java, Analysis/Companions/Graph.java, gj-files: Add (yet another) graph abstraction to FLEX. This one is specifically designed for efficiency, flexibility, extensibility, and type-safety. 2003-05-06 salcianu * gj-files: update gj-files such that the new code compiles * Analysis/AllCallers.java: small change * Analysis/PointerAnalysis/InterThreadPA.java, Analysis/PointerAnalysis/MAInfo.java: debug code * Analysis/PointerAnalysis/ODMAInfo.java, Analysis/PointerAnalysis/ODPointerAnalysis.java: making sure Frederic's analysis still compiles after the last changes. * Analysis/PointerAnalysis/NodeRepository.java: Performance tricks: 1. All allocation sites for exceptions (and there are many of them), can be coalesced into a single inside node. Controlled by COALESCE_EXCEPTIONS. Use if you don't need too much precision for exception nodes (the usual case). Tremendous reduction in the number of nodes! 2. All objects returned from native methods can be coalesced into a single RETURN node. Similarly, all objects thrown from native methods can be coalesced into a single EXCP node. Controlled by COALESCE_RESULTS_FROM_NATIVES. I don't see any reason why this flag should be turned off. Significant reduction in the number of nodes! After these optimizations, the analysis runs on JLEX in 136 seconds! 2003-05-06 C. Scott Ananian * Util/Collections/AggregateSetFactory.java: Reworked the AggregateSetFactory to implement remove() efficiently (in O(1) time) and to fix a bug where the set implementation would inadvertently keep live the set providing their initial contents. 2003-05-06 salcianu * Analysis/PointerAnalysis/ParIntGraph.java: more detailed graph node statistics * Analysis/PointerAnalysis/PointsToGraph.java: fixed grammar mistake * Analysis/PointerAnalysis/PANode.java: New node: CONST - models all constant objects. Of course, we can extend this to have one node for each constant object; unnecessary for the moment and too costly (for small benchmarks, we want to number of nodes to be as small as possible) * Analysis/PointerAnalysis/LightPAEdgeSet.java: Fixed evil "mutation behind the scene" bug, due to a forgotten ".clone()". * Analysis/PointerAnalysis/PointerAnalysis.java: 1. Proper treatment of CONST. "v = CONST obj" deletes previous edges from v (we didn't do this before, which resulted in some unnececessary imprecisions); also, if obj is an object, puts v to point the only node that models all constant objects. This node is unessential for stack/thread allocation (we obviously don't need to stack allocate these immortal objects; that's why we didn't care too much about it before), but it's good for completeness anyway. 2. Remove a previous precision enhancing hack rendered useless by 1. * Util/BasicBlocks/SCCBBFactory.java, Analysis/MemOpt/Util.java, Util/LightBasicBlocks/SCCLBBFactory.java: Small changes to reflect the fact that harpoon.Util.Graphs.SCComponent.Navigator is now harpoon.Util.Graphs.Navigator. * Analysis/MetaMethods/MetaCallGraph.java, Analysis/MetaMethods/MetaCallGraphImpl.java, Analysis/MetaMethods/SmartCallGraph.java, Analysis/CallGraph.java, Analysis/Quads/AbstrCallGraph.java, Analysis/Quads/CachingCallGraph.java, Analysis/Quads/CallGraph.java, Analysis/Quads/CallGraphImpl2.java: CallGraphs and MetaCallGraphs now extend the just introduced DiGraph. This way, if you ever work on an analysis that explores the call graph top-down, you can call the method getTopDownComponentView() of the call graph and obtain a top-down sorted list of the call graph strongly connected components. Currently, the list uses next/prev fields in the SCCs; it will be cleaner to have a real java.util.List, but there is too much code to change right now ... If you work on a bottom-up analysis, you simply iterate over that list in reverse order. Some analyses (e.g. PointerAnalysis) were already doing the things described above. As the things get more elegant, they will become accessible to other analyses too. 2003-05-04 salcianu * bin/copyright.perl: putting a more stable email address 2003-05-03 C. Scott Ananian * Util/Default.java: Add left()/right() methods to Default.PairList. * prj.el: Update prj.el to latest version of JDE. * Temp/package.html: Correct javadoc spelling error. 2003-05-01 salcianu * Analysis/MemOpt/IADriver.java: Useless file: entire functionality for IncomaptibilityAnalysis is now available via SAMain. * Analysis/PointerAnalysis/MAInfo.java, Main/SAMain.java: USE_OLD_CLINIT_STRATEGY is gone! rip * Analysis/Quads/SmallMethodInliner.java: fixed comment to reflect reality 2003-04-30 salcianu * Analysis/MemOpt/Util.java, Support/gjlib.jar, Analysis/AllCallers.java: Cleaner AllCallers * Analysis/PointerAnalysis/MAInfo.java: Modified MAInfo to use the top-down view of a meta-callgraph from MetaCallGraph (instead of building a new one from scratch) + other cosmetic changes. * Analysis/MetaMethods/MetaCallGraph.java, Analysis/MetaMethods/MetaCallGraphAbstr.java: Added methods for getting Top-Down / Bottom-Up views of a meta-callgraph. * Main/CompStagePipeline.java, Main/SAMain.java, Analysis/PointerAnalysis/MAInfo.java, Analysis/PointerAnalysis/PointerAnalysisCompStage.java, Analysis/Realtime/Realtime.java: Various changes to integrate the new compiler stages in the top level module (SAMain). * Analysis/PointerAnalysis/AllocSyncOptCompStage.java, Analysis/PointerAnalysis/PARTJSupportCompStage.java: Two new compiler stages: - stage for memory allocation optimizations and sync removal via pointer analysis - stage that uses pointer analysis results to offer some support to RTJ programs (debugging and check removal). 2003-04-29 wbeebee * Backend/Runtime1/init-safe.properties, Backend/Runtime1/method-root.properties: More GNU Classpath support... 2003-04-23 salcianu * bin/build-precisec: BUG FIX: build-precisec used to painstakingly collect the JVM options (-D...) from the command line and next throw them away ... (i.e., javaopts was not passed to run-java, nor was it exported). They are now properly passed to run-java, right AFTER ${flexc_options:="-Dharpoon.alloc.strategy=bdw"} This way, if your command line options specify a different allocation strategy, SAMain will actually see it :) 2003-04-22 C. Scott Ananian * Backend/MIPS/CodeGen.spec, Backend/StrongARM/CodeGen.spec, Util/Collections/BinaryTree.java, Util/Collections/IntervalTree.java, Util/Collections/RedBlackTree.java: javadoc "@see" tag syntax fixes. * GNUmakefile: Location of CVS history browsing web app has changed (although the old address redirects to the new address). 2003-04-21 salcianu * Analysis/MemOpt/PreallocOpt.java, Analysis/PointerAnalysis/MAInfo.java, Analysis/PointerAnalysis/PointerAnalysisCompStage.java, Analysis/Realtime/Realtime.java, Instrumentation/AllocationStatistics/AllocationInstrCompStage.java, Main/CodeGenerator.java, Main/CompStagePipeline.java, Main/CompilerStage.java, Main/CompilerStageEZ.java, Main/EventDrivenTransformation.java, Main/MZFCompilerStage.java, Main/RegularCompilerStageEZ.java, Main/RoleInference.java, Main/SAMain.java, Main/Transactions.java, Support/gjlib.jar: Code reorganization. * Analysis/PointerAnalysis/PAAllocSyncCompStage.java: Compiler stage for stack allocation and sync removal. 2003-04-18 salcianu * Analysis/MetaMethods/MetaCallGraph.java, Analysis/MetaMethods/MetaCallGraphAbstr.java, Analysis/PointerAnalysis/PointerAnalysis.java, Analysis/PointerAnalysis/PointerAnalysisCompStage.java, Main/SAMain.java, Support/gjlib.jar: Moving more functionality from PAMain into PointerAnalysisCompStage * Util/Collections/PersistentMap.java, Util/Collections/PersistentTreeNode.java: Make more stuff Serializable. * Main/CompilerStageEZ.java, Main/CompilerState.java: Added a new field to CompilerState: PersistentMap attribs. These map can be used to store those things that are too unusual and don't deserve a field on their own. Of course, the entire CompilerState can be just a PersistentMap; however, fields have the advantage of strong typing. * Main/CodeGenerator.java: The debugging options for the register allocation are controlled by the debug.reg-alloc environment property. * Main/CompStagePipeline.java: Two CompilerStages can be combined into a single one, using a CompStagePipeline. * Backend/Maps/FieldMap.java, Backend/Maps/MethodMap.java, Backend/Maps/NameMap.java, Backend/Runtime1/AllocationStrategy.java, Backend/Runtime1/ObjectBuilder.java, Backend/Runtime1/Runtime.java, Backend/Generic/Frame.java, Backend/Generic/LocationFactory.java, Backend/Generic/RegFileInfo.java, Backend/Generic/Runtime.java: Declared some classes Serializable, such that we can serialize CompilerStates * Analysis/MemOpt/PreallocOpt.java: unnecessary code deleted * Analysis/Realtime/CheesyPACheckRemoval.java, Analysis/Realtime/PACheckRemoval.java: Small changes to accomodate the slight change of interface in PointerAnalysis (I dropped one argument of its constructor). * Analysis/PointerAnalysis/PointerAnalysis.java, Analysis/PointerAnalysis/PointerAnalysisCompStage.java, Main/CompilerStageEZ.java, Main/SAMain.java: New compiler stage: PointerAnalysisCompStage (constructs a PointerAnalysis object). Gradually, things from the "deceased" PAMain are moved into the new compiler stage architecture. * Analysis/MemOpt/PreallocOpt.java, Analysis/MetaMethods/FakeMetaCallGraph.java, Analysis/MetaMethods/SmartCallGraph.java: Simplified a bit the SmartCallGraph / FakeMetaCallGraph interface: you can now pass them the SAMain-style program roots (taht may include classes, not only methods). Updated PreallocOpt to reflect this. * Main/CodeGenerator.java: Fix a help message. The new command line options cannot be coalesced. Therefore, "-OPR" becomes "-O -P -R". 2003-04-17 salcianu * Main/SAMain.java: cosmetic changes * Main/CodeGenerator.java, Main/SAMain.java: Some of the options in CodeGenerator were too reg-alloc-debug-specific (and were poluting the listing of our compiler options). By default, they are not included; if you need them, set the DEBUG flag on. 2003-04-16 salcianu * Support/gjlib.jar: Updated Support/gjlib.jar file. * Analysis/MemOpt/run_experiments: Update scripts to take advantage of the new harpoon.Util.Option package: new options may have multiple args, so we don't have to package multiple args in a single one (i.e. "-Z file1,file2"; we can now use "-Z file1 file2") * .cvsignore: small change * bin/build-mipsda, bin/build-mipsvp, bin/build-roles: changes similar to the one from build-precisec: -bMIPS became -b MIPS etc. * bin/build-precisec: Small change: our new options require the option arguments (compulsory and/or optional args) to be separated from the actual option. So, "-bprecisec" should now be written "-b precisec". * Analysis/Realtime/Realtime.java: Small changes to make Realtime-related processing fit in our CompilerStage architecture. * Main/SAMain.java: BIG changes. SAMain has been rewritten around the CompilerStage abstraction. The compiler is now a pipeline of stages; we built the pipeline at the beginning of the compiler and next pump the program through it. I think it now looks far nicer than the several hundred lines of the suggestively named "do_it" method. Here is a sample: private static void buildTreeFormPipeline() { addStage(new LowQuadToTree()); addStage(new WriteBarriers.WBDynamicWBTreePass()); addStage(new PreallocOpt.TreePass()); ... addStage(new RegularTreePass()); ... addStage(new RegularCompilerStageEZ("sanity-check-tree") { protected void real_action() { hcf = harpoon.Analysis.Tree.DerivationChecker.codeFactory(hcf); hcf = new CachingCodeFactory(hcf); } }); } Actions of SAMain: 1. construct pipeline of stages 2. grab options from all the stages from the pipeline and parse them by calling Option.parseOptions 3. build an initial compiler state 4. pump it through the pipeline: the pipeline starts with BuildQuadForm and ends with CodeGenerator. Almost all of the previous functionality of SAMain has been retained. The only exceptions are THREAD_INLINER and "-i" (load a serialized code factory), things were added when we're struggling with pointer analysis research (if my memory is correct) and never used afterwards. We can add them, if the public demand is overwhelming :) * Main/CodeGenerator.java: CodeGenerator has been engineered to be a CompilerStage. Actually, theer should be several compiler stages here. Unfortunately, I'm not very familiarv with this code, so I don't know where to draw the lines between the different (potential) stages, so I put all of them in a big stage. * Main/CompilerState.java: Updated JavaDoc * Main/CompilerState.java: Changes in the CompilerState abstraction: to be safe against field addition / deletion in CompilerState, the only permitted way of creating a CompilerState is: 1. at the beginning of the program: start with an empty CompilerState (i.e., all fields are null): CompiletState.EMPTY_STATE 2. change one element of an already existing CompilerState, thus producing a new CompilerState (no mutation), identical to teh original, except for the changed element. To enforce 2, the only constructor of CompilerState is now private. * Analysis/MemOpt/PreallocOpt.java: Modifications for implemting the Memory Prealloc. Optimization in the new staged architecture. * Instrumentation/AllocationStatistics/AllocationInstrCompStage.java: Compiler stage for the allocation instrumentation: options + code + static fields in one place, OUTSIDE SAMain! * Main/EventDrivenTransformation.java, Main/MIPSOptimizations.java, Main/MZFCompilerStage.java, Main/RoleInference.java, Main/Transactions.java, Main/WriteBarriers.java: New classes: I moved the code specific to advanced optimizations into external CompilerStages (see the list below). Each such stage has its own list of options (together with their help). Hopefully, all these stages wil be one day moved into their respective packages. * Main/CompilerStageEZ.java: Easy to use CompilerStage (I wrote this class after filling my 10540NR-EZ!). "easy" means that it's asy to cut and paste code from the previous version of SAMain into it: - Has an implementation of "action" that 1. calls "enabled" (abstract) to see whether the stage is activated or not. 2. unpacks the input CompilerState (into fields named hcf, classHierarchy, linker, roots), 3. calls "real_action" (abstract) 4. packs the resulting hcf, classHierarchy etc. and returns the resulting CompilerState. - packing and unpacking are safe against field additions to CompilerState (e.g., if tomorrow somebody decides to add a new field into CompilerState, that field will be propagated unchanged across stages that don't change it, without any modification to the existing stages). - Subclasses have to implement "enabled" and "real_action". real_action code can refer to hcf, classHierarchy and the other identifiers you enjoyed in SAMain. * Main/CompilerStage.java: New abstraction: CompilerStage. Hopefully, our compiler will be just a pipeline of compiler stages. Each compiler stage: - has a list of options (harpoon.Util.Options.Option) - does some processing (action) that takes a compiler state and returns another compiler state (reminder: a compiler state encapsulates all the data relevant to the program being compiled: code factory, main method, linker, roots etc.) - for debugging and friedly messages, each stage has a name * Main/ODPAMain.java, Main/PAMain.java: Remove PAMain and ODPAMain; these things will (hopefully) be integrated in SAMain. They prevented reorganization of SAMain. * Util/Options/Option.java: Small change. * Util/Options/Option.java: New package: Options - command line options, nicer than Getopt. Advantages: 1. object-oriented code - no more (huge) switch; dynamic dispatch of the "action" method instead. 2. the option name, the action it does (usually setting some boolean flags), and the help message all in one place. 3. Option.parseOptions takes a list/array of Strings and a list of options, parses the options that appear among those strings and return the unparsed Strings. Therefore, you can have several modules gradually parsing their options, instead of centralizing it in one place. Note: the code is pre-GJ-ed: it has all the generic types, but commented out (when the GJ compiler becomes more stable, we will uncomment them) 2003-04-14 C. Scott Ananian * GNUmakefile: Update the 'make backup' command to reflect the new location of the CVS repository. * GNUmakefile: Use gjdoc instead of javadoc to generate documentation; javadoc don't (yet) handle parameterized types. Also, correct the location of the overview.html file. * Tools/Annotation/Java12.cup: Update annotation tool to latest version of JSR-14 grammar. 2003-04-10 C. Scott Ananian * Main/Javap.java: Suppress 'extends java.lang.Object' in type variable bounds if there are no non-object bounds. * IR/Tree/TreeKind.java, IR/package.html: Javadoc fixes. 2003-04-09 C. Scott Ananian * bin/annotate.perl: Reg-exp match for HTML tag should be case-insensitive. Lower-case tags are mandatory for XHTML. * bin/build-spec-arm-hack, bin/build-spec-arm-pnk, bin/build-spec-mipsda, bin/build-spec-mipsvp, bin/build-spec-precisec, bin/interpret, bin/run-java: Handle spaces in arguments to scripts better. * Main/Javap.java: Fix a bug with our parsing of JSR-14 type parameter descriptor strings. The declaration 'extends Object & Comparable' is different from 'extends Comparable' because the erasure differs. We were conflating these two cases. 2003-04-08 salcianu * Main/SAMain.java, Analysis/MemOpt/PreallocOpt.java: one more commit before our group eating * Main/CompilerState.java, Main/SAMain.java: small changes * Main/CodeGenerator.java, Main/ODPAMain.java, Main/PAMain.java, Main/SAMain.java: Additional code cleaning in SAMain 2003-04-07 salcianu * Analysis/MemOpt/run_experiments, Analysis/MemOpt/time_experiments: Minor changes: putting some scripts in good shape. 2003-04-02 salcianu * Main/CodeGenerator.java, Main/SAMain.java: comments * Main/CodeGenerator.java, Main/CompilerState.java, Main/ODPAMain.java, Main/PAMain.java, Main/SAMain.java: MASSIVE restructuring: 1. New abstraction: CompilerState - tuple of things that constitute the state of the compiler: main method, set of roots, code factory, etc. Ideally, we'll split the compiler in several stages, each taking a CompilerState and returning a new one (to avoid errors, CompilerState is immutable!) 2. Code generating code was moved into CodeGenerator.java, together with its many, many options (there is a huge number of options for the register allocator, how many of them are actually used?). Hopefully, other compiler stages will be moved out of SAMain. SAMain should consist only of option parsing and the big, top-level structure. Many, many things remain to be done ... 2003-04-01 salcianu * Main/SAMain.java: Ongoing code cleaning in SAMain.java. * Main/ODPAMain.java, Main/PAMain.java, Main/SAMain.java: Fixed bug in SAMain + some forgotten commits. 2003-03-31 salcianu * Main/SAMain.java: Big changes to make SAMain more comprehensible. So far, the idea was to split the huge do_it() method into smaller units and to move the fancy optimizations into separate methods at the end of SAMain. 2003-03-28 salcianu * Main/SAMain.java: Code cleaning in SAMain: three things have been moved out of main / do_it: getMainMethod constructFrame checkOptionConsistency * Backend/Backend.java: added comments * Main/Sizer.java, Main/EDMain.java, Main/EDXMain.java, Main/EventDriven.java, Main/JMain.java, Main/ODPAMain.java, Main/Options.java, Main/PAMain.java, Main/SAMain.java, Backend/Backend.java: Added a top level class for the many backends we have: harpoon.Backend.Backend Cleaning SAMain: the constants used to simulate an enumeration for the backend kind (precisec, mips etc) have been moved harpoon.Backend.Backend: Backend.PRECISEC, Backend.MIPS. This new class also contains a convenient method Backend.getFrame (the former frameFromString from Options.java). 2003-03-18 C. Scott Ananian * Tools/Annotation/Java12.cup: Extend source code annotation tool to better handle type variables declared in class declaration. Still not perfect: 1) the scope of the class variables currently starts after the parameter block. That means that the second A in the definition > will not be linked correctly. 2) a good solution to this would be to move the scope declarations to the class_body_declarations production, making each class_body_declaration a new scope. Then some other means of implementing newInner() must be found to prevent class A defined in B.foo() and class A defined in B.bar() from conflicting. 3) HMethodTypeVariables are not handled. This is partly due to the scope issues above, and partly because the current QualName abstraction doesn't provide a good means to represent them. (perhaps add another 'method' field to the qual name?) Also the grammar is factored awkwardly for passing the eventual method name to the type variable declaration. (method type parameters can't be annotated until the method name is known, but can be referenced in the parameter block before the method name is parsed.) I did refactor code into doClassDeclaration with the result that inner classes and interfaces should be handled better (documentation comments linked, etc). * GNUmakefile: Move and un-export TARSOURCE, NONEMPTYPKGS, and PKGSWITHJAVASRC to keep the size of the exported environment down. (xargs wail failing with 'environment too large' in 'make clean' after several new source files were added to FLEX.) 2003-03-17 salcianu * Support/gjlib.jar: Updated version of Support/gjlib.jar * Analysis/MemOpt/get_stats, Analysis/MemOpt/run_experiments, Analysis/MemOpt/time_experiments: small changes in the scripts * Runtime/CounterSupport.java: small hack to take allignment into account (in an approximate manner). * ClassFile/HClassMutator.java, ClassFile/HField.java, ClassFile/HMethod.java: Improved JavaDoc. 2003-03-17 C. Scott Ananian * prj.el: Update copyright date on JDE skeleton. * ClassFile/HClass.java, ClassFile/HClassTypeVariable.java, ClassFile/HField.java, ClassFile/HFieldImpl.java, ClassFile/HFieldProxy.java, ClassFile/HMethod.java, ClassFile/HMethodImpl.java, ClassFile/HMethodProxy.java, ClassFile/HMethodTypeVariable.java, ClassFile/HParameterizedType.java, ClassFile/HType.java, ClassFile/HTypeVariable.java, Support/gjlib.jar, gj-files: Extend ClassFile package with skeletal support for parameterized types. Support was added to the IR.RawClass package some time ago (see Main.Javap for a use), but we haven't yet reflected that additional information into the HClass object. This commit still doesn't make the parameterized signatures visible; it just adds the API from the JSR14 spec which, when eventually implemented, will expose the parameterized types. For now, all of the new methods throw a RuntimeException if used. 2003-03-17 salcianu * ClassFile/HMethodMutator.java: better doc * bin/build-precisec: Big fix: if PRECISEC_FLAGS is defined as "`-g -O9`" it will be interpreted as a sigle token by gcc, and reported as an invalid option. 2003-03-16 kkz * Support/gjlib.jar: A new, more up-to-date gjlib.jar from a clean checkout of the source. 2003-03-16 salcianu * Analysis/MemOpt/IAStatistics.java, Analysis/MemOpt/PreallocOpt.java, Main/SAMain.java: Slight modification in the memory preallocation optimization to avoid adding any new class to the class hierarchy (and avoid the 22% slowdown for jess). 2003-03-15 kkz * IR/Quads/QuadSSI.java: Now we can make QuadSSI out of ResilientNoSSA. * IR/Quads/ResilientNoSSA.java, IR/Quads/ResilientUnHandler.java: Better handling for code in a try block; for exceptions that are going to be caught, throw them anyway, otherwise use the 'resilient' handling technique. 2003-03-13 C. Scott Ananian * Backend/PreciseC/TreeToC.java: Added a comment about a buglet Karen found, so that if it turns out to bit us again, we can Do The Right Thing about it. A decent work-around for the moment is to run SCCOptimize on the Quad form before translation to Tree. 2003-03-11 C. Scott Ananian * ClassFile/HClass.java, Support/gjlib.jar, gj-files: GJ-ize harpoon.ClassFile.HClass and modernize the Collections used. Have to add HClassArray, HClassPrimitive, and HClassProxy to gj-files in order for the Comparable interface to be implemented correctly. Updated gj-files and Support/gjlib.jar. [this commit is just pointless tweaking that I stumbled across as I tried to pin down a bug compiling HArrayMethod] * Analysis/PreciseGC/DynamicWBTreePass.java, Analysis/PreciseGC/WriteBarrierConstElim.java, Analysis/PreciseGC/WriteBarrierTreePass.java, gj-files, Support/gjlib.jar: The Tree Simplification class takes a List, not a plain list. Update PreciseGC/DynamicWBTreePass, PreciseGC/WriteBarrierConstElim, and PreciseGC/WriteBarrierTreePass to pass a correctly-parameterized list to their superclass. Some further GJ-ization done where appropriate. Updated gj-files and Support/gjlib.jar. As of this commit, FLEX is fully-parameterized; that is, it ought to compile correctly in its entirely using a proper implementation of the JSR-14 specification for generic java. (This doesn't mean that every class uses parameterized types, or even that even class that *ought* to use parameterized types does, but simply that FLEX has a consistent type definition using in some cases "raw" types.) In an ideal world, we would now be able to use a GJ compiler to compile all of FLEX, without using the current two-stage compilation process. Unfortunately, we cannot because the current JSR-14 prototype version 1.3, although it fixes many bugs found in its predecessors, still has the following three issues: 1) the compiler itself throws an exception when compiling Java12.java 2) The type-inference engine seems unable to resolve a call to Arrays.sort(Object[], Comparator) as a valid call to void sort(T[], Comparator) (probably according to spec, but breaks backward compatibility) 3) A bug in compiling HArrayField/HArrayMethod, which extend Comparable but not directly. So we are sticking with our two-phase compile for the moment. JSR-14 compiler version 1.3 -- which I encourage you to download and install from http://java.sun.com/people/gbracha/generics-update.html if you are still using 1.2 or earlier -- does fix many earlier bugs, and Sun is committed to distributing this with version 1.5 of the JDK, so I anticipate we will not have to use our two-phase compile for long. I may in fact switch to a mostly-GJ compile, with special treatment only for the 14 files which trigger the above 3 bugs. Also, jikes and a number of other java compiler projects are moving to support the JSR-14 GJ extensions, so I expect us to be just a little ahead of the curve here. * Backend/Analysis/InsertWriteBarrier.java, Backend/Analysis/MakeGCThreadSafe.java, Analysis/Tree/DeadCodeElimination.java, Analysis/Tree/JumpOptimization.java, Support/gjlib.jar, gj-files: The Tree Simplification class takes a List, not a plain list. Update DeadCodeElimination, JumpOptimization, InsertWriteBarrier, and MakeGCThreadSafe to pass a correctly-parameterized list to their superclass. Some further GJ-ization done where appropriate. Updated gj-files and Support/gjlib.jar. * IR/Quads/SSIToSSA.java, IR/LowQuad/LowQuadSSI.java, Analysis/LowQuad/Loop/MyLowQuadSSI.java, Analysis/EventDriven/EventDrivenCode.java, Analysis/EnvBuilder/EnvCode.java, Support/gjlib.jar, gj-files: Add a missing parameter to Analysis/EnvBuilder/EnvCode, Analysis/EventDriven/EventDrivenCode and Analysis/LowQuad/Loop/MyLowQuadSSI to get them to extend their parameterized superclass correctly. Also noticed a parameterization deficiency in LowQuadSSI, which suggested GJ-izing SSIToSSA as well. Updated gj-files and Support/gjlib.jar. * Analysis/DefaultAllocationInformation.java, Analysis/DefaultAllocationInformationMap.java, Analysis/AllocationInformationMap.java, Support/gjlib.jar, gj-files: GJ-ize AllocationInformationMap, DefaultAllocationInformation, and DefaultAllocationInformationMap to be consistent with the GJ-ized Analysis/Maps/AllocationInformation. Updated gj-files and Support/gjlib.jar. * IR/Tree/CanonicalTreeCode.java, IR/Tree/OptimizedTreeCode.java, gj-files, Support/gjlib.jar: GJ-ize CanonicalTreeCode and OptimizedTreeCode to fix a non-parameterized override of a parameterized method in the superclass (Tree.Code). This furthers the goal of getting *all* of FLEX to compile with the GJ compiler. (Note that Tools/Annotation/Java12.java currently crashes the GJ compiler, sadly enough.) 2003-03-11 wbeebee * Backend/Runtime1/class-root.properties, Backend/Runtime1/init-safe.properties, Backend/Runtime1/method-root.properties: Updated for Classpath * Support/awt-root-set, Support/cpvm.jar, Support/imagerec-root-set, Support/jacorb-root-set-classpath, Support/locale-root-set-classpath, Support/reflect-thunk.jar, Support/servo.jar: New roots for new GNU Classpath, AWT support, and Image Recognition. 2003-03-10 C. Scott Ananian * IR/Quads/Code.java, Analysis/Quads/ArrayUnroller.java, Analysis/Quads/TypeSwitchRemover.java, Analysis/Quads/Unreachable.java, Analysis/PointerAnalysis/MAInfo.java, Analysis/LowQuad/DerivationChecker.java, Support/gjlib.jar, gj-files: Fixed some users of Derivation to use the parameterized version. This involved GJ-izing DerivationChecker, TypeSwitchRemover, and Unreachable. The tighter type for Unreachable.prune() necessitated changes to ArrayUnroller and MAInfo. Updated gj-files and Support/gjlib.jar as well. * IR/Quads/ResilientNoSSA.java, IR/LowQuad/Code.java, IR/LowQuad/DerivationMap.java, IR/LowQuad/LowQuadNoSSA.java, IR/LowQuad/LowQuadSSA.java, IR/LowQuad/LowQuadSSI.java, Support/gjlib.jar, gj-files: GJ-ize IR/LowQuad/{Code,DerivationMap,LowQuadNoSSA,LowQuadSSA,LowQuadSSI}.java and IR/Quads/ResilientNoSSA.java to correct non-parameterized override of parameterized method in superclass. This furthers the goal of getting all of FLEX to compile with the GJ compiler, doing away with the current two-stage approach. Current GJ compiler still throws a null-pointer exception on some FLEX file (still trying to find the source), but the parameterized type-inference bugs of previous versions seem to have been corrected in version 1.3 of the JSR-14 compiler. Fixing IR/LowQuad/Code required parameterizing IR/LowQuad/DerivationMap, since the base Derivation interface is parameterized on HCodeElement type. Note that DerivationMap.transfer() lets you transfer types from a derivation of an HCodeElement element type dissimilar from your own. As a random aside, I'm still rather unhappy with the way strongly-typed tuples interact with the List interface -- they must always extends List because the get(i) method returns different types based on the value of the integer parameter. This makes it hard to extract the fields of the typed tuple in a type-safe manner. (See the Default.PairList class and its use in IR/LowQuad/DerivationMap and elsewhere.) Ideas here are welcomed. Updated Support/gjlib.jar, since we added new classes to gj-files. Karen, note that IR/Quads/ResilientNoSSA has been GJ-ized. * bin/find-gj: Fix file leak when using result caching. Also change prefix to be different from the autoconf test I borrowed this code from, to decrease the odds of stepping on each other's files. * bin/build-spec: Commit a forgotten building-spec-with-classpath patch. * Util/Collections/CollectionFactory.java, Util/Collections/Factories.java, Util/Collections/ListFactory.java, Util/Collections/SetFactory.java: Remove spurious 'import' statements. * bin/find-gj, .cvsignore, GNUmakefile: Made Makefile smarter about looking for a JSR-14 GJ compiler, and what options to give to it. The new bin/find-gj script tries compiling GJ code with jikes and javac first (in anticipation of a future where this support will be added to the standard tools) and then tries the JSR14DISTR javac script and some other guesses for standard locations. Each compiler is tried with both the '-source 1.4 -gj' and '-source 1.5' means of asking for GJ compatibility. To make this check faster, put the value found in .find-gj-cache in the environment variable JCC5. 2003-03-07 salcianu * Analysis/MemOpt/PreallocAllocationStrategy.java, Analysis/MemOpt/PreallocOpt.java: PreallocAllocationStrategy now extends BDWAllocationStrategy instead of MallocAll.... For non-preallocated site, we now may use GC_malloc_atomic which saves some execution time. 2003-03-05 C. Scott Ananian * bin/build-precisec: Shell variable assignments inside of $() may be done in a subshell and thus not correctly propagated to the parent shell. Move the default assignment out of the sub-shell to fix the problem. Thanks to Alex for the bug-finding and fix. 2003-03-03 salcianu * Analysis/MemOpt/get_stats, Analysis/MemOpt/run_experiments, Analysis/MemOpt/time_experiments: small changes * Support/gjlib.jar, Analysis/PointerAnalysis/MyAP.java, Analysis/Maps/AllocationInformation.java, Analysis/AllocationInformationMap.java, Analysis/ChainedAllocationProperties.java, Analysis/DefaultAllocationInformation.java: 1. Technical changes into the AllocationProperties 2. New version of Support/gjlib.jar * Analysis/MemOpt/run_experiments, Analysis/MemOpt/time_experiments: modified scripts; still far from ideal * Backend/PreciseC/Frame.java: Put the runtime selection code into a separate method; hopefully, at some point it will be factored out of PreciseC.Frame as a RuntimeFactory. * Main/SAMain.java: 1. Added long options to SAMain (we almost exhausted all the letters) 2. Changes to make sure the chain of code factories is the same in the cases of PREALLOC_OPT and ONLY_SYNC_REMOVAL (useful for timing measurements) 3. Simplified a bit the printing of the help messages: I've put all the help messages in help_lines - an array of strings. If you add a new option and want to add some info on it, just add some more elements to help_lines. * Analysis/MemOpt/AddMemoryPreallocation.java, Analysis/MemOpt/IAStatistics.java, Analysis/MemOpt/PreallocAllocationStrategy.java, Analysis/MemOpt/PreallocOpt.java: More info this time: (we've just verified that cvs commit works again) Various modifications to Memory Preallocation optimization: 1. Changes to take advantage of the soon-to-be-commited modification to BDW 2. Concentrate debug code into PreallocOpt.java 3. Add flag PreallocOpt.ONLY_SYNC_REMOVAL: run the IncompatibilityAnalysis and remove syncs on all the preallocatable objects, but don't actually preallocate them. Mostly for timing reasons: we want to measure only the difference due to memory preallocation - the memory preallocation opt. has to involve sync removal (otherwise, there are problems in the GC with the finalizers for the inflated objects). * Analysis/MemOpt/PreallocData.java: new class 2003-02-24 wbeebee * Analysis/MemOpt/PreallocOpt.java: Eliminate debugging output in the default case 2003-02-22 salcianu * Main/SAMain.java: Code cleaning: use CombineIterator(it1, it2) instead of CombineIterator(new Iterator[] { it1, it2} ) * Analysis/MemOpt/AddMemoryPreallocation.java: Removed some debug code 2003-02-21 salcianu * Main/SAMain.java, Instrumentation/AllocationStatistics/AllocationStatistics.java, Analysis/MemOpt/AddMemoryPreallocation.java, Analysis/MemOpt/IncompatibilityAnalysis.java, Analysis/MemOpt/PreallocAllocationStrategy.java, Analysis/MemOpt/PreallocOpt.java, Analysis/MemOpt/get_stats, Analysis/MemOpt/run_experiments, Analysis/MemOpt/time_experiments: various changes 2003-02-19 kkz * IR/Quads/ResilientNoSSA.java, IR/Quads/ResilientUnHandler.java: Added ResilientNoSSA pass for converting Quad-with-Try to a form of NoSSA with "resilient" exception handling---instead of throwing an exception, program will try to continue executing as far as this is possible. 2003-02-14 salcianu * Analysis/MemOpt/get_stats, Analysis/MemOpt/run_experiments, Analysis/MemOpt/time_experiments: Added my building, timing and statistics gathering scripts. Normally, we put scripts in bin; however, as these scripts are highly specialized, I decided to put them in Analysis/MemOpt. * Util/Timer.java, Analysis/MemOpt/AddMemoryPreallocation.java, Analysis/MemOpt/IAStatistics.java, Analysis/MemOpt/IncompatibilityAnalysis.java, Analysis/MemOpt/PreallocOpt.java: Small improvements and modifications. 2003-02-12 salcianu * Util/Util.java, Support/gjlib.jar, Main/ODPAMain.java, Main/PAMain.java, Instrumentation/AllocationStatistics/AllocationNumbering.java, Instrumentation/AllocationStatistics/AllocationStatistics.java, Analysis/PointerAnalysis/ComputeInterProcMuClosure.java, Analysis/PointerAnalysis/Debug.java, Analysis/PointerAnalysis/InterProcPA.java, Analysis/PointerAnalysis/MAInfo.java, Analysis/PointerAnalysis/NodeRepository.java, Analysis/PointerAnalysis/ODInterProcPA.java, Analysis/PointerAnalysis/ODMAInfo.java, Analysis/PointerAnalysis/PointerAnalysis.java, Analysis/PointerAnalysis/Stats.java, Analysis/MetaMethods/MetaCallGraphImpl.java, Analysis/MemOpt/IAStatistics.java, Analysis/MemOpt/IncompatibilityAnalysis.java, Analysis/MemOpt/PreallocAllocationStrategy.java: Refactoring (what a wonderful word!) Many pretty-printers have been moved from Analysis.PointerAnalysis.Debug to Util.Util, thus removing the un-natural dependencies of several packages on Analysis.PointerAnalysis. After a long battle with GJ bugs, I've managed to compile the code. Support/gjlib.jar has been rebuilt and it's now commited, so you shoudn't have any of these problems. 2003-02-11 salcianu * Analysis/MemOpt/package.html: Added a package.html file for the harpoon.Analysis.MemOpt package (the incompatibility analysis + preallocation optimization). * Instrumentation/AllocationStatistics/AllocationStatistics.java, Runtime/CounterSupport.java, Analysis/MemOpt/IAStatistics.java: Various changes for the allocation site instrumentation. * Main/Options.java, Backend/PreciseC/Frame.java: Comments + default case: if the AllocationStrategy passed to PreciseC.Frame is null, use the default "malloc"-based strategy. * Main/Options.java, Main/SAMain.java, Backend/PreciseC/Frame.java: The rest of the code for implementing the "AllocationStrategyFactory" trick. Note: it was implemented only for PreciseC.Frame (the other Frame's are unaffected - fortunately, their code was anyway much cleaner) * Backend/Runtime1/AllocationStrategyFactory.java: New class: AllocationStrategyFactory Given a Frame, produces an AllocationStrategy (and we have MANY of them: Instrumented, Preallocated, RTJ, nifty, niftystats, bdw, malloc etc.) Remember that messy code in PreciseC.Frame for detecting the appropriate AllocationStrategy? I'm moving it into SAMain: SAMain creates a Frame by passing it an appropriate AllocationStrategyFactory, based on the command line options and the value of "harpoon.alloc.strategy". Hopefully, this will eliminate many strange dependencies (why should Frame depend on command line args and static fields scattered all over the code?) The reason we pass a factory, and not an AllocationStrategy is that most AllocationStrategies constructors require a frame; therefore, they cannot be created before the call to the constructor of Frame. * Instrumentation/AllocationStatistics/AllocationNumbering.java, Instrumentation/AllocationStatistics/AllocationNumberingInterf.java, Instrumentation/AllocationStatistics/AllocationNumberingStub.java, Instrumentation/AllocationStatistics/InstrumentAllocs.java, Instrumentation/AllocationStatistics/InstrumentAllocs2.java, Instrumentation/AllocationStatistics/InstrumentedAllocationStrategy.java, Instrumentation/AllocationStatistics/UnknownAllocationSiteError.java: New allocation instrumentation appears to work! InstrumentedAllocationStrategy contains the only example I know about of generating a (non-native) CALL in tree form from scratch (not just converting a low quad PCALL intop a tree CALL). It's actually very neat and easy, but it's always hard to do it without any example. New class: UnknownAllocationSiteError for the case where we want to find the unique ID of an allocation site that was not seen by AllocationNUmbering (previously, we were just throwing Error). Not an Exception as 1) it's not supposed to be caught outside the instrumentation pacakage and 2) declaring thrown exceptions is not that fun. 2003-02-10 salcianu * Instrumentation/AllocationStatistics/AllocationNumbering.java, Instrumentation/AllocationStatistics/InstrumentAllocs2.java, Instrumentation/AllocationStatistics/InstrumentedAllocationStrategy.java: more work on the allocation site instrumentation 2003-02-09 salcianu * Main/SAMain.java, Analysis/MemOpt/AddMemoryPreallocation.java, Analysis/MemOpt/IAStatistics.java, Analysis/MemOpt/IncompatibilityAnalysis.java: More code cleaning * Runtime/CounterSupport.java, Instrumentation/AllocationStatistics/AllocationStatistics.java: More work on the new instrumentation for the allocation sites: - added a new method count2(allocID, length) in CounterSupport: it will be called by the instrumentation to record how many objects and how much space weas allocated at each site - refactored some of the code in CounterSupport - more intuitive names (i.e. "long array[]" was not that informative) - modified both the code that outputs the instrumentation results (in CounterSupport) and the parsing code from AllocationStatistics) 2003-02-08 salcianu * Instrumentation/AllocationStatistics/InstrumentedAllocationStrategy.java: More work on instrumentation * Support/gjlib.jar: updated Support/gjlib.jar * Instrumentation/AllocationStatistics/InstrumentAllocs2.java: Added more comments * Analysis/MemOpt/PreallocOpt.java, Analysis/Maps/AllocationInformation.java, Analysis/DefaultAllocationInformation.java: small changes * Analysis/PointerAnalysis/MyAP.java: small change * Instrumentation/AllocationStatistics/InstrumentAllocs.java, Instrumentation/AllocationStatistics/InstrumentAllocs2.java, Instrumentation/AllocationStatistics/InstrumentedAllocationStrategy.java: Adding several new instrumenatation classes for allocation sites. This instrumentation is made at the Tree format level, where we have access to the size of the allocated memory (which can be quite difficult to compute in Quad form, especially for multi-dimensional arrays). * Analysis/ChainedAllocationProperties.java: Convenient class to allow us to update some of the allocation properties attached with an allocation site. * Analysis/MemOpt/AddMemoryPreallocation.java: Remove debug code * Analysis/DefaultAllocationInformationMap.java: New class: combination of AllocationInformationMap and DefaultAllocationInformation. * Analysis/AllocationInformationMap.java: Remove debug test * Analysis/MemOpt/TestMemOpt.java: Remove unused file 2003-02-07 salcianu * IR/Tree/ESEQ.java, IR/Tree/SEQ.java: Moderate a bit some comments * IR/Tree/ESEQ.java, IR/Tree/SEQ.java: Added convenient constructors to SEQ and ESEQ. 2003-02-03 salcianu * Main/ODPAMain.java, Main/PAMain.java, Main/SAMain.java, Instrumentation/AllocationStatistics/AllocationNumbering.java, Instrumentation/AllocationStatistics/AllocationNumberingStub.java, Instrumentation/AllocationStatistics/AllocationStatistics.java, Instrumentation/AllocationStatistics/package.html, Instrumentation/package.html: More code cleaning of the allocation statistics package and some package.html files (one of them is a full tutorial). * Analysis/PointerAnalysis/InstrumentSyncOps.java: added back accidentally removed file * Main/MemOptMain.java, Main/ODPAMain.java, Main/PAMain.java, Main/SAMain.java, Instrumentation/AllocationStatistics/AllocationNumbering.java, Instrumentation/AllocationStatistics/AllocationNumberingInterf.java, Instrumentation/AllocationStatistics/AllocationNumberingStub.java, Instrumentation/AllocationStatistics/AllocationStatistics.java, Instrumentation/AllocationStatistics/InstrumentAllocs.java, Analysis/PointerAnalysis/AllocationNumbering.java, Analysis/PointerAnalysis/AllocationStatistics.java, Analysis/PointerAnalysis/InstrumentAllocs.java, Analysis/PointerAnalysis/InstrumentSyncOps.java, Analysis/MemOpt/IAStatistics.java, Analysis/MemOpt/PreallocOpt.java: New directories for instrumentation code: Instrumentation, Instrumentation/AllocationStatistics Moved the allocation instr. code from PointerAnalysis to Instrumentation/AllocationStatistics * Analysis/PointerAnalysis/AllocationNumbering.java, Analysis/PointerAnalysis/AllocationStatistics.java: Code cleaning 2003-01-31 wbeebee * Analysis/Realtime/init-safe.properties, Analysis/Realtime/rtjperf-method.properties: Changes to accomodate GNU Classpath 0.05. * Backend/Runtime1/init-safe.properties, Backend/Runtime1/method-root.properties: Upgrades to make FLEX compatible with GNU Classpath 0.05. 2003-01-08 wbeebee * Analysis/Realtime/thread-method.properties: Support masking of handlers so that the user can temporarily turn off certain handlers... 2003-01-07 salcianu * Analysis/MemOpt/IAStatistics.java: One more forgotten commit ... * Support/gjlib.jar: up-to-date Support/gjlib.jar * Main/MemOptMain.java, Main/SAMain.java, Analysis/PointerAnalysis/Debug.java, Analysis/MemOpt/AddMemoryPreallocation.java, Analysis/MemOpt/IADriver.java, Analysis/MemOpt/IAStatistics.java, Analysis/MemOpt/IncompatibilityAnalysis.java, Analysis/MemOpt/PreallocAllocationStrategy.java, Analysis/MemOpt/PreallocOpt.java: forgotten commits (1 month ...) for the memory preallocation experiments 2002-12-04 salcianu * Support/gjlib.jar: updated gjlib.jar * Analysis/PointerAnalysis/AllocationNumbering.java, Analysis/PointerAnalysis/AllocationStatistics.java, Analysis/MemOpt/IAStatistics.java, Analysis/MemOpt/IncompatibilityAnalysis.java, Analysis/MemOpt/PreallocOpt.java: Many chnages for grabbing the right statistics. 2002-12-02 salcianu * Main/SAMain.java, Analysis/PointerAnalysis/AllocationNumbering.java, Analysis/PointerAnalysis/AllocationStatistics.java, Analysis/MemOpt/AddMemoryPreallocation.java, Analysis/MemOpt/PreallocAllocationStrategy.java, Analysis/MemOpt/PreallocOpt.java: With Scott's help, I fixed my allocation instrumentation code to work fine with obfuscated code (e.g., mpegaudio) that uses Unicode characters in the method/classes names. Wes, I think your application at Berkley has some chances :) Even if you didn't travel to Zimbabwe to discover your roots, you work in a project that allows people to fully express their personality by using identifiers rooted in their native culture :) Wait until I start using Romanian words in the FLEX code (of course, just kidding) * Main/SAMain.java, Analysis/PointerAnalysis/AllocationNumbering.java: 1. priniting some statistics in AllocationNumbering 2. by default, sync and calls are not instrumented (only allocations are) * Analysis/PointerAnalysis/AllocationNumbering.java, Analysis/PointerAnalysis/AllocationStatistics.java: small changes to process some benchmarks * Main/SAMain.java: Correcting the default value of INSTRUMENT_ALLOCS_STUB * Support/gjlib.jar, Main/SAMain.java, Analysis/PointerAnalysis/AllocationStatistics.java: Sorry for all the people that had trouble compiling FLEX this morning; hopefully, it should be all solved now. * Analysis/MemOpt/PreallocOpt.java, Support/gjlib.jar: new gjlib.jar + small changes in PreallocOpt * Main/MemOptMain.java, Main/PAMain.java, Main/SAMain.java: small changes * Analysis/PointerAnalysis/AllocationStatistics.java, Analysis/MemOpt/IAStatistics.java: forgotten commit 2002-12-01 salcianu * Main/MemOptMain.java, Main/SAMain.java, IR/Quads/QuadSSI.java: various changes * Analysis/PointerAnalysis/AllocationStatistics.java, Analysis/MemOpt/IAStatistics.java: more code for statistics * Analysis/MemOpt/PreallocOpt.java, Analysis/PointerAnalysis/AllocationNumbering.java, Analysis/PointerAnalysis/InstrumentAllocs.java: lots of hacking for generating statistics 2002-11-30 salcianu * Support/gjlib.jar: minot changes * Analysis/Quads/DeadCode.java, IR/Quads/Code.java, IR/Quads/QuadSSI.java: Added a new parameter to IR.Quads.Code.replace: teh map of old temps to new temps. On long term, DeadCode.optimize shoudl simply call replace, without dirrectly handling the allocation information conversion details. 2002-11-30 wbeebee * Support/gjlib.jar: Alex forgot to make a new gjlib.jar file after committing his changes to includes from GJized Harpoon Code. This broke recompiling from scratch. I'm committing the new gjlib.jar that includes Alex's changes. 2002-11-30 salcianu * Analysis/MetaMethods/FakeMetaCallGraph.java, Analysis/MetaMethods/MetaCallGraphImpl.java: unimportant changes * Analysis/MetaMethods/SmartCallGraph.java: Make sure SmartCallGraph fully implements the CallGraph interface. * Analysis/MemOpt/AddMemoryPreallocation.java, Analysis/MemOpt/IADriver.java, Analysis/MemOpt/IncompatibilityAnalysis.java, Analysis/MemOpt/PreallocOpt.java, Main/SAMain.java: Final commits for this evening. The memory pre-allocation optimization is now known to work on JLex (the biggest program tried so far). 1. Better organization of the code to minimize the impact on SAMain (which is pretty cluttered anyway) 2. Lots of new Javadoc comments 3. Removed some unused debugging code (not all debugging code, though, as tough times awaits me!) * IR/Quads/Code.java, IR/Quads/QuadSSI.java, Analysis/Quads/DeadCode.java: 1. New method added to harpoon.IR.Quads.Code: notifyReplace(oldQuad, newQuad) When an optimization (e.g., DeadCode.optimize()) replaces a quad with another one, it should call notifyReplace such that the Code object has a chance of updating some method-wide mappings, e.g., the quad NoSSA <-> quad SSI mappings that Ovy and I need to maintain (such that we can move results between these two quad formats). Subclasses of Code should override this method with whatever code they need to maintain the consistency of their own data with respect to quad replacement. 2. DeadCode.optimize() was modified to invoke notifyReplace 3. QuadSSI overrides notifyReplace; as a consequence, it is now able to remove the dead code and avoid some spectacular program crash in the backend due to forgotten TYPECAST (apparently, all TYPECASTs should be replaced with INSTANCEOFs). 2002-11-29 salcianu * Analysis/MemOpt/PreallocOpt.java: more code for the preallocation optimization * IR/Tree/Tree.java: 1. Tree.unlink() is now public 2. unlink code has been changed to cut BOTH parent->child and child->parent links 2002-11-29 ovy * Analysis/MemOpt/IADriver.java, Analysis/MemOpt/IncompatibilityAnalysis.java: - optimization to enable us to run on the javac benchmark in reasonable time for a change - re-enabled SSI prebuild in IADriver to get timings compatible with those in the POPL paper 2002-11-29 salcianu * Main/SAMain.java, Analysis/MemOpt/AddMemoryPreallocation.java, Analysis/MemOpt/PreallocAllocationStrategy.java, Backend/PreciseC/Frame.java: New AllocationStrategy to support the memory preallocation optimization. Some other related related changes. * Analysis/MemOpt/IncompatibilityAnalysis.java: small changes in the comments * Analysis/PointerAnalysis/MyAP.java: added cope to deal with the new Alloc. Properties * Analysis/Maps/AllocationInformation.java: New method for the memory preallocation optimization getMemoryChunkField(). * Analysis/AllocationInformationMap.java, Analysis/DefaultAllocationInformation.java: Added some code to support the new addition to the AllocationProperties. * Analysis/Quads/AbstrCallGraph.java, Analysis/Quads/CachingCallGraph.java, Analysis/Quads/CallGraph.java, Analysis/Quads/CallGraphImpl.java: Small changes: - added a load_caches method to CachingCallGraph to measure the call construction time - added an optional operation getRunMethods() to the CallGraph interface * Util/Collections/WorkSet.java: making some things Serializable 2002-11-27 salcianu * Main/SAMain.java, Analysis/MemOpt/PreallocOpt.java: Set the default value of OVY_PREALLO_OPT to false. * Analysis/MemOpt/PreallocOpt.java: Commented out some code to allow FLEX to compile. * Analysis/MemOpt/PreallocOpt.java: New class: code for the static preallocation optimization (using Ovy's IncompatibilityAnalysis). More to come. * Main/MemOptMain.java, Main/PAMain.java, Main/SAMain.java, Main/Sizer.java: Various small changes. Among other things, all the root set creation code has been taken out of the huge SAMain.do_it method and put into a separated method. It would be good to do the same thing with the rest of do_it (it's really TOO big!). Also added OVY_PREALLOC_OPT flag and code to call the static preallocation optimization enabled by Ovy's analysis. * Analysis/PointerAnalysis/ComputeInterProcMuClosure.java, Analysis/PointerAnalysis/InterProcPA.java, Analysis/PointerAnalysis/LightPAEdgeSet.java, Analysis/PointerAnalysis/MAInfo.java, Analysis/PointerAnalysis/Matching.java, Analysis/PointerAnalysis/NodeRepository.java, Analysis/PointerAnalysis/PANode.java, Analysis/PointerAnalysis/PointerAnalysis.java, Analysis/PointerAnalysis/PointsToGraph.java: Forgotten commit: small modifications in the Pointer Analysis code. 2002-11-25 wbeebee * Analysis/Realtime/QuantaChecker.java, Analysis/Realtime/Realtime.java: Added support for preemptive and non-preemptive scheduling. 2002-10-11 wbeebee * Analysis/Realtime/realtime-method.properties: Runtime calls a few more methods for RTJ now... 2002-10-09 wbeebee * bin/build-precisec: Set up so that HOST_PREFIX="arm-linux-" is all you need for build-precisec to use the correct cross-compiler. 2002-10-09 salcianu * Main/SAMain.java: The infamous "alexhack" is gone! 2002-10-04 salcianu * Main/MemOptMain.java: removed some dead code * Analysis/PointerAnalysis/AllocationNumbering.java, Analysis/PointerAnalysis/InstrumentAllocs.java: adding some comments * Analysis/Realtime/Realtime.java, Analysis/Realtime/RealtimeRuntime.java: inessential, formatting changes 2002-09-29 wbeebee * Analysis/Quads/ArrayCopyInliner.java: Now inlines all methods beginning with arraycopy, like arraycopy_backwards... 2002-09-27 wbeebee * Analysis/Quads/ArrayCopyInliner.java: Wasn't actually inlining arraycopy's.... this one does. And if someone else names something arraycopy - it gets inlined too. 2002-09-27 C. Scott Ananian * Analysis/SizeOpt/BitWidthAnalysis.java: Weird bug found by Wes in size optimizations as applied to java.awt.event.FocusEvent.paramString() when compiling the StringGrid JacORB client: occasionally we'd identify a field as definitely initialized, and then the class supposed to do the definite initialization would end up uninstantiated. So all the GETs waiting to see what the field would end up becoming languish and Bad Things Happen. Now we add a little check at the end of the analysis for uninitialized definitely-initialized fields and set them to *some* value so that the analysis can complete. The next QuadClassHierarchy analysis done will then pick up on the fact that no constructors for these classes are ever called and make all of the virtual methods of the classes unreachable. If you really wanted, you could then iterate the Bitwidth optimizations with the new information about uncallable methods --- the only way to avoid the iteration is by doing classhierarchy analysis concurrent with the bitwidth analysis, and the bitwidth analysis is hairy enough as it is! Cliff Click's thesis work addressed this work of problem. And now he's working for Sun on their server JVM. Coincidence? Yes. 2002-09-26 C. Scott Ananian * Main/SAMain.java: Tweak this to keep all the inline-arraycopy'ing together in one place. 2002-09-26 wbeebee * Main/SAMain.java: Inline arraycopies with the -Dharpoon.inline.arraycopy=true option... 2002-09-25 C. Scott Ananian * Backend/Runtime1/sunjdk.init-safe.properties: Who was I kidding? Thread.start() isn't init-safe! [This was added in revision 1.3 of init-safe.properties, apparently to make the JacORB clients compile. I'm about to fix this issue 'for real'.] 2002-09-24 wbeebee * Backend/Runtime1/ROOTS-README: A discussion of roots and what they mean... * Backend/Runtime1/class-root.properties: Needed a comment - so [Ljava.lang.ClassLoader; comes from jikes compiling ClassLoader.class. * Backend/Runtime1/class-root.properties: [Ljava/lang/Classloader is needed for Classpath 2002-09-24 C. Scott Ananian * Backend/Runtime1/init-safe.properties: init-safe properties for java.lang.Thread were still those left over from sunjdk. Properly updated them for GNU classpath based on our (now complete) implementation of Thread.java's native methods. * Backend/Runtime1/init-safe.properties: Revert part of previous commit. I decided that pretending runFinalization() was safe was a bad idea. We now have a runFinalization$$initcheck() method which warns and dies instead. Also, the Runtime.insertSystemProperties hack was just plain wrong. This was a bug in Classpath, not our bug. * bin/run-java: Allow specification of CLASSPATH_HOME in the environment to override the classpath-config script. This lets you more easily use CVS pulls of GNU classpath. 2002-09-24 wbeebee * Backend/Runtime1/init-safe.properties: Lots of java.io.ObjectInputStream is actually init-safe. Runtime.insertSystemProperties is not init-safe though, since being init-safe would involve it in an initialization cycle that actually isn't OK (as opposed to the initialization cycles that are OK that are specifically allowed by the JLS and break any attempts to statically eliminate this possibly non-deterministic source of runtime errors.) Runtime.runFinalization is most certainly not init-safe, but we'll pretend it's safe because we can't easily figure out what it might depend on -> and, well, if you're finalizers can't handle a somewhat broken (and possibly uninitialized) world, it's your own fault. Realize, though that this means another source of runtime errors for programs which depend on finalization. java.net.PlainSocketImpl.available is init-safe - and maybe we might get around to actually implementing it the right way (as opposed to always returning a zero). Thread.nativeInit, nativeSetPriority, and sleep are also all init-safe. * Support/jacorb-root-set, Support/jacorb-root-set-sunjdk: jacorb-root-set is different depending on whether you use Classpath or the SunJDK. @RENAME: jacorb-root-set jacorb-root-set-sunjdk@ * Support/jacorb-root-set-classpath: jacorb-root-set is different depending on whether you use Classpath or the SunJDK. @SPLIT: jacorb-root-set jacorb-root-set-classpath@ 2002-09-21 C. Scott Ananian * IR/Quads/Translate.java: Bug fix for the 'missing HANDLER' bug exposed by the com.sun.media.jai.util.Service class. Thanks to Wes for rediscovering this bug, which I'd lost the test case for. And my new fix makes more sense than my old fix, so all's well that ends well. Basically, fixupHandlers() was calling s.recordHandlers() with a bogus State object, and it was coming back to haunt it. Now we store a valid State with the PHI, and all's well. Added some new toString() methods for debugging, too. 2002-09-19 wbeebee * Analysis/AbstractClassFixupRelinker.java: Ditching extraneous output. 2002-09-19 C. Scott Ananian * IR/Bytecode/OpMethod.java: jikes v1.16 has decided to start invoking methods of arrays directly, which broke some of our bytecode-parsing code. However, it seems that JLS 10.7 supports them, even though it is obvious that the bytecode format was never designed for this --- so we'll go ahead and play along with jikes for the moment. 2002-09-13 wbeebee * Analysis/Quads/ArrayCopyInliner.java, Analysis/Quads/SmallMethodInliner.java: Whoops - forgot where IntMap was... * Analysis/Quads/ArrayCopyInliner.java, Analysis/Quads/SmallMethodInliner.java: Modified SmallMethodInliner to support overriding the score function and created ArrayCopyInliner to ensure that arraycopy's were inlined. 2002-09-10 wbeebee * Analysis/AbstractClassFixupRelinker.java: Bug: forDescriptor -> fixup causes infinite recursion on forDescriptor Scott fix: fixup after forDescriptor has returned to top level. This is OK because we don't care about fixup until class emit time - at which time everything's in the cache anyway. 2002-09-10 C. Scott Ananian * Analysis/AbstractClassFixupRelinker.java: Whoops -- committed AbstractClassFixupRelinker with some tweaks to the comments lying unsaved in a hidden emacs window. This commit just updates the documentation to explain our rationale better. * Analysis/AbstractClassFixupRelinker.java: Be more aggressive in fixing up classes mentioned in other classes. This seems to prevent us from delaying the fixup until the "worst possible time", i.e. when FLEX is in the middle of changing class and method signatures during some transformation. The specific bug I was seeing (that this commit fixes) had to do with the unused and uncompiled class java.awt.RenderingHints being "fixed up" in the middle of InitializerTransform when HClass.getMutator() was called on java.awt.Component. Component had a *field* of type RenderingHints which got 'relinked' during the creation of the mutator; this caused RenderingHints to be 'fixed up' at a point *after* the split of Map.entrySet() to Map.entrySet$$initcheck(). Since RenderingHints was not only uninstantiated, but unreferenced in compiled code (I think the Component class containing the RenderingHints field was uninstantiable in this program), the MethodSplitter of course did not split RenderingHints.entrySet() to RenderingHints.entrySet$$initcheck (MethodSplitter didn't even know about RenderingHints because it didn't show up anywhere in the ClassHierarchy). Because RenderingHints didn't contain the RenderingHints.entrySet$$initcheck method needed to implement the (already split) Map.entrySet$$initcheck interface method, AbstractClassFixupRelinker was dying on an assertion. Changing to a more aggressive strategy ensures that RenderingHints is fixed up *before* InitializerTransform is run, bypassing the whole problem. * Backend/Runtime1/method-root.properties: Add NoSuchFieldException and NoSuchMethodException, which are thrown by the native implementations of Class.getField(), Class.getMethod(), and Class.getConstructor(). * Main/SAMain.java, IR/LowQuad/Translate.java, Analysis/Quads/Virtualize.java, Support/gjlib.jar, gj-files: Bug-fix for dangling symbols when building with GNU classpath. java.security.CodeSource referenced the final method java.net.URL.hashCode (there were similar references to java.net.URL.equals); however, java.net.URL was never instantiated by the code, so the QuadClassHierarchy correctly inferred that java.net.URL.hashCode was uncallable. The harpoon.IR.LowQuad.Translate class converted the virtual call to URL.hashCode() to a non-virtual call because URL.hashCode() was final. However, this non-virtual call leaves a dangling reference to a method which will never be compiled. The correct thing to do is to avoid non-virtualizing uncallable methods; this is what harpoon.Analysis.Quads.Nonvirtualize does, for example. But harpoon.IR.LowQuad.Translate isn't really smart enough to do this itself; it doesn't know anything about class hierarchies or callable methods and I'd like to keep it that way. So I've just disabled the "smart" non-virtualization in LowQuad.Translate, and added another invocation of Analysis.Quads.Nonvirtualize in the factory chain just before the conversion to low-quad. This means that our end-result will be the same (actually, maybe slightly better). There's a parallel case having to do with explicit non-virtual references in input bytecode to methods later found uncallable (i.e. references that were non-virtual from the start, as opposed to virtual references that we've made non-virtual at some point). The new Virtualize pass takes care of these, even though I haven't actually come across this problem in the bytecode inputs we're seeing at the moment. Also updated gj-files and Support/gjlib.jar with the new GJ code (the Virtualize pass). * Support/cpvm.jar, Support/reflect-thunk.jar, bin/run-java: Improve GNU Classpath support in bin/run-java: now uses classpath-config, if available, to locate the GNU Classpath glibj.zip file, and uses the versions of reflect-thunk.jar and cpvm.jar from RUNTIME_DIR, if possible (otherwise it looks for these in Support). Added up-to-date versions of reflect-thunk.jar and cpvm.jar to Support to better enable Runtime-less compilation. * Backend/Runtime1/init-safe.properties, Backend/Runtime1/method-root.properties: Tweak the init-safe and method-root properties to get 'Hello, world' to run on GNU classpath. If the size of the arrays in gnu.java.io.decode.Decoder8859_1/gnu.java.io.encode.Encoder8859_1 get to be a problem, you could always use your own (different) default encoding. Look at gnu.java.io.EncodingManager. 2002-09-09 C. Scott Ananian * Backend/Runtime1/method-root.properties: Valid method root set for GNU classpath. 2002-09-08 C. Scott Ananian * Backend/Runtime1/init-safe.properties: More classpath init-safe properties hacking: ClassLoader has no native methods; using a pure-java implementation of printStackTrace(), and nativeGetLibname, nativeLoad, and insertSystemProperties in java.lang.Runtime are safe. * Backend/Runtime1/init-safe.properties: Added init-safe entries for VMClassLoader and VMSecurityManager. * Backend/Runtime1/DataReflection1.java, Backend/Runtime1/init-safe.properties: Update init-safe properties and DataReflection1 table generation to correspond with the newly-minted implementation of java.lang.Class for GNU classpath. 2002-09-06 C. Scott Ananian * Support/reflect-thunk.jar: Updated reflect-thunk.jar with the recent changes to Runtime/src/java.lang.reflect --- primarily, Method/Field/Constructor were made subclasses of AccessibleObject. * Backend/Runtime1/class-root.properties, Backend/Runtime1/init-safe.properties: Add class root properties for GNU classpath. Fix some problems with the init-safe properties for classpath: a missing newline, and some method name ambiguity problems that required adding signature information. * ClassFile/Linker.java: Make the cause of parsing errors more obvious. * Backend/Runtime1/init-safe.properties: Initial set of init-safe properties for Classpath, verified against its native implementations. 2002-09-06 wbeebee * Analysis/Realtime/Realtime.java: Now CheckQuanta no longer needs to be called to support thread switching. This has a (small) performance benefit, reduces the size of instrumented methods, doesn't guarantee thread progress, but provides support for C threads as well as Java threads. scheduleID is used to schedule a C thread as opposed to a Java thread. C threads obey the convention of having negative UID's, which Java threads have positive UID's. This way, the RTJ scheduler can schedule RealtimeThreads with real-time constraints with a higher priority than C threads that do not have such constraints unless the C thread explicitly informs the RTJ scheduler otherwise. Soon, C threads will use a completely POSIX-compliant interface (enabling snarfing multithreaded native code for use in RTJ-enabled real-time systems). 2002-09-05 C. Scott Ananian * GNUmakefile: Hmm... the buggy bash version is more buggy than I thought --- surrounding the offending command in an 'if' doesn't help, because it dies w/ a syntax error on the contents of the if even if the body of the if is never executed. So here's another way to workaround the problem. 2002-09-05 wbeebee * Support/realtime.jar: Removing realtime.jar. 2002-09-04 C. Scott Ananian * bin/run-java: Change canonical location of realtime.jar: ${REALTIME_DIR}/realtime.jar (which defaults to ~/Harpoon/Realtime/realtime.jar). Remove Support/realtime.jar. This pre-built file is available from the flex web page if it is needed (otherwise just check out Realtime and run make). * Support/gjlib.jar: Support/gjlib.jar appeared to be out-dated; in particular the compiled version of harpoon.ClassFile.HCode was out-of-date. * GNUmakefile: Oops: last commit broke the build, due to an overly-long command line. This should fix it. 2002-09-03 wbeebee * bin/find-flex-dir: Create a REALTIME_DIR environment variable. 2002-09-03 C. Scott Ananian * GNUmakefile: Work around broken versions of bash, which can't deal with 'for' statements with no elements in the list. * Analysis/SizeOpt/MZFExternalize.java: Remove use of deprecated HCode.getElements() in MZFExternalize. * Analysis/SizeOpt/MZFChooser.java, Analysis/SizeOpt/MZFCompressor.java, Analysis/SizeOpt/MZFWidenType.java: Change the type of the interface from using Integer to Number to hide implementation details. * IR/Tree/Code.java, IR/Quads/Code.java, IR/Bytecode/Code.java, ClassFile/HCode.java: Completely remove the deprecated 'getElementsE()' method of HCode, thanks to Wes' deprecation-reduction work. Also remove getElementsI() in harpoon.IR.Bytecode.Code, which now duplicates code in the superclass. Add deprecation tages to Quads.Code.getElements() and Tree.Code.getElements(), which were causing the @deprecation tag in HCode.getElements() to be overruled in many cases. This exposes many more uses of getElements(), unfortunately --- maybe this method shouldn't be deprecated after all? * Util/Graph.java, Main/TypesMain.java, IR/Quads/ReHandlerToSSA.java, IR/Bytecode/Code.java, Analysis/TypeInference/IntraProc.java, Analysis/SizeOpt/FieldReducer.java, Analysis/SizeOpt/MZFCompressor.java, Analysis/SizeOpt/MZFWidenType.java, Analysis/SizeOpt/MostlyZeroFinder.java, Analysis/SizeOpt/SizeCounters.java, Analysis/Quads/SCC/SCCOptimize.java: The other half of Wes' "reduce deprecation" patch; modified to use SnapshotIterators where necessary. * Support/gjlib.jar, gj-files, Analysis/Quads/ComponentOfReducer.java, Analysis/Quads/MemoryOptimization.java, Analysis/Quads/MethodTraceFactory.java, Analysis/Quads/Nonvirtualize.java, Analysis/Counters/EpilogMutator.java, Analysis/Counters/RuntimeMethodCloner.java: GJ-ize and reduce deprecation in: harpoon.Analysis.Counters.EpilogMutator harpoon.Analysis.Counters.RuntimeMethodCloner harpoon.Analysis.Quads.ComponentOfReducer harpoon.Analysis.Quads.MemoryOptimization harpoon.Analysis.Quads.MethodTraceFactory harpoon.Analysis.Quads.Nonvirtualize.java This is based on wbeebee's original 'reduce deprecation' patch; note however the use of SnapshotIterator, necessary to preserve correctness. * Analysis/SizeOpt/Field2Method.java, Analysis/SizeOpt/FieldReducer.java, Analysis/SizeOpt/MZFChooser.java, Analysis/SizeOpt/MZFCompressor.java, Analysis/SizeOpt/MZFExternalize.java, Analysis/SizeOpt/MZFWidenType.java, Analysis/SizeOpt/MostlyZeroFinder.java, Analysis/SizeOpt/SizeCounters.java, Support/gjlib.jar, Util/Default.java, gj-files: GJ-ize the harpoon.Analysis.SizeOpt package. This required exposing the PairList class of harpoon.Util.Default; not sure if this was a good or bad choice, in retrospect. The types are more precise & informative, sure, but I'm not convinced they are more *useful*. 2002-09-02 C. Scott Ananian * Analysis/Maps/AllocationInformation.java, Analysis/Maps/ConstMap.java, Analysis/Maps/ConstMapProxy.java, Analysis/Maps/DefaultMap.java, Analysis/Maps/Derivation.java, Analysis/Maps/ExactTypeMap.java, Analysis/Maps/ExactTypeMapProxy.java, Analysis/Maps/ExecMap.java, Analysis/Maps/ExecMapProxy.java, Analysis/Maps/MapProxy.java, Analysis/Maps/TypeMap.java, Analysis/Maps/TypeMapProxy.java, Analysis/Maps/UseDefMap.java, Support/gjlib.jar, gj-files: GJ-ize the harpoon.Analysis.Maps package & rebuild Support/gjlib.jar. 2002-09-01 C. Scott Ananian * IR/Tree/Code.java, IR/Tree/TreeCode.java, IR/Quads/Code.java, IR/Quads/Quad.java, IR/Quads/QuadNoSSA.java, IR/Quads/QuadRSSx.java, IR/Quads/QuadSSA.java, IR/Quads/QuadSSI.java, IR/Quads/QuadWithTry.java, ClassFile/HCode.java, ClassFile/HCodeAndMaps.java, Support/gjlib.jar, Analysis/Transformation/MethodMutator.java, gj-files: 1) GJ-ized HCodeAndMaps. 2) Changed signature of HCode.clone() to return parameterized HCodeAndMaps. 3) Changed classes in IR/Quads and IR/Tree to implement this new signature. Ended up further GJ-izing Quad.java, Tree/Code.java. 4) Used parameterized HCodeAndMaps to parameterize MethodMutator. 5) Rebuilt Support/gjlib.jar with these changes. * Temp/CloningTempMap.java, gj-files: GJ-ized CloningTempMap. * IR/Quads/HANDLER.java, IR/Quads/PHI.java, Analysis/Quads/AbstrCallGraph.java, Analysis/Quads/CallGraphImpl.java: GJ-ized several classes, removing 'unchecked cast' warnings. 2002-08-30 C. Scott Ananian * GNUmakefile: Bug-fix to keep 'make jar' from building the jar file *twice*. (Once for the Harpoon.jar target, and once for the Harpoon.jar.TIMESTAMP target.) * Analysis/Realtime/CheckAdder.java, Analysis/Realtime/ClassReplacer.java, Analysis/Realtime/QuantaChecker.java: Fix bugs introduced by Wes' commit on Wed, 14 Aug 2002 16:51:51. He was trying to reduce the use of deprecated methods, but his changes could cause illegal concurrent modification of the HCode by the visitor during iteration. Thanks to Patrick for pointing me to the 'snapshot' vocabulary which I've used in my fix. Moral: beware 'trivial' changes! * ClassFile/HCode.java: Note that the getElementsL() method of HCode does not necessarily give a snapshot view (unlike getElements(), whose interface dictates it must). * IR/Tree/TreeFactory.java, IR/Tree/Code.java, IR/Tree/Data.java, IR/Tree/Tree.java, IR/Quads/Code.java, IR/Quads/Quad.java, IR/Assem/Code.java, IR/Assem/Instr.java, Support/gjlib.jar: Make iterators returned by getElementsI() fail-fast under concurrent modification. (Note that there is no way to modify the underlying representation for harpoon.IR.Bytecode.Code, so that iterator doesn't need to be fail-fast.) Also update Support/gjlib.jar w/ these changes, as we've added fields and whatnot. Now incorrect substitutions of getElementsI() for getElements() in cases where element mutation is done during the iteration should be detected and a ConcurrentModificationException thrown. (Previously, the iterator would get confused, perhaps silently.) * Util/Collections/ReverseIterator.java, Util/Collections/SnapshotIterator.java, gj-files: As per Patrick's advice, create a 'SnapshotIterator' class which can be used when we want to mutate a collection underneath an iterator without the iterator noticing. So the old: Quad[] ql = (Quad[]) hc.getElements(); for (int i=0; i it=new SnapshotIterator(hc.getElementsI()); it.hasNext(); ) it.next().accept(visitor); Note that this transformation is *not* safe without the construction of the SnapshotIterator, as the iterator returned by hc.getElementsI() will get *very* confused if your visitor starts modifying elements underneath it. The next commit will make the iterator "fail-fast" (see http://java.sun.com/docs/books/tutorial/collections/implementations/general.html ) so that bugs of this sort are detected. Also modified ReverseIterator so that it extends SnapshotIterator and does not duplicate code. * IR/Bytecode/Code.java: Remove unnecessary definitions of getElements() and getElementsE(); use the superclass's implementation instead (which also has better javadoc). * Util/ArrayIterator.java, Util/Default.java, Util/EnumerationIterator.java, Util/FilterIterator.java, Support/gjlib.jar: Missed a few changes necessary for the Util->Util.Collections move; packages in harpoon.Util which used the moved classes now need import statements. Committed a Support/gjlib.jar which contains the updates. * Util/Collections/BinaryHeap.java, Util/Collections/BinomialHeap.java, Util/Collections/DisjointSet.java, Util/Collections/FibonacciHeap.java, Util/Collections/PersistentMap.java, Util/Collections/PersistentSet.java, IR/Tree/Code.java, IR/Tree/ExpList.java, IR/Quads/Code.java, IR/Quads/HANDLER.java, IR/Quads/HandlerSet.java, IR/Quads/Translate.java, IR/Properties/CFGrapher.java, IR/Assem/Code.java, IR/Assem/Instr.java, IR/Assem/InstrLABEL.java, Backend/StrongARM/AccelRFInfo.java, Backend/Analysis/ClassFieldMap.java, Backend/PreciseC/TreeToC.java, Analysis/Quads/ArrayUnroller.java, Analysis/Instr/LocalCffRegAlloc.java, Analysis/Instr/RegAlloc.java, Analysis/Instr/AppelRegAlloc.java, Analysis/Instr/AppelRegAllocClasses.java, Analysis/GraphColoring/AbstractGraph.java, Analysis/GraphColoring/SparseGraph.java, Analysis/DataFlow/CachingLiveTemps.java, Analysis/DataFlow/LiveTemps.java, Analysis/DataFlow/SpaceHeavyLiveTemps.java, IR/Bytecode/Liveness.java, ClassFile/Loader.java, Analysis/BasicBlock.java, Analysis/CycleEq.java, Analysis/EdgesIterator.java, Analysis/FCFGBasicBlock.java, Analysis/SESE.java, gj-files: Necessary code updates to reflect the move of ReverseIterator, ReverseListIterator, UnmodifiableIterator and UnmodifiableListIterator to the harpoon.Util.Collections package. Also updates the entries in gj-files. Support/gjlib.jar should be updated as well, but I'm going to do a single update later to account for several changes I'm about to check in. * Util/Collections/ReverseIterator.java, Util/Collections/ReverseListIterator.java, Util/Collections/UnmodifiableIterator.java, Util/Collections/UnmodifiableListIterator.java, Util/ReverseIterator.java, Util/ReverseListIterator.java, Util/UnmodifiableIterator.java, Util/UnmodifiableListIterator.java: Moved ReverseIterator, ReverseListIterator, UnmodifiableIterator, and UnmodifiableListIterator to harpoon.Collections.Util package (from harpoon.Util package). @RENAME: Util Util/Collections@ 2002-08-14 wbeebee * Analysis/Realtime/CheckAdder.java, Analysis/Realtime/ClassReplacer.java, Analysis/Realtime/QuantaChecker.java, Analysis/Realtime/ThreadToRealtimeThread.java: Reduced deprecation. Fixed ThreadToRealtimeThread/ClassReplacer -> they now actually replace Threads with RealtimeThreads. I would have found this bug earlier had we had a regression tester... * Analysis/Quads/QuadCounter.java: Updated to reduce deprecation. 2002-08-12 wbeebee * Analysis/Realtime/init-safe.properties: RTJ currently works only with Sun JDK. This will change when Classpath comes... * Analysis/Realtime/RealtimeRuntime.java, Analysis/Realtime/init-safe.properties, Analysis/Realtime/thread-method.properties: Eliminated PriorityScheduler-specific things from rootset. INCREF and DECREF should be init-safe (since RefCountArea.instance(), which is necessary to call them, satisfies all of the dependencies). Also, a bug fix in RealtimeRuntime, thanks to Scott - RTJ should now build referring to sunjdk.*.properties rather than the old *.properties. 2002-08-08 C. Scott Ananian * Main/EDMain.java, Main/EDXMain.java, Main/EventDriven.java, Main/JMain.java, Main/ODPAMain.java, Main/Options.java, Main/PAMain.java, Main/SAMain.java, Main/Sizer.java, Backend/Runtime1/Runtime.java, Analysis/MemOpt/TestMemOpt.java: Removed deprecated static runtimeCallableMethods() method from harpoon.Backend.Runtime1.Runtime for good; now all of its old users need to acquire a handle on a Frame object. Made these changes where needed. In the process, restructured co-dependent SAMain/PAMain so that the frame object is created earlier and there is a single place where backend names are parsed into the appropriate Frame objects. Added frameFromString() method to harpoon.Main.Options. 2002-08-08 wbeebee * Backend/Runtime1/Runtime.java: Nothing like maintaining deprecated code! 2002-08-08 C. Scott Ananian * Support/gjlib.jar: Updated Support/gjlib.jar to account for recent changes to Backend/Runtime1/Runtime.java (added classpath support, moved sun jdk properties files). 2002-08-07 salcianu * Main/PAMain.java: 1. Reverting last change performed on PAMain: > Fixed an obvious (?) one-character typo in Alex's PAMain code. > Alex, if you're reading this, can you verify that this is correct? One should not trust obvious things :) USE_OLD_STYLE was mainly a debug hack to allow me to play with the analysis without the code duplication introduced by the new static initializer policy. If USE_OLD_STYLE is false, it means that the new static initializer transf. has already been applied to the HCodeFactory that the analysis saw. Therefore, it is not necessary to have SAMain do it again. Two years ago, "SAMain.USE_OLD_CLINIT_STRATEGY = true" achieved this but we should probably have a more elegant NEW_CLINIT_ALREADY_DONE option in SAMain. 2. If one wants to analyze an application for which the old static initializer policy fails, then USE_OLD_STYLE must be set to "false". Therefore it's better to have "USE_OLD_STYLE = false" by default (and modify it only when debugging). Done. Anyway, PAMain prints precise messages about the static initializer policy that it uses. 2002-08-07 C. Scott Ananian * Main/PAMain.java: Update PAMain to account for the great properties file renaming. Alex should really be getting this from Runtime.resourcePath(...). 2002-08-07 andoni * Main/PAMain.java: Fixed an obvious (?) one-character typo in Alex's PAMain code. Alex, if you're reading this, can you verify that this is correct? 2002-08-06 C. Scott Ananian * Backend/Runtime1/Runtime.java: Configuration checking: make sure that we don't accidentally compile against sun's jdk and then try to link against gnu classpath, or vice-versa. Of course, you'll get a *ton* of link errors if you try this, but hopefully the 'check_with_classpath_needed' or 'check_with_sunjdk_needed' error will help resolve confusion. * Util/ParseUtil.java: Better feedback if parsing a properties file fails: we now tell you the filename, as well as the line number (not always obvious!). * bin/run-java, Backend/Runtime1/Runtime.java: The other shoe drops: changes to the build environment to allow run-java to use the GNU classpath libraries and Runtime1 to use the sunjdk-prefixed properties files. * Backend/Runtime1/class-root.properties, Backend/Runtime1/field-root.properties, Backend/Runtime1/init-safe.properties, Backend/Runtime1/method-root.properties, Backend/Runtime1/mzf-unsafe.properties, Backend/Runtime1/sunjdk.class-root.properties, Backend/Runtime1/sunjdk.field-root.properties, Backend/Runtime1/sunjdk.init-safe.properties, Backend/Runtime1/sunjdk.method-root.properties, Backend/Runtime1/sunjdk.mzf-unsafe.properties, Backend/Runtime1/sunjdk.transact-safe.properties, Backend/Runtime1/sunjdk.writebarrier-safe.properties, Backend/Runtime1/transact-safe.properties, Backend/Runtime1/writebarrier-safe.properties: Renamed all existing properties files with a sunjdk. prefix to prepare for the coming move to GNU classpath. The GNU versions of these properties will have no prefix. @RENAME: Backend/Runtime1/ Backend/Runtime1/sunjdk.@ * Backend/Runtime1/DataStrings.java: The first glimmer of GNU classpath support. * bin/build-precisec: We should surround the value of KEEP_ARCHIVE in quotes to protect against the (usual) case where it is undefined. But, surprisingly, it seems to work anyway. That's because GNU test/bash seems to be smart enough to work around this user error: CORRECT: $ if [ -z "" ]; then echo hi; fi STILL WORKS: $ if [ -z ]; then echo hi; fi Anyway, I've fixed the problem in build-precisec, even though it's not really a (visible) problem. 2002-08-05 C. Scott Ananian * IR/Quads/Prune.java: Incorrect description (reverse pre-order is not the same as post-order). But (surprisingly?) the implementation was correct. 2002-08-02 C. Scott Ananian * Analysis/Quads/SCC/SCCAnalysis.java, Analysis/SizeOpt/BitWidthAnalysis.java: Parallel changes to SCCAnalysis and BitWidthAnalysis: our evaluation of INSTANCEOF was being a little too aggressive in determining that a test was *definitely false*. (This applies also to the COMPONENTOF and TYPESWITCH quads.) If either side of the instanceof is an *interface type*, then we can't ever say the test is definitely false (unless both sides are "exact"). This was a big thinko on my part; I clearly wasn't considering interfaces at all when I wrote this code. But Alex Andoni found that we were compiling some JacORB code incorrectly, which led me to this bug. Thanks, Alex! 2002-07-31 C. Scott Ananian * bin/build-precisec: Allow using bin/build-precisec to compile without -O9 by overriding PRECISEC_CFLAGS. But we'll complain if you do, so that you don't forget that you MUST USE -O9 FOR BENCHMARKS. Use the PRECISEC_CFLAGS option like this: PRECISEC_CFLAGS= bin/build-precisec ... or PRECISEC_CFLAGS=-g bin/build-precisec ... Here are some common options compared: PRECISEC_CFLAGS= <- small binaries, fastest compile. can't debug. PRECISEC_CFLAGS=-g <- biggest binaries, fast compile. PRECISEC_CFLAGS=-O9 <- smallest binaries, slower compile. can't debug. PRECISEC_CFLAGS=-g -O9 <- big binaries, slowest compile. Wes' idea to compile some key binaries with -O9 and without is a good one, although I'm hesitant to waste *too* many cycles on this: it seems that if a regression test starts failing, a human being can manually compile with -O0 pretty easily to see if that's the reason why. 2002-07-30 C. Scott Ananian * build: Removed ./build as it was: 1) named incorrectly. Should be something like 'build-rtj'. 2) placed incorrectly. All scripts belong in the bin/ subdirectory. 3) Uses #!/bin/bash2 as the first line; bash2 is certainly not on any debian machines, and I would guess is not on any machines except the original committer's. 4) Doesn't support additional options, such as -Dfoo=bar, which are likely to be necessary to enable various obscure flex features. (The way bin/build-precisec and friends do it isn't ideal, but it's better than nothing.) I'm giving this the benefit of the doubt and assuming it's of general use and not specific to the testing framework -- commands embedded in the regression tests have no need to be short or user-friendly, since no humans ever have to type them. I've proactively removed this as I'm about to build a new distributions of FLEX to upload to the web page for Christian Hammer, and I'm trying to avoid confusing him with a script named 'build' that it may seem to him that he should run. It can be easily recovered with cd Harpoon/Code ; cvs update -r1.1 -p build and then re-committed (if necessary) under a new name in a new location with #3 (certainly) and #4 (hopefully) fixed. 2002-07-30 salcianu * Analysis/PointerAnalysis/PointerAnalysis.java: Fix a bug and make Christian Hammer happy. I was over-zealous in saving memory: on some code path that never occured in the previous uses of the Pointer Analysis, some data was prematurely deallocated (by setting the only reference to it to be null). 2002-07-30 dumi * build: A script needed by regression testing (and, in general, a good shortcut if you don't want to write long bin/build-precisec....... commands). I hope it'll not harm anything if I commit it in Code. Will be updated soon, after I figure out how to make scripts from repository do the same things as the scripts that I have only on my machine 2002-07-26 C. Scott Ananian * Backend/PreciseC/TreeToC.java: Karen's quick fix that makes our (precise-c) output 100% repeatable. 2002-07-26 wbeebee * Analysis/Realtime/realtime-method.properties: Revert! Revert! 2002-07-26 C. Scott Ananian * Backend/PreciseC/TreeToC.java: Sort the list of prototypes at the start of the c file so that output is repeatable across runs. Originally I just wrapped a TreeSet around sym2decl.values(), but this slowed the output routine down -- there are a lot of symbols and it had to allocate a tree node for each. In the version I'm committing here I've converted the set to a String[] to do the sorting, to keep things fast. I don't have any empirical evidence to prove that the speed difference matters. But I did it just the same. =) 2002-07-26 wbeebee * Analysis/Realtime/realtime-method.properties: Forgot a root for RTJ TCK. 2002-07-26 C. Scott Ananian * Util/HClassUtil.java: HClass.commonParent() was missing a case: merging two primitive arrays is *possible*: int[] and float[] yield Object; float[][] and double[][] yield Object[], etc. Alex Andoni found this bug, which showed up when compiling the class harpoon.Runtime.ArrayCopy. 2002-07-23 C. Scott Ananian * Support/gjlib.jar: Fix the build-from-scratch problems. Y'all can remove your .ignore files now. 2002-07-22 C. Scott Ananian * Analysis/Quads/SCC/SCCAnalysis.java, Analysis/SizeOpt/BitWidthAnalysis.java: Bug fix in SCC analysis/optimization. SCCAnalysis (and its parallel, SizeOpt.BitWidthAnalysis) was not properly accounting for flips in the sign bit caused by overflow. For example, if you take an integer with range 0-255 and cast it to a byte, the new range is *not* 0-127, because the "overflow" bit 8 flips the sign. The new range should be -128-127. This was a systemic oversight in the analysis; I didn't account for sign flips during adds/multiplies/etc either. DIV/REM are still unaccounted for; I'm not sure if sign flips can happen during overflow on division-type operations. Alex Andoni found this bug in the optimized version of java.text.Utility.RLEStringToByteArray(). Thanks, Alex! 2002-07-18 kkz * Backend/Runtime1/TreeBuilder.java, Analysis/PreciseGC/DynamicWBInserter.java, Analysis/PreciseGC/DynamicWBTreePass.java, Analysis/PreciseGC/PointsToQuadVisitor.java: New files for dynamic write barrier support. Added to Backend/Runtime1/TreeBuilder method for generating tree form for directly clearing next to low bit of hashcode field. 2002-07-18 C. Scott Ananian * Analysis/Quads/DeadCode.java: Fix bug in DeadCode where removed useless quads were being re-added to the worklist and revisited (because they used temps and thus were mentioned in the useMap). Revisiting a deleted CJMP was causing us to die horribly trying to remove a non-existent edge to a PHI. Alex Andoni found this bug; much obliged. We now use an InvertibleMultiMap for the useMap and remove all entries in useMap corresponding to deleted quads at the time the quad is removed. InvertibleMultiMaps can be very very handy sometimes. 2002-07-18 wbeebee * Analysis/Realtime/thread-method.properties: Scheduler.getDefaultScheduler() should be used for initialization, not PriorityScheduler.getScheduler() - to conform to the new spec. 2002-07-17 wbeebee * Analysis/Realtime/rtjperf-method.properties: I would ideally like to eliminate all dependencies on java.util.Date, since that includes the locale-root-set, which takes forever to compile and sometimes runs out of stack space - but it looks like the spec for javax.realtime.AbsoluteTime has methods that return a java.util.Date - so anything that touches AbsoluteTime is going to need locale-root-set. 2002-07-16 C. Scott Ananian * IR/Quads/Quad.java: Removed explicit recursion from copyone(), because Sun's jvm crashes if the stack gets too deep. * IR/Quads/Prune.java: Sharply reduce the amount of stack space required by IR/Quads/Prune: instead of needing a frame for every quad in the method (which runs out of stack space for Very Large methods), we now need frames sufficient for the # of quads in the largest basic block. This will (hopefully) keep us from running out of stack space when compiling realtime-java code to which Wes has added all manner of checks. 2002-07-16 wbeebee * Analysis/Realtime/RealtimeAllocationStrategy.java: Remember that SEGMENT.STRING_CONSTANTS are for string objects to be interned only - SEGMENT.TEXT is more appropriate for char* like strings. It seems to me that this bug bit me before, the day my MEng thesis was due - debugged once again with the help of that famous cananian 2002-07-16 C. Scott Ananian * Analysis/Transformation/MethodSplitter.java: Karen discovered that MethodSplitter rather doesn't like it if you ask convert() for a split version of a method before you've asked for the original version. This small patch should fix matters. * Support/gjlib.jar: Committing updated gjlib.jar. Not sure it's necessary, but RealtimeRuntime changed and it's better safe than sorry. 2002-07-15 wbeebee * Analysis/Realtime/RealtimeRuntime.java, Analysis/Realtime/init-safe.properties, Support/realtime.jar: RTJPerf contains an init-safe native method call. (no initCheck required) 2002-07-12 C. Scott Ananian * Tools/Annotation/Lex/Lexer.java, Tools/Annotation/Java12.cup: Import java 1.5 grammar and extend our source annotation tool so that we can annotate java 1.4+GJ sources. An updated srcdoc will be on the FLEX web site in the morning. [Use wdiff to verify the parallel to the java 1.5 grammar distributed with CUP.] 2002-07-11 C. Scott Ananian * Tools/Annotation/Lex/FIFO.java: Use standard JDK1.4 'assert' statement instead of home-spun ASSERT() method in FIFO class imported with java 1.5 lexer. * bin/cvsblame.pl: Fix infinite loop in cvsblame.pl script when tag mentioned in commit message is not actually present in the file. * Tools/Annotation/Lex/FIFO.java, Tools/Annotation/Lex/Lexer.java, Tools/Annotation/Java12.cup: Update source-annotation lexer to latest Java 1.5 lexer distributed with CUP. [Note that parser still handles Java 1.4 only.] * GNUmakefile: Old linux kernels (2.2.x?) had trouble with the very long command-lines which our new faster 'make java' rule was giving to /bin/sh. Work around this by testing whether there are any files to rebuild using only the *first word* of the out-of-date files list, instead of using the whole list. [Karen found this bug.] Also added ##out-of-date## to the 'make clean' rule. This file is generated as a side-effect of 'make java' and may stick around if you abort a compile. * .cvsignore: Added a few new entries to .cvsignore to account for recent changes in the top-level makefile. Also .cvsignore'd tmp-root-set, which build-spec-foo generates. * Main/SAMain.java: Temporarily turn off JumpOptimization. It has a bug but I can't get the assertion to fail anymore. demo.grid.Server from the JacORB 1.3.30 distribution compiles to an infinite loop with JumpOptimization enabled, however. [identifying why seems to be an interesting case of the halting problem, although soluble in practice.] * Analysis/AbstractClassFixupRelinker.java, Support/gjlib.jar: Alex Andoni found a bug in AbstractClassFixupRelinker: interfaces *can* have non-interface methods; namely, they can have static initializers. Handle this case properly in AbstractClassFixupRelinker now (and check in an updated gjlib.jar for bootstrapping). 2002-07-10 C. Scott Ananian * Support/gjlib.jar: Updated Support/gjlib.jar with recent AbstractClassFixupRelinker changes. * Analysis/AbstractClassFixupRelinker.java: Add a missing GJ type to remove an 'unchecked operation' warning. * Analysis/AbstractClassFixupRelinker.java: Fix a buglet with the 'fix superclass first' recursion. * IR/Quads/Translate.java: Document a bug in IR/Quads/Translate, and add a pair of asserts to catch it. I was working on a fix for this, and then I lost the test case. So email me if you ever see these assertions fail, so that I can fix this bug properly! 2002-07-08 C. Scott Ananian * Main/SAMain.java: Turn on use of AbstractClassFixupRelinker. This relinker adds abstract method declarations in abstract classes which javac v1.4 fails to include. * Analysis/AbstractClassFixupRelinker.java, ClassFile/Linker.java, gj-files, Support/gjlib.jar: Added a Relinker subclass which automatically fixes up abstract classes so that they always define abstract methods for all the interface methods they implement. Newer versions of Sun's javac compiler don't do this anymore, but FLEX depends on it. 2002-07-07 C. Scott Ananian * GNUmakefile: dumi found a bug with my .ignore dependency. oops. the makefile didn't work if you didn't have a .ignore file. now it should work properly. 2002-07-06 wbeebee * Analysis/Realtime/rtjperf-method.properties, Support/realtime.jar: Updated properties for RTJPerf. * Analysis/Realtime/rtjperf-method.properties: Added roots for RTJPerf 2002-07-05 C. Scott Ananian * GNUmakefile: Makefile improvements: make sure files modified between start of compile and end of compile still get marked as 'out-of-date' for the next compile. [Slight race condition still, but should be much narrower than before.] Also do the right thing if .ignore changes. 2002-07-05 wbeebee * Support/realtime.jar, Analysis/Realtime/Realtime.java, Analysis/Realtime/rtjperf-method.properties: RTJPerf clock now requires extra roots! * Analysis/Realtime/thread-method.properties: Corrected method used by RTJ Thread support 2002-07-01 C. Scott Ananian * bin/run-java: realtime.jar is not (usually) present in Support/ anymore. Special-casing this one file is not the best way to do this, but after talking to Wes seems the most practical at the moment. 2002-07-01 wbeebee * Support/.cvsignore, Support/realtime.jar: Use make in the Realtime directory to generate a realtime.jar file. 2002-06-27 wbeebee * Analysis/Realtime/realtime-method.properties: Fixed rootset. * Support/realtime.jar, Main/SAMain.java, Analysis/Realtime/HeapCheckAdder.java, Analysis/Realtime/QuantaChecker.java, Analysis/Realtime/Realtime.java, Analysis/Realtime/realtime-class.properties, Analysis/Realtime/realtime-method.properties, Analysis/Realtime/stats-method.properties, Analysis/Realtime/thread-method.properties, GNUmakefile: Fixed HeapCheckAdder and QuantaChecker so that they can take CanonicalTreeCode and spit out CanonicalTreeCode. Turned off Realtime-Threads by default, can be enabled with _threads option after the -t for RTJ. Updated the RTJ rootset adder to be properties-aware. Now, roots for RTJ are listed in the appropriate properties file rather than being hard-coded in Java. * Analysis/Realtime/Realtime.java: Fixed pretty print of options for RTJ. * Support/realtime.jar, Analysis/Realtime/Realtime.java, Backend/PreciseC/Frame.java: Fixed rootset. Eliminated fake_scopes option because it was primarily there to support legacy Benchmarks which have since been fixed. Punting legacy code to simplify life. 2002-06-25 C. Scott Ananian * Backend/PreciseC/TreeToC.java: Revert cata's changes, which are complete bogus. If you notice, he adds a "\n" to a string right before a call to nl(), which adds a newline. (Lots of other "\n"s added, too.) However, he had EMIT_LINE_DIRECTIVES=true, so he was actually *asking* FLEX to make every effort to keep everything on one line so that the Java and C line numbers match up. @REVERT: 1.5 TreeToC.java@ 2002-06-25 dumi * Support/realtime.jar, Backend/PreciseC/TreeToC.java, Analysis/Realtime/QuantaChecker.java, Analysis/Realtime/Realtime.java: Commit of Cata's stuff from months of uncommited code. If things break, revert to the version before this one. 2002-06-25 kkz * Analysis/PreciseGC/WriteBarrierQuadPass.java, Runtime/PreciseGC/WriteBarrier.java: Factored out generic write barrier functionality from WriteBarrierQuadPass. Added dynamic write barrier support to WriteBarrier. * Analysis/PreciseGC/DynamicWBQuadPass.java, Analysis/PreciseGC/MRAFactory.java, Analysis/PreciseGC/WriteBarrierConstElim.java, Analysis/PreciseGC/WriteBarrierData.java, Analysis/PreciseGC/WriteBarrierInserter.java, Analysis/PreciseGC/WriteBarrierStats.java, Analysis/PreciseGC/WriteBarrierTreePass.java, Main/SAMain.java: Added DynamicWBQuadPass. Also factored out various generic write barrier functionality from MRAFactory and WriteBarrierQuadPass, and addedWriteBarrierInserter pass. * Backend/Runtime1/TreeBuilder.java, Analysis/PointerAnalysis/MyAP.java, Analysis/EventDriven/CloningVisitor.java, Analysis/Maps/AllocationInformation.java, Analysis/AllocationInformationMap.java, Analysis/DefaultAllocationInformation.java: Added property to AllocationInformation to support dynamic write barriers. 2002-06-25 wbeebee * Main/SAMain.java: A wbOptLevel of 0 indicates no write barrier support - which is whatt a multi-threaded program should have. 2002-06-18 C. Scott Ananian * Analysis/Quads/QuadClassHierarchy.java: Slightly improve QuadClassHierarchy's handling for Class, Field, and Method constants. The real trick would be to handle the Constructor.newInstance() and Method.invoke() calls intelligently, though, and we don't do that. * Support/jacorb-root-set: Use this root set to compile CORBA applications using JacORB 1.3.30. This has been tested on the JacORB demo.grid.Client, but should work for servers (including the JacORB nameserver) as well. 2002-06-11 C. Scott Ananian * Analysis/Transformation/MethodSplitter.java: Fix a bug with the InitializerTransformer's splitting of Object[].clone() methods. Basically, A[].clone() wouldn't get split because Object[].clone() is marked final, and the ClassHierarchy says that A[] is a child of Object[]. But in *real* java semantics, the superclass of A[] is *Object* and Object.clone() is not final, thus A[].clone() should be split. There may be a deeper bug here, and I'm sure this inheritance boondoggle is going to bite someone else, eventually. But this commit fixes the bug for now. * GNUmakefile: Speed up compile times by only rebuilding source files which have changed since the last compilation. Deleting the file 'out-of-date' will force everything to be rebuilt. Also, if you type 'make' when *nothing* seems to be out-of-date, we'll rebuild everything, just to be sure. Let me know if this makefile change behaves as you expect or if you find files which for some reason or another are not being properly rebuilt or are always rebuilt or some such. With this change to the makefile, build times drop (for me) from 52s user time to under 9s (i.e > 5x speedup). If you're not using JDK1.4 already, you might consider grabbing that, too, as the javac in 1.4 is pretty fast. Hope this makes your compiling experiences happier! 2002-06-10 C. Scott Ananian * Support/gjlib.jar, GNUmakefile: Add 'gj-files' to distributed harpoon.tgz; update Support/gjlib.jar. * GNUmakefile: Add precompiled Support/gjlib.jar to the source tgz bundle, as this is necessary for building FLEX w/o the Sun gj compiler. * Analysis/MemOpt/IncompatibilityAnalysis.java: Fix ovy's erroneous calls to getField(boolean) so that FLEX will compile again. * Backend/Runtime1/init-safe.properties: Added some missing init-safe methods; these were added during the process of making JacORB clients compile correctly. * Analysis/EventDriven/AsyncCode.java, Analysis/EventDriven/CloningVisitor.java, Analysis/EnvBuilder/EnvBuilder.java: Remove bogus 'import harpoon.ClassFile.Relinker' statements, which are not needed at all. I'm just cleaning up dependencies here to make it easier to see what code really uses Relinker capabilities. 2002-06-08 C. Scott Ananian * Support/locale-root-set: java.text.resources.DateFormatZoneData_en_US, like java.text.resources.LocaleElements_en_US, is requested but not present in JDK1.1. So it *shouldn't* be mentioned in the locale-root-set. This is just a note for future hackers who might notice the Class.forName() call requesting these two classes. * bin/run-java: Add the classpath implementation of the java.math package to the default FLEX classpath. * GNUmakefile: Update JDKDOCLINK to jdk 1.4 (from jdk 1.2). 2002-06-06 C. Scott Ananian * Analysis/Tree/AlgebraicSimplification.java: (Finally) address a long-standing oversight: we now simplify certain unary operations on a constant, so that -(-100) is simplified to (100); similarly for the ~ operator and int-to-{byte,char,short} conversions. * Analysis/Tree/JumpOptimization.java: Fix an over-zealous assertion in the JumpOptimization code. * Backend/PreciseC/TreeToC.java: Bug-fix: negating a negative number was creating code like "--100" which was interpreted by the C lexer as a syntax error (pre-decrement of an integer constant). Simply fixed by adding a space after the negation operator to yield "- -100" in such cases --- then the lexer will no longer combine the two tokens into the pre/post decrement operator. 2002-06-05 C. Scott Ananian * Support/cpmath.jar: GNU classpath's pure-java version of the java.math package. Compiled from CVS grabbed at 10:54pm EST 2002-06-05. Java sources are included in the .jar. 2002-06-05 ovy * Main/MemOptMain.java: Changed to reflect small API change in IncompatibilityAnalysis. * Analysis/MemOpt/IADriver.java, Analysis/MemOpt/IncompatibilityAnalysis.java: Separated sample main method, added comments, code cleanups. 2002-05-11 salcianu * Analysis/MemOpt/Util.java: a little bit more debug/stat code 2002-05-11 ovy * Analysis/MemOpt/Util.java: Fixed null pointer exception due to native methods. 2002-05-11 salcianu * Analysis/MemOpt/Util.java: bug fix 2002-05-10 salcianu * Analysis/MemOpt/Util.java: reverting the last change ... * Analysis/MemOpt/Util.java, gj-files: Slight modification to Analysis.MemOpt.Util. * Analysis/MemOpt/Util.java: Finishing some stuff for Ovy. * Analysis/PointerAnalysis/Stats.java, Analysis/MemOpt/Util.java: New file: Analysis.MemOpt.Util containts some stuff to help Ovy. * Analysis/PointerAnalysis/Stats.java: Small_change 2002-05-02 salcianu * GNUmakefile: Added one command to recompile just one class. Really useful now that the addition of GJ increased the compilation time A LOT. Don't use it if you changed class interfaces. Should be removed when the makefile will be smart enough to recompile only the necessary things. * Analysis/MemOpt/IncompatibilityAnalysis.java: Small changes. * Analysis/Realtime/CheesyPACheckRemoval.java, Analysis/Realtime/PACheckRemoval.java: Modified two classes to use the new constructor for MetaCallGraphImpl * Main/EDMain.java, Main/EDXMain.java, Main/EventDriven.java, Main/MemOptMain.java, Main/ODPAMain.java, Main/PAMain.java, Main/SAMain.java, Analysis/MetaMethods/GenType.java, Analysis/MetaMethods/MetaCallGraphAbstr.java, Analysis/MetaMethods/MetaCallGraphImpl.java, Analysis/MetaMethods/SmartCallGraph.java: 1. Modified the constructors for meta / smart call graphs: they now require a linker (in addition to their former parameters). All classes that called this constructors have been modified too. 2. Found and fixed a (quite important) bug in MetaCallGraphAbstr.java It's funny that it never occured in practice before! Isn't this amazing? Maybe someone up there really cares about me :) 3. Added some code top the meta call graph to keep track of the things that are put in collections and maps. This allows us to trim the call graph a bit. More can be done but I think the real solution is to have a real Data Polymorphic CPA-like call graph construction. 2002-05-01 kkz * GNUmakefile: Scott fixed evil bug in makefile relating to shell meta characters in .ignore file. 2002-04-25 ovy * Analysis/MemOpt/IncompatibilityAnalysis.java: Debugging code for JLex experiment. 2002-04-24 ovy * Util/BinHeapPriorityQueue.java, Analysis/MemOpt/IncompatibilityAnalysis.java: Fixed stupid bug in BinHeap PQ. IA cleanups. 2002-04-24 salcianu * ClassFile/CachingCodeFactory.java, Main/MemOptMain.java: As promised, CachingCodeFactory has been reverted to its previous behavior. * Main/MemOptMain.java, Main/SAMain.java, Analysis/MemOpt/IncompatibilityAnalysis.java, Analysis/MemOpt/MyGraphColorer.java, ClassFile/CachingCodeFactory.java: CachingCodeFactory has been slightly modified. It seems to me that when we call ccf.put(m, hcode), we don't want to clean all the underlying code factories (especially because usually the code factory used by a CachingCodeFactory is non-caching). I will create a new class that implements this behavior in shot time (<2 hours). For the time being, I simply commented out one instruction from CachingCodeFactory.put. Plenty of changes. * IR/Quads/QuadSSI.java: fix an evil bug! 2002-04-23 salcianu * Runtime/CounterSupport.java, Main/MemOptMain.java, Main/SAMain.java, Analysis/MemOpt/IncompatibilityAnalysis.java, Analysis/PointerAnalysis/AllocationNumbering.java, Analysis/PointerAnalysis/InstrumentAllocs.java: new file: MemOptMain - main file for the MemOpt project (will be merged into SAMain when it becomes mature enough) small modifications in several other files 2002-04-23 ovy * Analysis/MemOpt/IncompatibilityAnalysis.java: Added some methods to support Alex's instrumental analysis. Ovy * Analysis/MemOpt/IncompatibilityAnalysis.java, Analysis/MemOpt/MultiMapUtils.java, Analysis/MemOpt/MyGraphColorer.java, Analysis/MemOpt/SSILiveness.java: Added my MemOpt code. This is under heavy construction, so if youre not Alex, do not use. More comments and readability improvements will come after around May 10, when my thesis is due. Ovy * IR/Quads/QuadSSI.java: Made QuadSSI do the following if a static flag is set: -- keep the quadMap from SSI rename -- do not execute dead code optimization, which changes quads without keeping a mapping around. This is a short term hack which enables me to map quads from nossa to ssi. Not sure what the long term solution is, though (change DeadCode to keep mappings?) The flag is not set by default, so existing code should work fine. Ovy * Util/BinHeapPriorityQueue.java, Util/MaxPriorityQueue.java: New implementation for BinHeapPriorityQueue, supporting all binary heap operations fast (plus, it's not on crack). Extended MaxPriorityQueue to reflect the new operations. Will add comments to BinHeapPriorityQueue soon. Ovy 2002-04-21 salcianu * Analysis/PointerAnalysis/InterProcPA.java, Analysis/MetaMethods/MetaCallGraphImpl.java: Bug fix: I hope MetaCallGraphImpl supports now the SSx (x \in {A,I}) forms 2002-04-20 salcianu * Analysis/MetaMethods/MetaCallGraphImpl.java: Tentative bug fix to MetaCallGraphImpl.java 2002-04-17 salcianu * Main/PAMain.java, Analysis/MetaMethods/MetaCallGraphImpl.java, Analysis/MetaMethods/SmartCallGraph.java: MetaCallGraphImpl (and SmartCallGraph too) should now work with QuadSSA/SSI (in addition to QuadNoSSA). They seem to work correctly. 2002-04-12 salcianu * Main/PAMain.java: Eliminated lots of unused code. * Analysis/MetaMethods/SmartCallGraph.java: Adding a convenient constructor. * Analysis/Quads/AbstrCallGraph.java, Analysis/Quads/CallGraphImpl.java: small changes 2002-04-12 C. Scott Ananian * GNUmakefile: Fixup GNUmakefile to use tar-over-ssh instead of scp for the install links, which minimizes the number of times one has to enter a password and also works around current scp breakage on lm. Also updated the 'backup' target so that it works no matter where you are and doesn't chew up (unavailable) disk space on lm. Finally, fixes the 'doc' target to actually work -- well for magic-3-1 sources, that is. Javadoc doesn't handle parameterized types yet. Removed obsolete 'oldfirst' and 'olderfirst' target. 2002-04-11 salcianu * Analysis/Quads/SSICallGraph.java, Analysis/MemOpt/ComputeAnAe.java, Analysis/MemOpt/TestMemOpt.java, Analysis/Quads/CallGraphImpl.java: Various changes. * gj-files: Some of the classes I modified use GJ. * Util/Util.java, IR/Quads/Code.java: At Scott's suggestion, I removed seelctQuads and selectCALLs from harpoon.Util.Util. An improved version of them has been placed in harpoon.IR.Quads.Code (which is indeed more appropriate). Now, you can select all the quads with a given property from a code. Here are two applications: selectCALLs - good in some call graph implementations selectAllocations - get all the [A]NEWs from a method (Karen might find this useful). 2002-04-11 C. Scott Ananian * GNUmakefile, Support/gjlib.jar: Build correctly from scratch. Also rebuild gjlib.jar to purge some locally-modified versions of class files from it. 2002-04-11 salcianu * Analysis/Quads/AbstrCallGraph.java, Analysis/Quads/CachingCallGraph.java, Analysis/Quads/CallGraph.java, Analysis/Quads/CallGraphImpl.java, Analysis/Quads/SSICallGraph.java: 1. added abstract class ABstrCallGraph to store some common code for SSICallGraph and CallGraphImpl 2. small changes in the other files 2002-04-11 C. Scott Ananian * Tools/Annotation/Lex/Keyword.java, Tools/Annotation/Lex/Lexer.java, Tools/Annotation/Java12.cup, Tools/Annotation/Main.java: Update the annotation tool to Java 1.4 (this means we now recognize the 'assert' statement). Also sync'ed it somewhat with the latest release of the CUP JavaGrammar package. The annotation tool doesn't yet work with parameterized types; that should be the next update. * IR/Quads/ASET.java, IR/Quads/CALL.java, IR/Quads/CJMP.java, IR/Quads/COMPONENTOF.java, IR/Quads/CONST.java, IR/Quads/DEBUG.java, IR/Quads/FOOTER.java, IR/Quads/GET.java, IR/Quads/HANDLER.java, IR/Quads/HEADER.java, IR/Quads/INSTANCEOF.java, IR/Quads/LABEL.java, IR/Quads/METHOD.java, IR/Quads/MONITORENTER.java, IR/Quads/MONITOREXIT.java, IR/Quads/MOVE.java, IR/Quads/NEW.java, IR/Quads/NOP.java, IR/Quads/OPER.java, IR/Quads/PHI.java, IR/Quads/Quad.java, IR/Quads/QuadValueVisitor.java, IR/Quads/RETURN.java, IR/Quads/SET.java, IR/Quads/SIGMA.java, IR/Quads/SWITCH.java, IR/Quads/THROW.java, IR/Quads/TYPECAST.java, IR/Quads/TYPESWITCH.java, IR/Quads/XI.java, IR/LowQuad/LowQuad.java, IR/LowQuad/LowQuadValueVisitor.java, IR/LowQuad/PAOFFSET.java, IR/LowQuad/PARRAY.java, IR/LowQuad/PFCONST.java, IR/LowQuad/PFIELD.java, IR/LowQuad/PFOFFSET.java, IR/LowQuad/PGET.java, IR/LowQuad/PMCONST.java, IR/LowQuad/PMETHOD.java, IR/LowQuad/PMOFFSET.java, IR/LowQuad/PSET.java, IR/Quads/AGET.java, IR/Quads/ALENGTH.java, IR/Quads/ANEW.java, IR/Quads/ARRAYINIT.java, Support/gjlib.jar: Add new QuadValueVisitor and LowQuadValueVisitor which use the magic of parameterized types to allow you to return a value from a visitor. For those of you not using GJ, just pretend the return type is 'Object' and it will work. Updated gj-files to add the ValueVisitors; also updated the bootstrap Support/gjlib.jar file. 2002-04-10 C. Scott Ananian * gj-files: Add new QuadValueVisitor and LowQuadValueVisitor which use the magic of parameterized types to allow you to return a value from a visitor. For those of you not using GJ, just pretend the return type is 'Object' and it will work. Updated gj-files to add the ValueVisitors; also updated the bootstrap Support/gjlib.jar file. * Util/Util.java, Analysis/Quads/SSICallGraph.java: Reverted the addition of some unnecessary methods to harpoon.Util.Util: I'm trying to keep the public API of FLEX as small as possible. Util is full of too much stuff as it is; it's hard enough for people to find what they're looking for. Adding more methods willy-nilly doesn't help this. If I had time, I'd go through and eliminate all the getElements()/getElementsE()/getElementsI() redundancies in FLEX, too, but unfortunately I don't. At the moment, at least. Rewrote some code in Analysis/Quads/SSICallGraph.java to show how this functionality should be achieved. Left in selectQuads and selectCALLs for now; I'm trusting that Alex will find a more appropriate place for them as soon as he's finished merging to CVS HEAD. But *please* don't use the obsolete Hashtable and Vector classes in public APIs! They have been superceded by the Map and List classes; use these instead. Since harpoon.Util.Util is compiled by GJ, I took the opportunity to add proper parameterized types to these methods, which also serves the purpose of better documenting the API. (Vector of *what*? List of *what*?) 2002-04-10 salcianu * Analysis/Quads/SSICallGraph.java: SSICallGraph implements harpoon.Analysis.Quads.CallGraph for SSI code. It is basically a wrapper around CallGraphImpl2 to hide the different calling format for CallGraphImpl2.calls(cs, rd, etm). To avoid creating ReachingDefs and ExactTypeMap multiple times, when we call it for the first time with a call site from a method hm, we analyze all the call sites from that method and cache the results. Has caching for both calls(hm) and calls(hm, cs); This way one can use the power of CallGraphImpl2 in a regular harpoon.Analysis.Quads.CallGraph (CallGraphImpl2 itself implements just harpoon.Analysis.CallGraph). * Util/Util.java: New method: convert(obj, map) returns the image of obj through map (if any) or obj (unmodified) otherwise. 2002-04-09 C. Scott Ananian * bin/migrate-assert.perl, bin/run-java, Util/TypeInference/TypeInference.java, Util/LightBasicBlocks/LightBasicBlock.java, Util/Collections/AbstractHeap.java, Util/Collections/AbstractMapEntry.java, Util/Collections/AggregateMapFactory.java, Util/Collections/AggregateSetFactory.java, Util/Collections/BinaryHeap.java, Util/Collections/BinaryTree.java, Util/Collections/BinomialHeap.java, Util/Collections/BitSetFactory.java, Util/Collections/CollectionFactory.java, Util/Collections/CollectionWrapper.java, Util/Collections/DisjointSet.java, Util/Collections/Environment.java, Util/Collections/Factories.java, Util/Collections/FibonacciHeap.java, Util/Collections/GenericInvertibleMap.java, Util/Collections/GenericInvertibleMultiMap.java, Util/Collections/GenericMultiMap.java, Util/Collections/HashEnvironment.java, Util/Collections/Heap.java, Util/Collections/IntervalTree.java, Util/Collections/InvertibleMap.java, Util/Collections/InvertibleMultiMap.java, Util/Collections/LinearMap.java, Util/Collections/LinearSet.java, Util/Collections/ListFactory.java, Util/Collections/ListWrapper.java, Util/Collections/MapFactory.java, Util/Collections/MapSet.java, Util/Collections/MapWrapper.java, Util/Collections/MultiMap.java, Util/Collections/MultiMapFactory.java, Util/Collections/MultiMapSet.java, Util/Collections/PairMapEntry.java, Util/Collections/PersistentEnvironment.java, Util/Collections/PersistentMap.java, Util/Collections/PersistentSet.java, Util/Collections/PersistentTreeNode.java, Util/Collections/RedBlackTree.java, Util/Collections/SetFactory.java, Util/Collections/SetWrapper.java, Util/Collections/UniqueStack.java, Util/Collections/UniqueVector.java, Util/Collections/UnmodifiableMultiMap.java, Util/Collections/WorkSet.java, Util/ArrayEnumerator.java, Util/ArrayFactory.java, Util/ArrayIterator.java, Util/ArraySet.java, Util/BinHeapPriorityQueue.java, Util/BinaryRelation.java, Util/BitString.java, Util/CloneableIterator.java, Util/CombineEnumerator.java, Util/CombineIterator.java, Util/Default.java, Util/EnumerationIterator.java, Util/FilterEnumerator.java, Util/FilterIterator.java, Util/Grapher.java, Util/HClassUtil.java, Util/Indexer.java, Util/IteratorEnumerator.java, Util/NullEnumerator.java, Util/ReverseEnumerator.java, Util/ReverseIterator.java, Util/ReverseListIterator.java, Util/SingletonEnumerator.java, Util/Timer.java, Util/UnmodifiableIterator.java, Util/UnmodifiableListIterator.java, Util/Util.java, Util/Worklist.java, Tools/PatMat/CodeGeneratorGenerator.java, Tools/PatMat/MaximalMunchCGG.java, Tools/PatMat/Spec.java, Tools/Annotation/Java12.cup, Temp/CloningTempMap.java, Temp/Temp.java, Runtime/MZFExternalMap.java, Support/gjlib.jar, Interpret/Tree/Method.java, Interpret/Tree/ObjectRef.java, Interpret/Tree/OffsetMap32.java, Interpret/Tree/Ref.java, Interpret/Tree/StaticState.java, Main/EDMain.java, Main/EDXMain.java, Main/Javap.java, Main/Javap2.java, Main/ODPAMain.java, Main/PAMain.java, Main/SAMain.java, Interpret/Quads/ArrayRef.java, Interpret/Quads/INClass.java, Interpret/Quads/InterpretedThrowable.java, Interpret/Quads/Method.java, Interpret/Quads/ObjectRef.java, Interpret/Quads/Ref.java, Interpret/Quads/StaticState.java, Interpret/Tree/ArrayRef.java, Interpret/Tree/ClazPointer.java, Interpret/Tree/DefaultFrame.java, Interpret/Tree/InterpreterOffsetMap.java, IR/Tree/CONST.java, IR/Tree/CanonicalTreeCode.java, IR/Tree/Code.java, IR/Tree/DATUM.java, IR/Tree/Data.java, IR/Tree/DerivationGenerator.java, IR/Tree/ESEQ.java, IR/Tree/EXPR.java, IR/Tree/INVOCATION.java, IR/Tree/JUMP.java, IR/Tree/LABEL.java, IR/Tree/MEM.java, IR/Tree/METHOD.java, IR/Tree/MOVE.java, IR/Tree/NAME.java, IR/Tree/NATIVECALL.java, IR/Tree/OPER.java, IR/Tree/OptimizedTreeCode.java, IR/Tree/Print.java, IR/Tree/RETURN.java, IR/Tree/SEGMENT.java, IR/Tree/SEQ.java, IR/Tree/Stm.java, IR/Tree/TEMP.java, IR/Tree/THROW.java, IR/Tree/ToCanonicalTree.java, IR/Tree/ToTree.java, IR/Tree/ToTreeHelpers.java, IR/Tree/Translation.java, IR/Tree/Tree.java, IR/Tree/TreeCode.java, IR/Tree/TreeGrapher.java, IR/Tree/TreeUseDefer.java, IR/Tree/TreeVerifyingVisitor.java, IR/Tree/UNOP.java, IR/RawClass/AccessFlags.java, IR/RawClass/Attribute.java, IR/RawClass/AttributeSignature.java, IR/Tree/ALIGN.java, IR/Tree/BINOP.java, IR/Tree/CALL.java, IR/Tree/CJUMP.java, IR/Quads/Translate.java, IR/Quads/UnHandler.java, IR/Quads/XI.java, IR/Quads/AGET.java, IR/Quads/ALENGTH.java, IR/Quads/ANEW.java, IR/Quads/ARRAYINIT.java, IR/Quads/ASET.java, IR/Quads/CALL.java, IR/Quads/CJMP.java, IR/Quads/COMPONENTOF.java, IR/Quads/CONST.java, IR/Quads/CloneSynthesizer.java, IR/Quads/Code.java, IR/Quads/DEBUG.java, IR/Quads/Edge.java, IR/Quads/GET.java, IR/Quads/HANDLER.java, IR/Quads/HandlerSet.java, IR/Quads/INSTANCEOF.java, IR/Quads/METHOD.java, IR/Quads/MONITORENTER.java, IR/Quads/MONITOREXIT.java, IR/Quads/MOVE.java, IR/Quads/NEW.java, IR/Quads/OPER.java, IR/Quads/PHI.java, IR/Quads/Pattern.java, IR/Quads/Peephole.java, IR/Quads/Print.java, IR/Quads/Prune.java, IR/Quads/Quad.java, IR/Quads/ReHandler.java, IR/Quads/SET.java, IR/Quads/SIGMA.java, IR/Quads/SSIRename.java, IR/Quads/SSIToSSA.java, IR/Quads/SWITCH.java, IR/Quads/THROW.java, IR/Quads/TYPECAST.java, IR/Quads/TYPESWITCH.java, IR/Quads/TempChain.java, IR/Quads/ThreadInliner.java, IR/Quads/ToNoSSA.java, IR/Properties/CFGEdge.java, IR/Properties/CFGraphable.java, IR/Properties/CFGrapher.java, IR/Properties/UseDefable.java, IR/Properties/UseDefer.java, IR/LowQuad/DerivationMap.java, IR/LowQuad/LowQuadSSI.java, IR/LowQuad/PAOFFSET.java, IR/LowQuad/PCALL.java, IR/LowQuad/PCONST.java, IR/LowQuad/PFCONST.java, IR/LowQuad/PFOFFSET.java, IR/LowQuad/PGET.java, IR/LowQuad/PMCONST.java, IR/LowQuad/PMOFFSET.java, IR/LowQuad/POPER.java, IR/LowQuad/PPTR.java, IR/LowQuad/PSET.java, IR/Jasmin/Jasmin.java, IR/Bytecode/InMerge.java, IR/Bytecode/Instr.java, IR/Bytecode/Op.java, IR/Assem/Code.java, IR/Assem/Instr.java, IR/Assem/InstrEdge.java, IR/Assem/InstrFactory.java, IR/Assem/InstrGroup.java, IR/Assem/InstrLABEL.java, IR/Assem/InstrMOVE.java, ClassFile/ClassPointer.java, ClassFile/Factories.java, ClassFile/HClass.java, ClassFile/HClassArraySyn.java, ClassFile/HClassProxy.java, ClassFile/HClassSyn.java, ClassFile/HCode.java, ClassFile/HCodeEdge.java, ClassFile/HConstructor.java, ClassFile/HConstructorSyn.java, ClassFile/HField.java, ClassFile/HFieldImpl.java, ClassFile/HFieldSyn.java, ClassFile/HInitializer.java, ClassFile/HInitializerSyn.java, ClassFile/HMember.java, ClassFile/HMemberProxy.java, ClassFile/HMethod.java, ClassFile/HMethodImpl.java, ClassFile/HMethodSyn.java, ClassFile/HPointer.java, ClassFile/ImplMagic.java, ClassFile/Linker.java, ClassFile/Loader.java, ClassFile/Relinker.java, Backend/StrongARM/Code.java, Backend/StrongARM/CodeGen.spec, Backend/StrongARM/CodeGen.spec.coarseInstrs, Backend/StrongARM/CodeGen.spec.instrGroups, Backend/StrongARM/InstrBuilder.java, Backend/StrongARM/RegFileInfo.java, Backend/StrongARM/TwoWordTemp.java, Backend/Sparc/Code.java, Backend/Sparc/CodeGen.spec, Backend/Sparc/RegFileInfo.java, Backend/Sparc/TempBuilder.java, Backend/RuntimeTiny/ClazNumbering.java, Backend/RuntimeTiny/CompleteClazNumbering.java, Backend/RuntimeTiny/DataClazTable.java, Backend/RuntimeTiny/FixUnaligned.java, Backend/RuntimeTiny/ObjectBuilder.java, Backend/RuntimeTiny/PreOrderClazNumbering.java, Backend/RuntimeTiny/Runtime.java, Backend/RuntimeTiny/TinyClassFieldMap.java, Backend/RuntimeTiny/TinyPackedClassFieldMap.java, Backend/RuntimeTiny/TreeBuilder.java, Backend/RuntimeTiny/package.html, Backend/Runtime2/Runtime.java, Backend/Runtime2/TreeBuilder.java, Backend/Runtime1/Data.java, Backend/Runtime1/DataClaz.java, Backend/Runtime1/DataGC.java, Backend/Runtime1/DataStaticFields.java, Backend/Runtime1/DataStrings.java, Backend/Runtime1/HeapStatsAllocationStrategy.java, Backend/Runtime1/NiftyAllocationStrategy.java, Backend/Runtime1/ObjectBuilder.java, Backend/Runtime1/Runtime.java, Backend/Runtime1/SPAllocationStrategy.java, Backend/Runtime1/TreeBuilder.java, Backend/PreciseC/Frame.java, Backend/PreciseC/IdentifyNoHandler.java, Backend/PreciseC/TreeToC.java, Backend/Maps/DefaultNameMap.java, Backend/Maps/FieldMap.java, Backend/MIPS/BypassLatchSchedule.java, Backend/MIPS/Code.java, Backend/MIPS/CodeGen.spec, Backend/MIPS/InstrBuilder.java, Backend/MIPS/RegFileInfo.java, Backend/MIPS/StackInfo.java, Backend/Generic/Code.java, Backend/Generic/CodeGen.java, Backend/Generic/GCInfo.java, Backend/Generic/InstrBuilder.java, Backend/Generic/MaxMunchCG.java, Backend/Generic/RegFileInfo.java, Backend/Generic/Runtime.java, Backend/CSAHack/RegAlloc/Color.java, Backend/CSAHack/RegAlloc/DerivationGenerator.java, Backend/CSAHack/RegAlloc/RegAlloc.java, Backend/Analysis/BasicGCInfo.java, Backend/Analysis/ClassFieldMap.java, Backend/Analysis/ClassMethodMap.java, Backend/Analysis/InitializerOrdering.java, Backend/Analysis/InsertWriteBarrier.java, Backend/Analysis/InterfaceMethodMap.java, Backend/Analysis/MakeGCThreadSafe.java, Backend/Analysis/PackedClassFieldMap.java, Backend/Analysis/SortedClassFieldMap.java, Backend/CSAHack/FlowGraph/AssemFlowGraph.java, Analysis/TypeInference/ClassCone.java, Analysis/TypeInference/IntraProc.java, Analysis/Tree/AlgebraicSimplification.java, Analysis/Tree/AlignmentAnalysis.java, Analysis/Tree/CacheEquivalence.java, Analysis/Tree/ConstantPropagation.java, Analysis/Tree/DeadCodeElimination.java, Analysis/Tree/DominatingMemoryAccess.java, Analysis/Tree/JumpOptimization.java, Analysis/Tree/MemHoisting.java, Analysis/Tree/Simplification.java, Analysis/Tree/TreeFolding.java, Analysis/Transformation/MethodMutator.java, Analysis/Transformation/MethodSplitter.java, Analysis/Transactions/AnalysisCheckOracle.java, Analysis/Transactions/ArrayCopyImplementer.java, Analysis/Transactions/BitFieldNumbering.java, Analysis/Transactions/CheckOracle.java, Analysis/Transactions/CloneImplementer.java, Analysis/Transactions/DominatingCheckOracle.java, Analysis/Transactions/SimpleCheckOracle.java, Analysis/Transactions/SyncTransformer.java, Analysis/Transactions/TreePostPass.java, Analysis/SizeOpt/BitWidthAnalysis.java, Analysis/SizeOpt/ConstructorClassifier.java, Analysis/SizeOpt/Field2Method.java, Analysis/SizeOpt/FieldReducer.java, Analysis/SizeOpt/MZFChooser.java, Analysis/SizeOpt/MZFCompressor.java, Analysis/SizeOpt/MZFExternalize.java, Analysis/SizeOpt/MZFWidenType.java, Analysis/SizeOpt/MostlyZeroFinder.java, Analysis/RoleInference/LocalVariableNamer.java, Analysis/Quads/SCC/SCCAnalysis.java, Analysis/Quads/SCC/SCCOptimize.java, Analysis/Realtime/CheckAdder.java, Analysis/Realtime/CheckAdderNoSSA.java, Analysis/Realtime/CheckAdderWithTry.java, Analysis/Realtime/CheesyPACheckRemoval.java, Analysis/Realtime/ClassReplacer.java, Analysis/Realtime/PACheckRemoval.java, Analysis/Realtime/QuantaChecker.java, Analysis/Realtime/Realtime.java, Analysis/Realtime/RealtimeRuntime.java, Analysis/Realtime/Stats.java, Analysis/Realtime/ThreadToRealtimeThread.java, Analysis/PreciseGC/AllocationHoisting.java, Analysis/PreciseGC/MRAFactory.java, Analysis/PreciseGC/RCTransformer.java, Analysis/PreciseGC/WriteBarrierConstElim.java, Analysis/PreciseGC/WriteBarrierData.java, Analysis/PreciseGC/WriteBarrierPostPass.java, Analysis/PreciseGC/WriteBarrierQuadPass.java, Analysis/PreciseGC/WriteBarrierStats.java, Analysis/PreciseGC/WriteBarrierTreePass.java, Analysis/Quads/ArrayUnroller.java, Analysis/Quads/CallGraphImpl.java, Analysis/Quads/CallGraphImpl2.java, Analysis/Quads/CoalescingToNoSSA.java, Analysis/Quads/DeadCode.java, Analysis/Quads/DefiniteInitOracle.java, Analysis/Quads/DispatchTreeTransformation.java, Analysis/Quads/InitializerTransform.java, Analysis/Quads/MayReadOracle.java, Analysis/Quads/MemoryOptimization.java, Analysis/Quads/MethodInliningCodeFactory.java, Analysis/Quads/MustParamOracle.java, Analysis/Quads/NewMover.java, Analysis/Quads/QuadClassHierarchy.java, Analysis/Quads/QuadInterferenceGraph.java, Analysis/Quads/QuadLiveness.java, Analysis/Quads/SimpleConstMap.java, Analysis/Quads/TypeInfo.java, Analysis/Quads/TypeSwitchRemover.java, Analysis/Quads/Unreachable.java, Analysis/PointerAnalysis/ActionRepository.java, Analysis/PointerAnalysis/ArtificialTempFactory.java, Analysis/PointerAnalysis/EdgesNCallees.java, Analysis/PointerAnalysis/InstrumentSyncOps.java, Analysis/PointerAnalysis/InterProcPA.java, Analysis/PointerAnalysis/InterThreadPA.java, Analysis/PointerAnalysis/LightPAEdgeSet.java, Analysis/PointerAnalysis/MAInfo.java, Analysis/PointerAnalysis/MethodHole.java, Analysis/PointerAnalysis/NodeRepository.java, Analysis/PointerAnalysis/ODInformation.java, Analysis/PointerAnalysis/ODInterProcPA.java, Analysis/PointerAnalysis/ODMAInfo.java, Analysis/PointerAnalysis/ODParIntGraph.java, Analysis/PointerAnalysis/ODPointerAnalysis.java, Analysis/PointerAnalysis/PANode.java, Analysis/PointerAnalysis/PAThreadMap.java, Analysis/PointerAnalysis/ParIntGraph.java, Analysis/PointerAnalysis/PointerAnalysis.java, Analysis/PointerAnalysis/PointsToGraph.java, Analysis/Partition/Profile.java-old, Analysis/MetaMethods/GenType.java, Analysis/MetaMethods/MetaAllCallers.java, Analysis/MetaMethods/MetaCallGraphImpl.java, Analysis/MetaMethods/MetaMethod.java, Analysis/MemOpt/ComputeAnAe.java, Analysis/MemOpt/TestMemOpt.java, Analysis/Maps/Derivation.java, Analysis/Maps/UseDefMap.java, Analysis/LowQuad/Loop/AllInductions.java, Analysis/LowQuad/Loop/BasicInductions.java, Analysis/LowQuad/Loop/Induction.java, Analysis/LowQuad/Loop/LoopAnalysis.java, Analysis/LowQuad/Loop/LoopOptimize.java, Analysis/LowQuad/Loop/MyLowQuadNoSSA.java, Analysis/LowQuad/Loop/MyLowQuadSSI.java, Analysis/GraphColoring/OptimisticGraphColorer.java, Analysis/GraphColoring/SparseGraph.java, Analysis/Instr/AppelRegAlloc.java, Analysis/Instr/AppelRegAllocClasses.java, Analysis/Instr/AppelRegAllocFsk.java, Analysis/Instr/AppelRegAllocStd.java, Analysis/Instr/Check.java, Analysis/Instr/EqTempSets.java, Analysis/Instr/GraphColoringRegAlloc.java, Analysis/Instr/LocalCffRegAlloc.java, Analysis/Instr/RegAlloc.java, Analysis/Instr/RegFile.java, Analysis/Instr/SpillHeuristics.java, Analysis/Instr/Verify.java, Analysis/Instr/Web.java, Analysis/EventDriven/AsyncCode.java, Analysis/EventDriven/CloningVisitor.java, Analysis/DataFlow/ReversePostOrderEnumerator.java, Analysis/DataFlow/ReversePostOrderIterator.java, Analysis/DataFlow/SpaceHeavyLiveTemps.java, Analysis/DataFlow/TreeSolver.java, Analysis/EnvBuilder/EnvBuilder.java, Analysis/Counters/EpilogMutator.java, Analysis/Counters/RuntimeMethodCloner.java, Analysis/DataFlow/DataFlowBasicBlockVisitor.java, Analysis/DataFlow/LiveTemps.java, Analysis/Counters/CounterFactory.java, Analysis/AllocationInformationMap.java, Analysis/BasicBlock.java, Analysis/BasicBlockFactoryInterf.java, Analysis/BasicBlockInterf.java, Analysis/ClassHierarchy.java, Analysis/CycleEq.java, Analysis/DefaultAllocationInformation.java, Analysis/DomTree.java, Analysis/FCFGBasicBlock.java, Analysis/InterferenceGraph.java, Analysis/Liveness.java, Analysis/PointsToAnalysis.java, Analysis/ReachingDefs.java, Analysis/ReachingDefsAltImpl.java, Analysis/ReachingDefsCachingImpl.java, Analysis/ReachingDefsImpl.java, Analysis/SESE.java, Analysis/SSxReachingDefsImpl.java, Analysis/UseDef.java, GNUmakefile, gj-files: Merge java-1-5 branch with FLEX head. @MERGE: java-1-5@ This means we're now using Java 1.4-style asserts uniformly throughout FLEX and that we're GJ-enabled. You *will* need a Java 1.4-compatible compiler (and runtime?) but you *won't* necessarily need a GJ-compiler to build FLEX. Briefly, asserts are now of the form: assert : "optional description message or object"; instead of Util.ASSERT(expression, "optional description message or object"); And most of the foundation classes now have gj types; you can use them or not. If you decide to go GJ in your class, you will need to add its filename to Harpoon/Code/gj-files and install the 1.2 prototype GJ compiler. More details are at: http://www.flex-compiler.lcs.mit.edu/Harpoon/jsr14.txt I've auto-converted asserts in all currently-checked-in code; if you've got a substantial amount of uncommitted code that you'd like converted, email me and I'll send you the convert script. * Support/CUP.jar: Having source files in the .jar seems to confuse javac. Moving the source files to a separate SRC/ directory path inside the jar seems to fix things. * Support/gjlib.jar: Whoops; last version checked in was built from modified harpoon.ClassFile.* sources. This version should be clean. * IR/Tree/Print.java: Make the PrintCallback passed to IR/Tree/Print be a PrintCallback. * Main/Javap.java, Main/Javap2.java: Add two implementations of javap-like functionality using our classfile infrastructure. harpoon.Main.Javap uses the low-level harpoon.IR.RawClass.ClassFile code, and fully support GJ signatures; harpoon.Main.Javap2 uses the higher-level harpoon.ClassFile.HClass code, and (as a consequence) doesn't (yet) emits only the 'erased' types of GJ classes. Both should work fine on non-GJ classes. * Main/Javap.java, Main/Javap2.java: New file. * Support/gjlib.jar: Improve GNUmakefile to support building even w/o GJ compiler (using pre-built Support/gjlib.jar binaries). * Support/gjlib.jar: New file. * GNUmakefile: Improve GNUmakefile to support building even w/o GJ compiler (using pre-built Support/gjlib.jar binaries). * Util/Collections/BinomialHeap.java: Workaround recursive inference bug in javac, not that we know exactly what is it. * Analysis/Instr/RegAlloc.java, Analysis/Instr/RegFile.java: Remove unnecessary 'import harpoon.Util.Collections.LinearMap' statements, since neither of these classes actually use LinearMap. Nothing does, really. * Util/Collections/DisjointSet.java, Util/Collections/Environment.java, Util/Collections/HashEnvironment.java, Util/Collections/LinearMap.java, Util/Collections/PersistentEnvironment.java, Util/Collections/PersistentMap.java, Util/Collections/PersistentSet.java, Util/Collections/PersistentTreeNode.java, gj-files: GJ-ize DisjointSet, LinearMap, Environment (and all subclasses) and PersistentTreeNode (and all classes which use it). PersistentTreeNode isolated a bug in the prototype 1.2 GJ compiler; look for 'XXX BUG IN JAVAC' to find it. The workaround code should be reverted when the bug is fixed. 2002-04-07 C. Scott Ananian * Analysis/SizeOpt/ConstructorClassifier.java: Add comment informed by writing up OOPSLA paper on this analysis. * GNUmakefile, gj-files: Add newly-GJ-ized files to the gj-files list. Makefile improvements: add gj-files as a dependency of the 'java' target. Use the $JSR14DISTR environment variable to define the path to JCC5. Add '-gj' to the JCC5 command-line, as it is needed for the 1.2 prototype compiler. * Analysis/Quads/QuadInterferenceGraph.java: GJ-ize QuadInterferenceGraph so that it conforms to the GJ-ized InterferenceGraph class. * Util/Collections/CollectionWrapper.java, Util/Collections/GenericInvertibleMap.java, Util/Collections/GenericInvertibleMultiMap.java, Util/Collections/GenericMultiMap.java, Util/Collections/LinearSet.java, Util/Collections/ListWrapper.java, Util/Collections/MapWrapper.java, Util/Collections/MultiMap.java, Util/Collections/UnmodifiableMultiMap.java, Util/Collections/WorkSet.java, Util/Default.java: Keep up with GJ prototype 1.2 changes: new signature for addAll, putAll, etc and constructors are covariant. harpoon.Util.Default has new unmodifiableCollection() method which doesn't yet work properly due to a bug in the GJ compiler; we've worked around the bug by adding an extra parameter to help the type inference engine. We also rejiggered the type signature of the Default.pair() method to allow pair elements of differing types so that we don't break as much existing code. We also narrowed the type of MultiMap.entrySet() to require a MultiMapSet as the return value. * Analysis/Instr/RegAlloc.java: GJ-ize return type of defC() so that the InstrMEM subclass within RegAlloc conforms to the GJ-ized UseDefable interface. * Util/Collections/UniqueStack.java, Util/Collections/UniqueVector.java: GJ-ize the UniqueStack and UniqueVector collections classes. * Main/EDMain.java, Main/EDXMain.java, Main/SAMain.java, IR/Assem/Code.java, IR/Assem/Instr.java, IR/Assem/InstrEdge.java, IR/Assem/InstrFactory.java, IR/Assem/InstrGroup.java, IR/Assem/InstrLABEL.java: GJ-ize the base harpoon.IR.Assem Instr IR classes. I think all the IRs are now GJ-ized. * Util/Collections/Factories.java: Update the harpoon.Util.Collections.Factories class to reflect the new covariance of the CollectionFactory classes. Also removed some now-unnecessary workarounds for 1.0 prototype GJ compiler bugs. * Util/Collections/AggregateMapFactory.java: Newly GJ-ize the harpoon.Util.Collections.AggregateMapFactory. * Util/Util.java: GJ-ize the Util.set_diff() method. * ClassFile/HCode.java: Tiny tweak to add the proper parameterized type to a nop PrintCallback instantiation. * Analysis/Transactions/AnalysisCheckOracle.java, Analysis/Transactions/DominatingCheckOracle.java, Analysis/Transactions/SimpleCheckOracle.java: Use more-specific return type for CheckSet.clone(). Newly GJ-ize DominatingCheckOracle and SimpleCheckOracle. * Analysis/Liveness.java, Analysis/Quads/QuadLiveness.java: GJ-ize the harpoon.Analysis.Liveness class and all subclasses. * Util/Collections/AbstractHeap.java, Util/Collections/BinaryHeap.java, Util/Collections/BinomialHeap.java, Util/Collections/FibonacciHeap.java, Util/Collections/Heap.java: GJ-ize the Heap classes in harpoon.Util.Collections. * Util/Collections/AggregateSetFactory.java, Util/Collections/BitSetFactory.java, Util/Collections/CollectionFactory.java, Util/Collections/ListFactory.java, Util/Collections/MapFactory.java, Util/Collections/MultiMapFactory.java, Util/Collections/SetFactory.java: Allow co-variance in the CollectionFactory classes; that is, we can create a Collection from a Collection of objects of a more restricted type. Also removes some workarounds needed for compiling with the 1.0 prototype GJ compiler---these are no longer neede with the 1.2 prototype. * Util/Collections/InvertibleMultiMap.java, Util/UnmodifiableListIterator.java, IR/Properties/CFGEdge.java, IR/Tree/TreeUseDefer.java, Analysis/BasicBlock.java, Analysis/ReachingDefsAltImpl.java, Analysis/ReachingDefsCachingImpl.java, Analysis/ReachingDefsImpl.java, Analysis/SSxReachingDefsImpl.java: Removed workarounds for bugs in the 1.0 prototype GJ compiler that are made unnecessary by the 1.2 prototype GJ compiler. 2002-04-03 salcianu * Analysis/Quads/CachingCallGraph.java, Analysis/MemOpt/ComputeAnAe.java, Analysis/MemOpt/TestMemOpt.java: 1. new class: CachingCallGraph.java is caching wrapper for CallGraph's (harpoon.Analysis.Quads.CallGraph has caching just for calls(hm), in some situations, it's good to cache calls(hm, cs) too). 2. minor changes here and there 2002-04-02 salcianu * Analysis/MemOpt/TestMemOpt.java: TestMemOpt.java is a simple class to allow Ovidiu and I to play with classes from the MemOpt package. When the project will grow more mature. We'll have a real top level class in harpoon.Main. * Analysis/MemOpt/ComputeAnAe.java: 1. new package harpoon.Analysis.MemOpt for the memory optimization for embedded system (the projected EMSOFT submission). Idea: detect a minimal number of sets of allocation sites that can share the same memory space (because no two objects allocated at sites from the same set can be live at the same time). 2. small class that computes some internal variables that Ovidiu and I require for the incompatibility detection: detecting the pairs of allocation sites that cannot share the same state. For each analyzable method m, ComputeAnAe computes: an(m) = allocation sites that may be encountered on a path that starts at the beginning of m and ends on its normal exit (the exit for RETURN). We consider transitive callees. ae(m) = same as an(m) but now we are interested in paths that end on the exceptional exit of m (the exit for unhandled THROW instructions) This computation is an easy application of the inclusion constraint solver harpoon.Util.Constraints.InclusionConstraints. * Util/Graph.java, Util/Util.java, Analysis/Quads/CallGraphImpl.java, Main/PAMain.java: Small changes. * Analysis/BasicBlockInterfVisitor.java: The visitor pattern in action, once again :) This way, one can process BasicBlock's and FCFGBasicBlock's (and future implems of BasicBlockInterf) without instanceof's. * Analysis/Tree/TreeFolding.java: Some method take a BasicBlockInterf arg now (more general that the previous BasicBlock arg). Shouldn't cause any difference. * Analysis/PreciseGC/WriteBarrierQuadPass.java: WorkSet has moved from harpoon.Util to harpoon.Util.Collections Fix the WriteBarrierQuadPass.java to reflect this. * Analysis/PointerAnalysis/ParIntGraph.java, Analysis/PointerAnalysis/PointerAnalysis.java: Minor changes in the pa code. * Analysis/Instr/RegAlloc.java: Replacing BasicBlock with BasicBlockInterf. Shouldn't cause any problem. * Analysis/DataFlow/BackwardDataFlowBasicBlockVisitor.java, Analysis/DataFlow/DataFlowBasicBlockVisitor.java, Analysis/DataFlow/ForwardDataFlowBasicBlockVisitor.java, Analysis/DataFlow/InstrSolver.java, Analysis/DataFlow/LiveVars.java, Analysis/DataFlow/ReachingDefs.java, Analysis/DataFlow/ReachingHCodeElements.java: Minor changes: some methods now take BasicBlockInterf's instead of just BasicBlock's. Shouldn't interfere with anything else. 2002-03-27 kkz * Main/SAMain.java, Backend/Runtime1/writebarrier-safe.properties, Analysis/PreciseGC/MRAFactory.java, Analysis/PreciseGC/RCTransformer.java, Analysis/PreciseGC/WriteBarrierQuadPass.java: Many changes to RC transformation, plus some experimental code for write barrier removal. Also added new compiler options to SAMain for different flavors of write barrier removal. 2002-03-27 C. Scott Ananian * Util/Collections/IntervalTree.java: Bug fix from Kim Roland Rasmussen ; including felix's email as well as rasmussen's in this commit message, because no one seems to be sure if this was actually a bug or not. On the assumption that it is, I'm committing it. If you're using this code and you notice something weird going on, you might want to have a hard look at this (and possibly revert it?). * IR/RawClass/Attribute.java, IR/RawClass/AttributeSignature.java: Add support for GJ 'Signature' attribute on classes/methods/fields. The HClass infrastructure doesn't do anything with this attribute yet, but we parse it at least. * IR/RawClass/AttributeSignature.java: New file. * IR/RawClass/AccessFlags.java: Add RawClass support for 'strictfp' modifier, introduced in Java 1.2. 2002-03-21 C. Scott Ananian * Backend/RuntimeTiny/Runtime.java: Fix formatting of pretty-print 'options' status output. * Backend/PreciseC/Frame.java, Backend/Runtime1/HeapStatsAllocationStrategy.java: Add new 'heapstats' allocation strategy, which interfaces with the --with-live-heap-statistics option of the Runtime to emit maximum live heap statistics for both object and array allocations separately. * Backend/Runtime1/HeapStatsAllocationStrategy.java: New file. * GNUmakefile: Clean up ChangeLog output by removing CVSROOT prefix on every file. 2002-03-20 C. Scott Ananian * Backend/RuntimeTiny/ObjectBuilder.java, Backend/RuntimeTiny/Runtime.java, Backend/RuntimeTiny/TinyPackedClassFieldMap.java, Backend/RuntimeTiny/TreeBuilder.java, Backend/Runtime1/Runtime.java: Add hashcode compression support to RuntineTiny. Note that the array length field is still forced to a word boundary at this point; I'll fix this at some point in the future. There are issues with Object[].length when the component pointers still need to be word-aligned. * Backend/Runtime1/TreeBuilder.java: Remove some 'final' modifiers to allow a subclass more leeway to move things around. * Backend/Runtime1/ObjectBuilder.java: Refactoring Runtime1/ObjectBuilder to better accomodate oddly-sized and shaped object headers. Also, allow the ClassFieldMap to position the length field, in preparation for (perhaps) variably-sized length fields. NOTE that the TreeBuilder uses its own idea of the ALENGTH offset (doesn't consult the ClassFieldMap) so this will have to be fixed if the ClassFieldMap ever decides to put the length in a funky place. * Backend/RuntimeTiny/TinyPackedClassFieldMap.java: The java '%' operator behaves strangely on negative numbers. Replace the fancy 'alignment' computation with a simple one which will be correct w/ negative offsets. * Runtime/MZFExternalMap.java: Fix documentation error: the named parameters appear in the wrong order here when compared to the implementation in Runtime/src/mzf and the use in Code/Analysis/SizeOpt/MZFExternalize. 2002-03-19 C. Scott Ananian * Analysis/SizeOpt/MZFWidenType.java: It's important to widen *all* methods (not just callable ones) to keep the system sane. Methods implement interfaces and extend superclasses, and the interface and superclass methods must be altered in the same way the method is if these relationships are to remain fixed. The easiest way to ensure that is to alter *all* methods in the same way. * Analysis/Quads/QuadClassHierarchy.java, Main/SAMain.java: Add mechanism to add an *instantiated* array class to the root set. Also add hack to SAMain that keeps String[] in the root set even when doing MZF splitting on String (which would tend to widen the type of the array). Note that RuntimeTiny requires this array to be in the *instantiated* class set so that its claz gets a low index during claz compression. * homeBackend/Runtime1/DataClaz.java: Add an assertion to DataClaz to help debugging. * Backend/RuntimeTiny/DataClazTable.java, Backend/StrongARM/Code.java, Analysis/Instr/AppelRegAlloc.java: Fix assertions with side-effects. These three were especially bad side-effects, too: they caused non-termination when assertions were disabled. 2002-03-18 C. Scott Ananian * Util/Collections/GenericInvertibleMultiMap.java, Util/Collections/GenericMultiMap.java, Util/Collections/MultiMap.java, Util/Collections/UnmodifiableMultiMap.java: BUG FIX: when I was adding typed to MultiMap to GJ-ize it, I inadvertently changed the running time of Map.entrySet().contains() from O(1) to O(N)! What happened is that I used the wrong type on the contains() method and so the method didn't override the base AbstractCollection.contains() implementation, which has an O(N) running-time. Yuck. Fixed, by making MultiMap.contains(key, value) and MultiMap.remove(key, value) both take Objects instead of exact key and value types. This is consistent w/ the interface of the other Map and Collection methods in the JDK API. However, it means that we can't make MultiMap implement BinaryRelation, because GJ doesn't support covariant subtyping of method parameters, sigh. Fixing this bug should make the BitwidthAnalysis run *much* faster. * bin/run-java: Move the '-ea' to the JAVA definition so that JAVA=jdb debugging still works. 2002-03-16 C. Scott Ananian * Analysis/DomTree.java: Workaround javac bug by ensuring that we have complete parameterized signatures for all constructors! (Otherwise we get a VerifyError at runtime, sigh.) * Backend/RuntimeTiny/TinyPackedClassFieldMap.java: New file. * Backend/RuntimeTiny/TinyPackedClassFieldMap.java, Backend/RuntimeTiny/TreeBuilder.java: New, improved, field packer. Makes better use of 'holes' left by any necessary padding. * Backend/PreciseC/Frame.java: Allow easier use of custom allocators. * Backend/RuntimeTiny/ObjectBuilder.java, Backend/RuntimeTiny/Runtime.java, Backend/RuntimeTiny/TinyClassFieldMap.java, Backend/RuntimeTiny/TreeBuilder.java, gj-files: Add support for allocating fields in the empty space left by a compressed claz pointer. 2002-03-15 C. Scott Ananian * Backend/Runtime1/ObjectBuilder.java: Refactor ObjectBuilder to eliminate duplicate code and fix a bug w/ incorrect output of classes with padding between fields. * Backend/RuntimeTiny/TinyClassFieldMap.java, Backend/RuntimeTiny/TreeBuilder.java: Added TinyClassFieldMap which more-correctly lays out fields in the sizeopt context: you can separately specified *forced* alignments (like for pointers) and *preferred* alignments (everything else). Only pads when necessary for a forced alignment. * Backend/RuntimeTiny/TinyClassFieldMap.java: New file. * Backend/Analysis/SortedClassFieldMap.java, gj-files: Added TinyClassFieldMap which more-correctly lays out fields in the sizeopt context: you can separately specified *forced* alignments (like for pointers) and *preferred* alignments (everything else). Only pads when necessary for a forced alignment. * Util/ReverseIterator.java, Util/ReverseListIterator.java: GJ-ized ReverseIterator. Added new ReverseListIterator class, which is more efficient on List's iterators. * Util/ReverseListIterator.java: New file. * gj-files: GJ-ized ReverseIterator. Added new ReverseListIterator class, which is more efficient on List's iterators. * Backend/Runtime1/ObjectBuilder.java, gj-files: GJ-ized harpoon.Backend.Runtime1.ObjectBuilder. * Backend/RuntimeTiny/FixUnaligned.java, Backend/RuntimeTiny/Runtime.java, Backend/RuntimeTiny/TreeBuilder.java: Add first-draft byte-aligned fields support. This is a pretty broken way to do things, as FixUnaligned can't deal w/ floats and generally doesn't have enough information about the fields it is dealing with. But luckily for us, x86 will transparently handle unaligned accesses (probably slowly, but still) so we don't really need to worry about this just yet. * Backend/RuntimeTiny/FixUnaligned.java: New file. * Backend/Runtime1/TreeBuilder.java, gj-files: Add first-draft byte-aligned fields support. This is a pretty broken way to do things, as FixUnaligned can't deal w/ floats and generally doesn't have enough information about the fields it is dealing with. But luckily for us, x86 will transparently handle unaligned accesses (probably slowly, but still) so we don't really need to worry about this just yet. * IR/Tree/CanonicalTreeCode.java, IR/Tree/ToCanonicalTree.java: Widened types so that you can pass a Code (doesn't have to be a TreeCode) through the canonicalization process. This is very useful if you are taking what *used* to be a canonical tree, munging it, and then attempting to re-canonicalize it, since CanonicalTreeCode extends Code but not TreeCode. * Analysis/Tree/AlignmentAnalysis.java: Made several fields and methods public so that AlignmentAnalysis is actually *useful* from outside its package. * Analysis/Tree/MemHoisting.java, Analysis/Tree/Simplification.java, gj-files: GJ-ized Analysis/Tree/Simplification and its subclass MemHoisting. * IR/Properties/CFGrapher.java, Util/UnmodifiableListIterator.java: Work around javac bugs. In the CFGrapher case, the code was valid but yielded an 'unchecked' warning; but javac massacred the code-gen resulting in a VerifyError thrown when the bytecode for the class was executed. Corrected this by fixing the decl to not generate the 'unchecked' warning. In the UnmodifiableListIterator case, this is bug in how the GJ compiler handles final methods. I've reported it to Sun and hopefully it will be fixed. In the meantime, we must mark the methods as non-final to work around the problem. 2002-03-14 C. Scott Ananian * Analysis/Tree/AlignmentAnalysis.java: New file. * Analysis/Tree/AlignmentAnalysis.java, Analysis/Tree/CacheEquivalence.java, gj-files: Split CacheEquivalence analysis in two so that I can re-use the dataflow alignment analysis from it. The split probably needs some polishing yet, but it'll do for now. Added a bit of extra GJ-goodness while I was at it. * Analysis/ReachingDefs.java, Analysis/ReachingDefsAltImpl.java, Analysis/ReachingDefsCachingImpl.java, Analysis/ReachingDefsImpl.java, Analysis/SSxReachingDefsImpl.java: GJ-ized all ReachingDefs implementations. * Analysis/BasicBlock.java, Analysis/BasicBlockFactoryInterf.java, Analysis/BasicBlockInterf.java: GJ-ified the BasicBlock/BasicBlock.Factory interfaces & implementations. * Util/Collections/BitSetFactory.java, Util/BitString.java, Util/Indexer.java: GJ-ified the BitSetFactory and the BitString and Indexer classes which it uses. 2002-03-13 C. Scott Ananian * Util/ArrayEnumerator.java, Util/Default.java, Analysis/Quads/SCC/SCCAnalysis.java, Analysis/Maps/UseDefMap.java, Analysis/DataFlow/ReversePostOrderEnumerator.java, Analysis/UseDef.java: Removed the last of the Enumeration-based classes from harpoon.Util (except for EnumerationIterator and IteratorEnumerator, needed for compatibility w/ old interfaces). * Util/Collections/WorkSet.java, Util/FilterIterator.java, Tools/PatMat/Spec.java, Temp/Temp.java, Interpret/Tree/ArrayRef.java, Interpret/Tree/ClazPointer.java, Interpret/Tree/Ref.java, Interpret/Tree/StaticState.java, Interpret/Quads/Ref.java, IR/Tree/Data.java, IR/Tree/OptimizedTreeCode.java, IR/Bytecode/Instr.java, Backend/StrongARM/CodeGen.spec, Backend/MIPS/CodeGen.spec, Analysis/PointerAnalysis/InstrumentSyncOps.java, Analysis/Tree/TreeFolding.java, Analysis/SESE.java: Remapped all the '/*final*/' declarations inserted in the hoary past of this compiler when the various java compilers had buggy final checking back to 'final'. I.e. made a lot of fields final again which we had to make unfinal ages ago to work around javac bugs. But the bugs are gone. Bring back the finals! * Util/ArrayIterator.java: Fix a javadoc typo. * Util/CombineEnumerator.java, Util/FilterEnumerator.java, Util/NullEnumerator.java, Util/ReverseEnumerator.java, Util/SingletonEnumerator.java: Remove unused *Enumerator classes. (We should all be using Iterators by now.) * Analysis/Tree/CacheEquivalence.java, Analysis/DomTree.java, gj-files: gj-ified harpoon.Analysis.DomTree (tough, this code was written a *long* time ago! made things use the 1.2 collections api while i was at it), and harpoon.Analysis.Tree.CacheEquivalence. * IR/Properties/CFGrapher.java, IR/Properties/UseDefer.java, IR/Tree/Code.java, IR/Tree/TreeCode.java, IR/Tree/TreeGrapher.java, IR/Tree/TreeUseDefer.java: GJ-ized CFGrapher and UseDefer (and subclasses). * Util/Collections/AggregateSetFactory.java, Util/FilterIterator.java: GJ-ized harpoon.Util.FilterIterator and harpoon.Util.Collections.AggregateSetFactory. Note that: 1) the jsr14 GJ spec doc has a much more elegant means of doing mapping functions, using non-static inner classes. See the 'Zipper' example in the text. We used an more inelegant approach to maintain compatibility w/ existing code. Maybe someday we'll "upgrade". 2) AggregateSetFactory is one of the places where one would wish that the types of the generated sets we're so tightly tied to the type of the Factory; i.e. it would be nice to have a generic factory that could make Sets for any V. However, the MapSetFactory (which turns MapFactorys into SetFactories that generate MapSets) would then be impossible to type-check. Ce la vi. 2002-03-11 C. Scott Ananian * Backend/RuntimeTiny/ObjectBuilder.java, Backend/RuntimeTiny/PreOrderClazNumbering.java, Backend/RuntimeTiny/Runtime.java, Backend/RuntimeTiny/TreeBuilder.java: Finished implementation of claz compression in the Code. It works on Hello, world now. I had to add an extension mechanism to harpoon.Backend.Runtime1.DataClaz to make this all work right, and provide a way to override/subclass the harpoon.Backend.Runtime1.ObjectBuilder. Next commit will make this work in the Runtime. * Backend/RuntimeTiny/ObjectBuilder.java: New file. * Backend/Runtime1/ObjectBuilder.java, Backend/Runtime1/Runtime.java, Backend/Runtime1/TreeBuilder.java, gj-files, homeBackend/Runtime1/DataClaz.java: Finished implementation of claz compression in the Code. It works on Hello, world now. I had to add an extension mechanism to harpoon.Backend.Runtime1.DataClaz to make this all work right, and provide a way to override/subclass the harpoon.Backend.Runtime1.ObjectBuilder. Next commit will make this work in the Runtime. * homeBackend/Runtime1/DataClaz.java: GJ-ify harpoon.Backend.Runtime1.DataClaz. * gj-files, Util/UnmodifiableListIterator.java, Backend/Maps/FieldMap.java, Backend/Analysis/ClassFieldMap.java, Backend/Analysis/PackedClassFieldMap.java, Backend/Analysis/SortedClassFieldMap.java: GJ-icize harpoon.Backend.Maps.FieldMap and its subclasses. Also GJ-ed harpoon.Util.UnmodifiableListIterator (needed for the above). 2002-03-10 C. Scott Ananian * Backend/RuntimeTiny/ClazNumbering.java, Backend/RuntimeTiny/CompleteClazNumbering.java, Backend/RuntimeTiny/DataClazTable.java, Backend/RuntimeTiny/PreOrderClazNumbering.java, Backend/RuntimeTiny/Runtime.java, Backend/RuntimeTiny/TreeBuilder.java, Backend/RuntimeTiny/package.html: Check in first draft of claz compression support. We don't actually resize the field yet, but we do store the index and do the dereference. The rest will come in due time. =) Note that we had to change TreeBuilder._claz_ from private to protected to allow our subclass to work properly; we also added some configuration checking to Runtime1 and Runtime2 to detect a runtime/code mismatch (it wouldn't do for one of them to compress the claz and not the other). * Backend/RuntimeTiny/ClazNumbering.java, Backend/RuntimeTiny/CompleteClazNumbering.java, Backend/RuntimeTiny/DataClazTable.java, Backend/RuntimeTiny/PreOrderClazNumbering.java, Backend/RuntimeTiny/Runtime.java, Backend/RuntimeTiny/TreeBuilder.java, Backend/RuntimeTiny/package.html: New file. * Backend/Runtime2/Runtime.java, Backend/Runtime1/Runtime.java, Backend/Runtime1/TreeBuilder.java, gj-files: Check in first draft of claz compression support. We don't actually resize the field yet, but we do store the index and do the dereference. The rest will come in due time. =) Note that we had to change TreeBuilder._claz_ from private to protected to allow our subclass to work properly; we also added some configuration checking to Runtime1 and Runtime2 to detect a runtime/code mismatch (it wouldn't do for one of them to compress the claz and not the other). * Backend/PreciseC/Frame.java: Extended the runtime selection to use reflection. This way we don't have to keep changing this code whenever we add a new runtime subclass. Kept a static reference to Runtime1 so that FLEX built w/ itself doesn't need a manual root-set specification. I'm not entirely sure I'm happy w/ the cleanness of this code, so I'm not applying the change to all the Backends' Frames yet. I'm going to let it sit for a while in the tree, and if it doesn't make me too unhappy, then I'll spread it to the rest. * Analysis/Quads/QuadClassHierarchy.java: Bug fix: we should never return interfaces in the 'instantiated classes' list. * Backend/Runtime2/Runtime.java, Backend/Runtime2/TreeBuilder.java, Backend/Runtime1/Data.java, Backend/Runtime1/Runtime.java, Analysis/Realtime/RealtimeRuntime.java, gj-files: Further GJ-ized harpoon.Backend.Runtime1.Runtime and all its subclasses. Also made _DATUM methods of Runtime1.Data protected, so that we can properly use them in subclasses. * gj-files: Updated gj-files to list all the new GJ-ized classes modified in the last few commits. * IR/Tree/Code.java, IR/Tree/Stm.java, IR/Tree/Tree.java, Backend/Runtime1/DataStrings.java, Backend/Runtime1/Runtime.java, Backend/Runtime1/TreeBuilder.java, Backend/Generic/Runtime.java: GJ-ize the Backend/Runtime interface (which required GJ-izing the harpoon.IR.Tree package as well). * Util/Collections/ListWrapper.java: GJ-ize the ListWrapper class. * Analysis/Quads/QuadClassHierarchy.java, IR/Quads/Code.java: Remove newly-unnecessary javac bug workarounds. * ClassFile/ClassPointer.java, ClassFile/Factories.java, ClassFile/HClass.java, ClassFile/HClassSyn.java, ClassFile/HConstructor.java, ClassFile/HField.java, ClassFile/HFieldImpl.java, ClassFile/HInitializer.java, ClassFile/HMember.java, ClassFile/HMemberProxy.java, ClassFile/HMethod.java, ClassFile/HMethodImpl.java, ClassFile/HPointer.java: GJ-ize all remaining files in harpoon.ClassFile package. Modulo a javac bug in ClassFile/ClassPointer.java, you can compile all classes in harpoon.ClassFile w/ the jsr14 compiler now. * bin/fm-javadoc-cmd: This script builds a javadoc .pdf using framemaker on athena. The 1.2-beta1 MIF doclet has some bugs, so this isn't quite ready for prime-time yet. * Tools/PatMat/Spec.java, Backend/Generic/RegUseDefer.java, Analysis/DataFlow/BackwardDataFlowBasicBlockVisitor.java, Analysis/DataFlow/ForwardDataFlowBasicBlockVisitor.java, Backend/CSAHack/FlowGraph/AssemFlowGraph.java: Javadoc @see tag fixes. * GNUmakefile, overview.html: Added an 'overview.html' file, which shows up in the generated javadoc. * Tools/PatMat/Spec.java: javadoc fix. 2002-03-09 C. Scott Ananian * GNUmakefile: Fix wrong *s on JDOCGROUPs options. Fix improper quoting of JDOCGROUP. Portability fixes. * Main/Raw.java, Backend/Generic/Code.java, Analysis/PointerAnalysis/EdgesNCallees.java, Analysis/PointerAnalysis/PAEdgeSet.java, Analysis/PointerAnalysis/PAEscapeFunc.java, Analysis/Instr/AppelRegAllocClasses.java, Analysis/Instr/EqTempSets.java, Analysis/FCFGBasicBlock.java: Fix typos in javadoc comments. * GNUmakefile: Some portability fixes and javadoc improvements. 2002-03-06 C. Scott Ananian * Analysis/PreciseGC/RCTransformer.java: WorkSet was moved from harpoon.Util to harpoon.Util.Collections some time ago. Karen probably has old .class files for the previous name still lying around. 2002-03-04 C. Scott Ananian * Analysis/PointsToAnalysis.java: Abstract interface for points-to analyses. * Analysis/PointsToAnalysis.java: New file. * GNUmakefile, bin/run-java, gj-files: Updated build environment to: 1) support more GJ-ed files (gj-files) 2) merge 'java5' and 'java' targets (GNUMakefile) 3) enable assertions by default (bin/run-java) * Analysis/Transactions/AnalysisCheckOracle.java, Analysis/Transactions/CheckOracle.java, Analysis/Quads/QuadClassHierarchy.java, Analysis/ClassHierarchy.java, Analysis/InterferenceGraph.java: GJ-ized some of the analyses. Makes the behavior of those interface methods that return Collections much easier to understand. * IR/Quads/Code.java, IR/Quads/Edge.java, IR/Quads/Print.java, IR/Quads/Quad.java: Bring the core Quad classes into the GJ age. Note that the separate nextEdge() and succ() methods are no longer necessary, as they return exactly the same types. (Same for prevEdge()/pred() and a few more methods.) Also, predC()/succC() should return a List instead of a Collection and then the prevEdge(i) calls could be replaced by succC().get(i). With a little tweaking to the implementatin of predC()/succC() this would have almost identical performance, while greatly reducing the size of the Quad interface. These more-aggressive GJ-izations haven't been done (yet) to preserve compatibility w/ legacy FLEX code. * Temp/Temp.java, IR/Properties/CFGEdge.java, IR/Properties/CFGraphable.java, IR/Properties/UseDefable.java, ClassFile/HCode.java, ClassFile/HCodeEdge.java: GJ-ify most of the core FLEX classes: HCode, HCodeEdge, CFGEdge, CFGraphable, UseDefable, Temp. Note that some of these could be further simplified now that GJ has given us co-variant return types, but these changes would require more changes to the 'legacy' FLEX code than I'm willing to do right now. * Util/Collections/CollectionFactory.java, Util/Collections/ListFactory.java, Util/Collections/SetFactory.java, Util/Default.java: Workaround bugs in javac which prohibit the casting of Set to Set and so forth. Revert most of this commit when these bugs are fixed. * Util/ArrayFactory.java, Util/ArrayIterator.java, Util/ArraySet.java, Util/CombineIterator.java, Util/EnumerationIterator.java, Util/Grapher.java, Util/IteratorEnumerator.java, Util/Util.java: More GJ-izing the Collections-related Util classes. Adding parameterized types where they make sense. 2002-02-28 kkz * Analysis/PreciseGC/RCTransformer.java: Transformation for recursive constructors. 2002-02-27 kkz * Analysis/PreciseGC/AllocationHoisting.java, Analysis/PreciseGC/MRAFactory.java: Minor changes to make allocation hoisting work for the olden benchmarks. 2002-02-27 C. Scott Ananian * Util/Collections/AbstractMapEntry.java, Util/Collections/CollectionFactory.java, Util/Collections/CollectionWrapper.java, Util/Collections/Factories.java, Util/Collections/GenericInvertibleMap.java, Util/Collections/GenericInvertibleMultiMap.java, Util/Collections/GenericMultiMap.java, Util/Collections/InvertibleMap.java, Util/Collections/InvertibleMultiMap.java, Util/Collections/LinearSet.java, Util/Collections/ListFactory.java, Util/Collections/MapFactory.java, Util/Collections/MapSet.java, Util/Collections/MapWrapper.java, Util/Collections/MultiMap.java, Util/Collections/MultiMapFactory.java, Util/Collections/MultiMapSet.java, Util/Collections/PairMapEntry.java, Util/Collections/SetFactory.java, Util/Collections/SetWrapper.java, Util/Collections/UnmodifiableMultiMap.java, Util/Collections/WorkSet.java: Migrated much of our harpoon.Util.Collections package to GJ. The lack of subtyping w/ parametric types (i.e. Factory being a subtype of Factory) is a real problem w/ our CollectionFactory stuff... but we'll deal. Moved MultiMap.Factory to MultiMapFactory to be consistent w/ the other *Factory classes. Added a new Default.EMPTY_MULTIMAP field. Hacked GNUmakefile to build only the classes in Harpoon/Code/gj-files using the GJ compiler, since it still has some *issues* (like insisting that java.util.Set is not a consistent subtype of java.util.Collection due to quibbles with the toArray() method). The rest of the classes are built using the standard java compiler. Yay, backwards-compatibility. Look for the XXX BUG IN JAVAC comments (in particular, in Util/Collections/Factories and Util/Collections/InvertibleMultiMap) to find the places were what I think to be perfectly OK GJ code gives the current GJ prototype compiler fits. Fix these bits when either the compiler, or my understanding of GJ, improves. * Util/Collections/MultiMapFactory.java: New file. * Util/BinaryRelation.java, Util/Default.java, Util/UnmodifiableIterator.java, Util/Worklist.java, Analysis/Instr/RegAlloc.java, GNUmakefile, gj-files: Migrated much of our harpoon.Util.Collections package to GJ. The lack of subtyping w/ parametric types (i.e. Factory being a subtype of Factory) is a real problem w/ our CollectionFactory stuff... but we'll deal. Moved MultiMap.Factory to MultiMapFactory to be consistent w/ the other *Factory classes. Added a new Default.EMPTY_MULTIMAP field. Hacked GNUmakefile to build only the classes in Harpoon/Code/gj-files using the GJ compiler, since it still has some *issues* (like insisting that java.util.Set is not a consistent subtype of java.util.Collection due to quibbles with the toArray() method). The rest of the classes are built using the standard java compiler. Yay, backwards-compatibility. Look for the XXX BUG IN JAVAC comments (in particular, in Util/Collections/Factories and Util/Collections/InvertibleMultiMap) to find the places were what I think to be perfectly OK GJ code gives the current GJ prototype compiler fits. Fix these bits when either the compiler, or my understanding of GJ, improves. * gj-files: New file. * Util/TypeInference/TypeInference.java, bin/migrate-assert.perl: Globally replace all instances of our Util.ASSERT function with the proper JDK1.4 'assert' keyword. Also check in a script, bin/migrate-assert.perl, which does *most* of these replacements for us (feed it a munged version of the source, and unmunge the output). Notably exceptions that can't be automagically done are in Tools/PatMat/MaximalMunchCGG.java. Some others, too. Hacked GNUMakefile to indicate that (current versions of) jikes will no longer compile this code. Fixed 'make java' target so that javac will. THIS COMMIT IS ONLY ON THE java-1-5 BRANCH. THE HEAD IS STILL pre-java 1.4 and jikes-compatible. * bin/migrate-assert.perl: New file. * Util/LightBasicBlocks/LightBasicBlock.java, Util/Collections/BinaryHeap.java, Util/Collections/BinaryTree.java, Util/Collections/BinomialHeap.java, Util/Collections/BitSetFactory.java, Util/Collections/DisjointSet.java, Util/Collections/Factories.java, Util/Collections/FibonacciHeap.java, Util/Collections/GenericMultiMap.java, Util/Collections/HashEnvironment.java, Util/Collections/RedBlackTree.java, Util/Collections/WorkSet.java, Util/ArrayIterator.java, Util/BinHeapPriorityQueue.java, Util/BitString.java, Util/CloneableIterator.java, Util/HClassUtil.java, Util/Timer.java, Util/Util.java, Tools/PatMat/CodeGeneratorGenerator.java, Tools/PatMat/MaximalMunchCGG.java, Tools/PatMat/Spec.java, Temp/CloningTempMap.java, Temp/Temp.java, Tools/Annotation/Java12.cup, Main/EDMain.java, Main/EDXMain.java, Main/ODPAMain.java, Main/PAMain.java, Main/SAMain.java, Interpret/Tree/InterpreterOffsetMap.java, Interpret/Tree/Method.java, Interpret/Tree/ObjectRef.java, Interpret/Tree/OffsetMap32.java, Interpret/Tree/StaticState.java, Interpret/Quads/ArrayRef.java, Interpret/Quads/INClass.java, Interpret/Quads/InterpretedThrowable.java, Interpret/Quads/Method.java, Interpret/Quads/ObjectRef.java, Interpret/Quads/StaticState.java, Interpret/Tree/ArrayRef.java, Interpret/Tree/DefaultFrame.java, IR/Tree/ALIGN.java, IR/Tree/BINOP.java, IR/Tree/CALL.java, IR/Tree/CJUMP.java, IR/Tree/CONST.java, IR/Tree/CanonicalTreeCode.java, IR/Tree/Code.java, IR/Tree/DATUM.java, IR/Tree/DerivationGenerator.java, IR/Tree/ESEQ.java, IR/Tree/EXPR.java, IR/Tree/INVOCATION.java, IR/Tree/JUMP.java, IR/Tree/LABEL.java, IR/Tree/MEM.java, IR/Tree/METHOD.java, IR/Tree/MOVE.java, IR/Tree/NAME.java, IR/Tree/NATIVECALL.java, IR/Tree/OPER.java, IR/Tree/Print.java, IR/Tree/RETURN.java, IR/Tree/SEGMENT.java, IR/Tree/SEQ.java, IR/Tree/TEMP.java, IR/Tree/THROW.java, IR/Tree/ToCanonicalTree.java, IR/Tree/ToTree.java, IR/Tree/ToTreeHelpers.java, IR/Tree/Translation.java, IR/Tree/Tree.java, IR/Tree/TreeGrapher.java, IR/Tree/TreeUseDefer.java, IR/Tree/TreeVerifyingVisitor.java, IR/Tree/UNOP.java, IR/Quads/AGET.java, IR/Quads/ALENGTH.java, IR/Quads/ANEW.java, IR/Quads/ARRAYINIT.java, IR/Quads/ASET.java, IR/Quads/CALL.java, IR/Quads/CJMP.java, IR/Quads/COMPONENTOF.java, IR/Quads/CONST.java, IR/Quads/CloneSynthesizer.java, IR/Quads/Code.java, IR/Quads/DEBUG.java, IR/Quads/Edge.java, IR/Quads/GET.java, IR/Quads/HANDLER.java, IR/Quads/HandlerSet.java, IR/Quads/INSTANCEOF.java, IR/Quads/METHOD.java, IR/Quads/MONITORENTER.java, IR/Quads/MONITOREXIT.java, IR/Quads/MOVE.java, IR/Quads/NEW.java, IR/Quads/OPER.java, IR/Quads/PHI.java, IR/Quads/Pattern.java, IR/Quads/Peephole.java, IR/Quads/Print.java, IR/Quads/Prune.java, IR/Quads/Quad.java, IR/Quads/ReHandler.java, IR/Quads/SET.java, IR/Quads/SIGMA.java, IR/Quads/SSIRename.java, IR/Quads/SSIToSSA.java, IR/Quads/SWITCH.java, IR/Quads/THROW.java, IR/Quads/TYPECAST.java, IR/Quads/TYPESWITCH.java, IR/Quads/TempChain.java, IR/Quads/ThreadInliner.java, IR/Quads/ToNoSSA.java, IR/Quads/Translate.java, IR/Quads/UnHandler.java, IR/Quads/XI.java, IR/LowQuad/DerivationMap.java, IR/LowQuad/LowQuadSSI.java, IR/LowQuad/PAOFFSET.java, IR/LowQuad/PCALL.java, IR/LowQuad/PCONST.java, IR/LowQuad/PFCONST.java, IR/LowQuad/PFOFFSET.java, IR/LowQuad/PGET.java, IR/LowQuad/PMCONST.java, IR/LowQuad/PMOFFSET.java, IR/LowQuad/POPER.java, IR/LowQuad/PPTR.java, IR/LowQuad/PSET.java, IR/Jasmin/Jasmin.java, IR/Bytecode/InMerge.java, IR/Bytecode/Op.java, IR/Assem/Code.java, IR/Assem/Instr.java, IR/Assem/InstrGroup.java, IR/Assem/InstrMOVE.java, ClassFile/HClassArraySyn.java, ClassFile/HClassProxy.java, ClassFile/HClassSyn.java, ClassFile/HConstructorSyn.java, ClassFile/HFieldSyn.java, ClassFile/HInitializerSyn.java, ClassFile/HMemberProxy.java, ClassFile/HMethodSyn.java, ClassFile/ImplMagic.java, ClassFile/Linker.java, ClassFile/Loader.java, ClassFile/Relinker.java, Backend/StrongARM/CodeGen.spec.coarseInstrs, Backend/StrongARM/CodeGen.spec.instrGroups, Backend/StrongARM/InstrBuilder.java, Backend/StrongARM/RegFileInfo.java, Backend/StrongARM/TwoWordTemp.java, ClassFile/ClassPointer.java, ClassFile/HClass.java, Backend/StrongARM/Code.java, Backend/StrongARM/CodeGen.spec, Backend/Sparc/Code.java, Backend/Sparc/CodeGen.spec, Backend/Sparc/RegFileInfo.java, Backend/Sparc/TempBuilder.java, Backend/Runtime1/DataGC.java, Backend/Runtime1/DataStaticFields.java, Backend/Runtime1/NiftyAllocationStrategy.java, Backend/Runtime1/ObjectBuilder.java, Backend/Runtime1/Runtime.java, Backend/Runtime1/SPAllocationStrategy.java, Backend/Runtime1/TreeBuilder.java, homeBackend/Runtime1/DataClaz.java, Backend/PreciseC/Frame.java, Backend/PreciseC/IdentifyNoHandler.java, Backend/PreciseC/TreeToC.java, Backend/MIPS/InstrBuilder.java, Backend/MIPS/RegFileInfo.java, Backend/MIPS/StackInfo.java, Backend/Maps/DefaultNameMap.java, Backend/MIPS/BypassLatchSchedule.java, Backend/MIPS/Code.java, Backend/MIPS/CodeGen.spec, Backend/Generic/Code.java, Backend/Generic/CodeGen.java, Backend/Generic/GCInfo.java, Backend/Generic/InstrBuilder.java, Backend/Generic/MaxMunchCG.java, Backend/Generic/RegFileInfo.java, Backend/Generic/Runtime.java, Backend/CSAHack/RegAlloc/Color.java, Backend/CSAHack/RegAlloc/DerivationGenerator.java, Backend/CSAHack/RegAlloc/RegAlloc.java, Backend/Analysis/ClassMethodMap.java, Backend/Analysis/InitializerOrdering.java, Backend/Analysis/InsertWriteBarrier.java, Backend/Analysis/InterfaceMethodMap.java, Backend/Analysis/MakeGCThreadSafe.java, Backend/Analysis/PackedClassFieldMap.java, Backend/CSAHack/FlowGraph/AssemFlowGraph.java, Backend/Analysis/BasicGCInfo.java, Backend/Analysis/ClassFieldMap.java, Analysis/TypeInference/ClassCone.java, Analysis/TypeInference/IntraProc.java, Analysis/Tree/AlgebraicSimplification.java, Analysis/Tree/CacheEquivalence.java, Analysis/Tree/ConstantPropagation.java, Analysis/Tree/DeadCodeElimination.java, Analysis/Tree/DominatingMemoryAccess.java, Analysis/Tree/JumpOptimization.java, Analysis/Tree/MemHoisting.java, Analysis/Tree/Simplification.java, Analysis/Tree/TreeFolding.java, Analysis/Transactions/ArrayCopyImplementer.java, Analysis/Transactions/BitFieldNumbering.java, Analysis/Transactions/CloneImplementer.java, Analysis/Transactions/SyncTransformer.java, Analysis/Transactions/TreePostPass.java, Analysis/Transformation/MethodMutator.java, Analysis/Transformation/MethodSplitter.java, Analysis/SizeOpt/BitWidthAnalysis.java, Analysis/SizeOpt/ConstructorClassifier.java, Analysis/SizeOpt/Field2Method.java, Analysis/SizeOpt/FieldReducer.java, Analysis/SizeOpt/MZFChooser.java, Analysis/SizeOpt/MZFCompressor.java, Analysis/SizeOpt/MZFExternalize.java, Analysis/SizeOpt/MZFWidenType.java, Analysis/SizeOpt/MostlyZeroFinder.java, Analysis/Realtime/Stats.java, Analysis/Realtime/ThreadToRealtimeThread.java, Analysis/RoleInference/LocalVariableNamer.java, Analysis/Realtime/CheckAdder.java, Analysis/Realtime/CheckAdderNoSSA.java, Analysis/Realtime/CheckAdderWithTry.java, Analysis/Realtime/CheesyPACheckRemoval.java, Analysis/Realtime/ClassReplacer.java, Analysis/Realtime/PACheckRemoval.java, Analysis/Realtime/QuantaChecker.java, Analysis/Realtime/Realtime.java, Analysis/Quads/DispatchTreeTransformation.java, Analysis/Quads/InitializerTransform.java, Analysis/Quads/MayReadOracle.java, Analysis/Quads/MemoryOptimization.java, Analysis/Quads/MethodInliningCodeFactory.java, Analysis/Quads/MustParamOracle.java, Analysis/Quads/NewMover.java, Analysis/Quads/QuadClassHierarchy.java, Analysis/Quads/SCC/SCCAnalysis.java, Analysis/Quads/SCC/SCCOptimize.java, Analysis/Quads/SimpleConstMap.java, Analysis/Quads/TypeInfo.java, Analysis/Quads/TypeSwitchRemover.java, Analysis/Quads/Unreachable.java, Analysis/Quads/ArrayUnroller.java, Analysis/Quads/CallGraphImpl.java, Analysis/Quads/CallGraphImpl2.java, Analysis/Quads/CoalescingToNoSSA.java, Analysis/Quads/DeadCode.java, Analysis/Quads/DefiniteInitOracle.java, Analysis/PreciseGC/AllocationHoisting.java, Analysis/PreciseGC/MRAFactory.java, Analysis/PreciseGC/WriteBarrierConstElim.java, Analysis/PreciseGC/WriteBarrierData.java, Analysis/PreciseGC/WriteBarrierPostPass.java, Analysis/PreciseGC/WriteBarrierQuadPass.java, Analysis/PreciseGC/WriteBarrierStats.java, Analysis/PreciseGC/WriteBarrierTreePass.java, Analysis/PointerAnalysis/ActionRepository.java, Analysis/PointerAnalysis/ArtificialTempFactory.java, Analysis/PointerAnalysis/EdgesNCallees.java, Analysis/PointerAnalysis/InstrumentSyncOps.java, Analysis/PointerAnalysis/InterProcPA.java, Analysis/PointerAnalysis/InterThreadPA.java, Analysis/PointerAnalysis/LightPAEdgeSet.java, Analysis/PointerAnalysis/MAInfo.java, Analysis/PointerAnalysis/MethodHole.java, Analysis/PointerAnalysis/NodeRepository.java, Analysis/PointerAnalysis/ODInformation.java, Analysis/PointerAnalysis/ODInterProcPA.java, Analysis/PointerAnalysis/ODMAInfo.java, Analysis/PointerAnalysis/ODParIntGraph.java, Analysis/PointerAnalysis/ODPointerAnalysis.java, Analysis/PointerAnalysis/PANode.java, Analysis/PointerAnalysis/PAThreadMap.java, Analysis/PointerAnalysis/ParIntGraph.java, Analysis/PointerAnalysis/PointerAnalysis.java, Analysis/PointerAnalysis/PointsToGraph.java, Analysis/MetaMethods/GenType.java, Analysis/MetaMethods/MetaAllCallers.java, Analysis/MetaMethods/MetaCallGraphImpl.java, Analysis/MetaMethods/MetaMethod.java, Analysis/Partition/Profile.java-old, Analysis/Maps/Derivation.java, Analysis/LowQuad/Loop/AllInductions.java, Analysis/LowQuad/Loop/BasicInductions.java, Analysis/LowQuad/Loop/Induction.java, Analysis/LowQuad/Loop/LoopAnalysis.java, Analysis/LowQuad/Loop/LoopOptimize.java, Analysis/LowQuad/Loop/MyLowQuadNoSSA.java, Analysis/LowQuad/Loop/MyLowQuadSSI.java, Analysis/Instr/AppelRegAlloc.java, Analysis/Instr/AppelRegAllocClasses.java, Analysis/Instr/AppelRegAllocFsk.java, Analysis/Instr/AppelRegAllocStd.java, Analysis/Instr/Check.java, Analysis/Instr/EqTempSets.java, Analysis/Instr/GraphColoringRegAlloc.java, Analysis/Instr/LocalCffRegAlloc.java, Analysis/Instr/RegAlloc.java, Analysis/Instr/RegFile.java, Analysis/Instr/SpillHeuristics.java, Analysis/Instr/Verify.java, Analysis/Instr/Web.java, Analysis/GraphColoring/OptimisticGraphColorer.java, Analysis/GraphColoring/SparseGraph.java, Analysis/EventDriven/AsyncCode.java, Analysis/EventDriven/CloningVisitor.java, Analysis/EnvBuilder/EnvBuilder.java, Analysis/Counters/CounterFactory.java, Analysis/Counters/EpilogMutator.java, Analysis/Counters/RuntimeMethodCloner.java, Analysis/DataFlow/DataFlowBasicBlockVisitor.java, Analysis/DataFlow/LiveTemps.java, Analysis/DataFlow/ReversePostOrderEnumerator.java, Analysis/DataFlow/ReversePostOrderIterator.java, Analysis/DataFlow/SpaceHeavyLiveTemps.java, Analysis/DataFlow/TreeSolver.java, Analysis/AllocationInformationMap.java, Analysis/BasicBlock.java, Analysis/ClassHierarchy.java, Analysis/CycleEq.java, Analysis/DefaultAllocationInformation.java, Analysis/DomTree.java, Analysis/FCFGBasicBlock.java, Analysis/ReachingDefsAltImpl.java, Analysis/ReachingDefsImpl.java, Analysis/SESE.java, Analysis/SSxReachingDefsImpl.java, GNUmakefile: Globally replace all instances of our Util.ASSERT function with the proper JDK1.4 'assert' keyword. Also check in a script, bin/migrate-assert.perl, which does *most* of these replacements for us (feed it a munged version of the source, and unmunge the output). Notably exceptions that can't be automagically done are in Tools/PatMat/MaximalMunchCGG.java. Some others, too. Hacked GNUMakefile to indicate that (current versions of) jikes will no longer compile this code. Fixed 'make java' target so that javac will. THIS COMMIT IS ONLY ON THE java-1-5 BRANCH. THE HEAD IS STILL pre-java 1.4 and jikes-compatible. 2002-02-26 C. Scott Ananian * Util/TypeInference/TypeInference.java, Util/LightBasicBlocks/LightBasicBlock.java, Util/Collections/BinaryHeap.java, Util/Collections/BinaryTree.java, Util/Collections/BinomialHeap.java, Util/Collections/BitSetFactory.java, Util/Collections/DisjointSet.java, Util/Collections/Factories.java, Util/Collections/FibonacciHeap.java, Util/Collections/GenericMultiMap.java, Util/Collections/HashEnvironment.java, Util/Collections/RedBlackTree.java, Util/Collections/WorkSet.java, Util/ArrayIterator.java, Util/BinHeapPriorityQueue.java, Util/BitString.java, Util/CloneableIterator.java, Util/HClassUtil.java, Util/Timer.java, Util/Util.java, Tools/PatMat/CodeGeneratorGenerator.java, Tools/PatMat/MaximalMunchCGG.java, Tools/PatMat/Spec.java, Tools/Annotation/Java12.cup, Temp/CloningTempMap.java, Temp/Temp.java, Main/EDMain.java, Main/EDXMain.java, Main/ODPAMain.java, Main/PAMain.java, Main/SAMain.java, Support/Jasminpatch, Support/Jasminpatch2, Interpret/Tree/DefaultFrame.java, Interpret/Tree/InterpreterOffsetMap.java, Interpret/Tree/Method.java, Interpret/Tree/ObjectRef.java, Interpret/Tree/OffsetMap32.java, Interpret/Tree/StaticState.java, Interpret/Quads/ArrayRef.java, Interpret/Quads/INClass.java, Interpret/Quads/InterpretedThrowable.java, Interpret/Quads/Method.java, Interpret/Quads/ObjectRef.java, Interpret/Quads/StaticState.java, Interpret/Tree/ArrayRef.java, IR/Tree/ALIGN.java, IR/Tree/BINOP.java, IR/Tree/CALL.java, IR/Tree/CJUMP.java, IR/Tree/CONST.java, IR/Tree/CanonicalTreeCode.java, IR/Tree/Code.java, IR/Tree/DATUM.java, IR/Tree/DerivationGenerator.java, IR/Tree/ESEQ.java, IR/Tree/EXPR.java, IR/Tree/INVOCATION.java, IR/Tree/JUMP.java, IR/Tree/LABEL.java, IR/Tree/MEM.java, IR/Tree/METHOD.java, IR/Tree/MOVE.java, IR/Tree/NAME.java, IR/Tree/NATIVECALL.java, IR/Tree/OPER.java, IR/Tree/Print.java, IR/Tree/RETURN.java, IR/Tree/SEGMENT.java, IR/Tree/SEQ.java, IR/Tree/TEMP.java, IR/Tree/THROW.java, IR/Tree/ToCanonicalTree.java, IR/Tree/ToTree.java, IR/Tree/ToTreeHelpers.java, IR/Tree/Translation.java, IR/Tree/Tree.java, IR/Tree/TreeGrapher.java, IR/Tree/TreeUseDefer.java, IR/Tree/TreeVerifyingVisitor.java, IR/Tree/UNOP.java, IR/LowQuad/LowQuadSSI.java, IR/LowQuad/PAOFFSET.java, IR/LowQuad/PCALL.java, IR/LowQuad/PCONST.java, IR/LowQuad/PFCONST.java, IR/LowQuad/PFOFFSET.java, IR/LowQuad/PGET.java, IR/LowQuad/PMCONST.java, IR/LowQuad/PMOFFSET.java, IR/LowQuad/POPER.java, IR/LowQuad/PPTR.java, IR/LowQuad/PSET.java, IR/Quads/AGET.java, IR/Quads/ALENGTH.java, IR/Quads/ANEW.java, IR/Quads/ARRAYINIT.java, IR/Quads/ASET.java, IR/Quads/CALL.java, IR/Quads/CJMP.java, IR/Quads/COMPONENTOF.java, IR/Quads/CONST.java, IR/Quads/CloneSynthesizer.java, IR/Quads/Code.java, IR/Quads/DEBUG.java, IR/Quads/Edge.java, IR/Quads/GET.java, IR/Quads/HANDLER.java, IR/Quads/HandlerSet.java, IR/Quads/INSTANCEOF.java, IR/Quads/METHOD.java, IR/Quads/MONITORENTER.java, IR/Quads/MONITOREXIT.java, IR/Quads/MOVE.java, IR/Quads/NEW.java, IR/Quads/OPER.java, IR/Quads/PHI.java, IR/Quads/Pattern.java, IR/Quads/Peephole.java, IR/Quads/Print.java, IR/Quads/Prune.java, IR/Quads/Quad.java, IR/Quads/ReHandler.java, IR/Quads/SET.java, IR/Quads/SIGMA.java, IR/Quads/SSIRename.java, IR/Quads/SSIToSSA.java, IR/Quads/SWITCH.java, IR/Quads/THROW.java, IR/Quads/TYPECAST.java, IR/Quads/TYPESWITCH.java, IR/Quads/TempChain.java, IR/Quads/ThreadInliner.java, IR/Quads/ToNoSSA.java, IR/Quads/Translate.java, IR/Quads/UnHandler.java, IR/Quads/XI.java, IR/LowQuad/DerivationMap.java, IR/Bytecode/Op.java, IR/Jasmin/Jasmin.java, IR/Bytecode/InMerge.java, IR/Assem/Code.java, IR/Assem/Instr.java, IR/Assem/InstrGroup.java, IR/Assem/InstrMOVE.java, ClassFile/HClass.java, ClassFile/HClassArraySyn.java, ClassFile/HClassProxy.java, ClassFile/HClassSyn.java, ClassFile/HConstructorSyn.java, ClassFile/HFieldSyn.java, ClassFile/HInitializerSyn.java, ClassFile/HMemberProxy.java, ClassFile/HMethodSyn.java, ClassFile/ImplMagic.java, ClassFile/Linker.java, ClassFile/Loader.java, ClassFile/Relinker.java, Backend/StrongARM/Code.java, Backend/StrongARM/CodeGen.spec, Backend/StrongARM/CodeGen.spec.coarseInstrs, Backend/StrongARM/CodeGen.spec.instrGroups, Backend/StrongARM/InstrBuilder.java, Backend/StrongARM/RegFileInfo.java, Backend/StrongARM/TwoWordTemp.java, ClassFile/ClassPointer.java, Backend/Sparc/Code.java, Backend/Sparc/CodeGen.spec, Backend/Sparc/RegFileInfo.java, Backend/Sparc/TempBuilder.java, Backend/Runtime1/DataClaz.java, Backend/Runtime1/DataGC.java, Backend/Runtime1/DataStaticFields.java, Backend/Runtime1/NiftyAllocationStrategy.java, Backend/Runtime1/ObjectBuilder.java, Backend/Runtime1/Runtime.java, Backend/Runtime1/SPAllocationStrategy.java, Backend/Runtime1/TreeBuilder.java, Backend/Runtime1/mzf-unsafe.properties, Backend/PreciseC/Frame.java, Backend/PreciseC/IdentifyNoHandler.java, Backend/PreciseC/TreeToC.java, Backend/Maps/DefaultNameMap.java, Backend/MIPS/BypassLatchSchedule.java, Backend/MIPS/Code.java, Backend/MIPS/CodeGen.spec, Backend/MIPS/InstrBuilder.java, Backend/MIPS/RegFileInfo.java, Backend/MIPS/StackInfo.java, Backend/Generic/Code.java, Backend/Generic/CodeGen.java, Backend/Generic/GCInfo.java, Backend/Generic/InstrBuilder.java, Backend/Generic/MaxMunchCG.java, Backend/Generic/RegFileInfo.java, Backend/Generic/Runtime.java, Backend/CSAHack/RegAlloc/Color.java, Backend/CSAHack/RegAlloc/DerivationGenerator.java, Backend/CSAHack/RegAlloc/RegAlloc.java, Backend/CSAHack/FlowGraph/AssemFlowGraph.java, Analysis/TypeInference/IntraProc.java, Backend/Analysis/BasicGCInfo.java, Backend/Analysis/ClassFieldMap.java, Backend/Analysis/ClassMethodMap.java, Backend/Analysis/InitializerOrdering.java, Backend/Analysis/InsertWriteBarrier.java, Backend/Analysis/InterfaceMethodMap.java, Backend/Analysis/MakeGCThreadSafe.java, Backend/Analysis/PackedClassFieldMap.java, Analysis/TypeInference/ClassCone.java, Analysis/Transformation/MethodSplitter.java, Analysis/Tree/AlgebraicSimplification.java, Analysis/Tree/CacheEquivalence.java, Analysis/Tree/ConstantPropagation.java, Analysis/Tree/DeadCodeElimination.java, Analysis/Tree/DerivationChecker.java, Analysis/Tree/DominatingMemoryAccess.java, Analysis/Tree/JumpOptimization.java, Analysis/Tree/MemHoisting.java, Analysis/Tree/Simplification.java, Analysis/Tree/TreeFolding.java, Analysis/Transformation/MethodMutator.java, Analysis/SizeOpt/ConstructorClassifier.java, Analysis/SizeOpt/Field2Method.java, Analysis/SizeOpt/FieldReducer.java, Analysis/SizeOpt/MZFChooser.java, Analysis/SizeOpt/MZFCompressor.java, Analysis/SizeOpt/MZFExternalize.java, Analysis/SizeOpt/MZFWidenType.java, Analysis/SizeOpt/MostlyZeroFinder.java, Analysis/Transactions/ArrayCopyImplementer.java, Analysis/Transactions/BitFieldNumbering.java, Analysis/Transactions/CloneImplementer.java, Analysis/Transactions/SyncTransformer.java, Analysis/Transactions/TreePostPass.java, Analysis/SizeOpt/BitWidthAnalysis.java, Analysis/RoleInference/LocalVariableNamer.java, Analysis/Quads/SCC/SCCOptimize.java, Analysis/Realtime/CheckAdder.java, Analysis/Realtime/CheckAdderNoSSA.java, Analysis/Realtime/CheckAdderWithTry.java, Analysis/Realtime/CheesyPACheckRemoval.java, Analysis/Realtime/ClassReplacer.java, Analysis/Realtime/PACheckRemoval.java, Analysis/Realtime/QuantaChecker.java, Analysis/Realtime/Realtime.java, Analysis/Realtime/Stats.java, Analysis/Realtime/ThreadToRealtimeThread.java, Analysis/Quads/ArrayUnroller.java, Analysis/Quads/CallGraphImpl.java, Analysis/Quads/CallGraphImpl2.java, Analysis/Quads/CoalescingToNoSSA.java, Analysis/Quads/DeadCode.java, Analysis/Quads/DefiniteInitOracle.java, Analysis/Quads/DispatchTreeTransformation.java, Analysis/Quads/InitializerTransform.java, Analysis/Quads/MayReadOracle.java, Analysis/Quads/MemoryOptimization.java, Analysis/Quads/MethodInliningCodeFactory.java, Analysis/Quads/MustParamOracle.java, Analysis/Quads/NewMover.java, Analysis/Quads/QuadClassHierarchy.java, Analysis/Quads/SCC/SCCAnalysis.java, Analysis/Quads/SimpleConstMap.java, Analysis/Quads/TypeInfo.java, Analysis/Quads/TypeSwitchRemover.java, Analysis/Quads/Unreachable.java, Analysis/PreciseGC/AllocationHoisting.java, Analysis/PreciseGC/MRAFactory.java, Analysis/PreciseGC/WriteBarrierConstElim.java, Analysis/PreciseGC/WriteBarrierData.java, Analysis/PreciseGC/WriteBarrierPostPass.java, Analysis/PreciseGC/WriteBarrierQuadPass.java, Analysis/PreciseGC/WriteBarrierStats.java, Analysis/PreciseGC/WriteBarrierTreePass.java, Analysis/PointerAnalysis/ODMAInfo.java, Analysis/PointerAnalysis/ODParIntGraph.java, Analysis/PointerAnalysis/ODPointerAnalysis.java, Analysis/PointerAnalysis/PANode.java, Analysis/PointerAnalysis/PAThreadMap.java, Analysis/PointerAnalysis/ParIntGraph.java, Analysis/PointerAnalysis/PointerAnalysis.java, Analysis/PointerAnalysis/PointsToGraph.java, Analysis/Partition/Profile.java-old, Analysis/PointerAnalysis/ActionRepository.java, Analysis/PointerAnalysis/ArtificialTempFactory.java, Analysis/PointerAnalysis/EdgesNCallees.java, Analysis/PointerAnalysis/InstrumentSyncOps.java, Analysis/PointerAnalysis/InterProcPA.java, Analysis/PointerAnalysis/InterThreadPA.java, Analysis/PointerAnalysis/LightPAEdgeSet.java, Analysis/PointerAnalysis/MAInfo.java, Analysis/PointerAnalysis/MethodHole.java, Analysis/PointerAnalysis/NodeRepository.java, Analysis/PointerAnalysis/ODInformation.java, Analysis/PointerAnalysis/ODInterProcPA.java, Analysis/MetaMethods/MetaMethod.java, Analysis/Maps/Derivation.java, Analysis/MetaMethods/GenType.java, Analysis/MetaMethods/MetaAllCallers.java, Analysis/MetaMethods/MetaCallGraphImpl.java, Analysis/LowQuad/Loop/AllInductions.java, Analysis/LowQuad/Loop/BasicInductions.java, Analysis/LowQuad/Loop/Induction.java, Analysis/LowQuad/Loop/LoopAnalysis.java, Analysis/LowQuad/Loop/LoopOptimize.java, Analysis/LowQuad/Loop/MyLowQuadNoSSA.java, Analysis/LowQuad/Loop/MyLowQuadSSI.java, Analysis/LowQuad/DerivationChecker.java, Analysis/Instr/AppelRegAlloc.java, Analysis/Instr/AppelRegAllocClasses.java, Analysis/Instr/AppelRegAllocFsk.java, Analysis/Instr/AppelRegAllocStd.java, Analysis/Instr/Check.java, Analysis/Instr/EqTempSets.java, Analysis/Instr/GraphColoringRegAlloc.java, Analysis/Instr/LocalCffRegAlloc.java, Analysis/Instr/RegAlloc.java, Analysis/Instr/RegFile.java, Analysis/Instr/SpillHeuristics.java, Analysis/Instr/Verify.java, Analysis/Instr/Web.java, Analysis/GraphColoring/OptimisticGraphColorer.java, Analysis/GraphColoring/SparseGraph.java, Analysis/EventDriven/AsyncCode.java, Analysis/EventDriven/CloningVisitor.java, Analysis/EnvBuilder/EnvBuilder.java, Analysis/DataFlow/DataFlowBasicBlockVisitor.java, Analysis/DataFlow/LiveTemps.java, Analysis/DataFlow/ReversePostOrderEnumerator.java, Analysis/DataFlow/ReversePostOrderIterator.java, Analysis/DataFlow/SpaceHeavyLiveTemps.java, Analysis/DataFlow/TreeSolver.java, Analysis/Counters/CounterFactory.java, Analysis/Counters/EpilogMutator.java, Analysis/Counters/RuntimeMethodCloner.java, Analysis/AllocationInformationMap.java, Analysis/BasicBlock.java, Analysis/ClassHierarchy.java, Analysis/CycleEq.java, Analysis/DefaultAllocationInformation.java, Analysis/DomTree.java, Analysis/FCFGBasicBlock.java, Analysis/ReachingDefsAltImpl.java, Analysis/ReachingDefsImpl.java, Analysis/SESE.java, Analysis/SSxReachingDefsImpl.java: Renamed harpoon.Util.Util.assert() to harpoon.Util.Util.ASSERT() so as not to conflict with the Java 1.4 'assert' keyword. On a separate branch, I will check in changes that replace our ASSERT with the new native keyword, but I'm not going to force everyone on the main trunk to upgrade to 1.4 just yet. (Also, I don't think our Runtime supports the 'assert' feature yet, and I'd like to ensure that FLEX is still able to compile FLEX.) * Analysis/GenericContextFactory.java: Bug-fix to context creation code. * Analysis/SizeOpt/BitWidthAnalysis.java, Analysis/Context.java, Analysis/GenericContextFactory.java: Checked in a general-purpose well-documented implementation of Context (as in "context-sensitive" and "context-insensitive"), and change BitWidthAnalysis to use this implementation instead of its home-grown one. * IR/RawClass/ClassFile.java: Bug-fix for ClassFile Raw pretty-printer. This one has been sitting in my tree for a while. 2002-02-25 C. Scott Ananian * Analysis/Partition/Profile.java-old: Moved old Profile.java from magic-1-2 branch into Analysis/Partition and give it a -old suffix since it is too old to compile correctly anymore. @RENAME: QuadSSA/Profile.java Partition/Profile.java-old@ * bin/annotate.perl, bin/annotate.sh, bin/brilliance.tcsh, bin/browse-roles, bin/build-arm-hack, bin/build-arm-pnk, bin/build-mipsda, bin/build-mipsvp, bin/build-precisec, bin/build-roles, bin/build-roles-browse, bin/build-spec, bin/build-spec-arm-hack, bin/build-spec-arm-pnk, bin/build-spec-mipsda, bin/build-spec-mipsvp, bin/build-spec-precisec, bin/copyright.perl, bin/cvsblame.pl, bin/find-flex-dir, bin/interpret, bin/keywords.sed, bin/munge, bin/remove-stars.perl, bin/run-java, bin/source-markup.perl, bin/test-collections, bin/unmunge, bin/unmunge.awk, Util/LightBasicBlocks/CachingLBBConverter.java, Util/LightBasicBlocks/CachingSCCLBBFactory.java, Util/LightBasicBlocks/LBBConverter.java, Util/LightBasicBlocks/LightBasicBlock.java, Util/LightBasicBlocks/SCCLBBFactory.java, Util/TypeInference/ArrayInfo.java, Util/TypeInference/CachingArrayInfo.java, Util/TypeInference/ExactTemp.java, Util/TypeInference/TypeInference.java, Util/Collections/MultiMapSet.java, Util/Collections/PairMapEntry.java, Util/Collections/PersistentEnvironment.java, Util/Collections/PersistentMap.java, Util/Collections/PersistentSet.java, Util/Collections/PersistentTreeNode.java, Util/Collections/RedBlackTree.java, Util/Collections/SetFactory.java, Util/Collections/SetWrapper.java, Util/Collections/TestMap.java, Util/Collections/TestSet.java, Util/Collections/UniqueStack.java, Util/Collections/UniqueVector.java, Util/Collections/UnmodifiableMultiMap.java, Util/Collections/WorkSet.java, Util/Collections/package.html, Util/Collections/AbstractHeap.java, Util/Collections/AbstractMapEntry.java, Util/Collections/AggregateMapFactory.java, Util/Collections/AggregateSetFactory.java, Util/Collections/BinaryHeap.java, Util/Collections/BinaryTree.java, Util/Collections/BinomialHeap.java, Util/Collections/BitSetFactory.java, Util/Collections/CollectionFactory.java, Util/Collections/CollectionWrapper.java, Util/Collections/DisjointSet.java, Util/Collections/Environment.java, Util/Collections/Factories.java, Util/Collections/FibonacciHeap.java, Util/Collections/GenericInvertibleMap.java, Util/Collections/GenericInvertibleMultiMap.java, Util/Collections/GenericMultiMap.java, Util/Collections/HashEnvironment.java, Util/Collections/Heap.java, Util/Collections/IntervalTree.java, Util/Collections/InvertibleMap.java, Util/Collections/InvertibleMultiMap.java, Util/Collections/LinearMap.java, Util/Collections/LinearSet.java, Util/Collections/ListFactory.java, Util/Collections/ListWrapper.java, Util/Collections/MapFactory.java, Util/Collections/MapSet.java, Util/Collections/MapWrapper.java, Util/Collections/MultiMap.java, Util/BasicBlocks/BBConverter.java, Util/BasicBlocks/CachingBBConverter.java, Util/BasicBlocks/CachingSCCBBFactory.java, Util/BasicBlocks/SCCBBFactory.java, Util/ReverseIterator.java, Util/Set.java, Util/SingletonEnumerator.java, Util/SortedMapComparator.java, Util/Timer.java, Util/Tuple.java, Util/UComp.java, Util/UniqueFIFO.java, Util/UniqueStack.java, Util/UniqueVector.java, Util/UnmodifiableIterator.java, Util/UnmodifiableListIterator.java, Util/Util.java, Util/Worklist.java, Util/package.html, Tools/PatMat/doc-files/instr-selection-tool.html, Util/ArrayEnumerator.java, Util/ArrayFactory.java, Util/ArrayIterator.java, Util/ArraySet.java, Util/BinHeapPriorityQueue.java, Util/BinaryRelation.java, Util/BitString.java, Util/CloneableIterator.java, Util/CombineEnumerator.java, Util/CombineIterator.java, Util/Default.java, Util/EnumerationIterator.java, Util/FIFO.java, Util/FilterEnumerator.java, Util/FilterIterator.java, Util/Graph.java, Util/Grapher.java, Util/HClassUtil.java, Util/Indexer.java, Util/IteratorEnumerator.java, Util/ListComparator.java, Util/MapComparator.java, Util/MaxPriorityQueue.java, Util/NullEnumerator.java, Util/ParseUtil.java, Util/PredicateWrapper.java, Util/ReferenceUnique.java, Util/ReverseEnumerator.java: Merge magic-2-0 branch back to HEAD. @MERGE: magic-2-0@ * Tools/PatMat/.cvsignore: Merge magic-2-0 branch back to HEAD. * Tools/PatMat/CodeGeneratorGenerator.java, Tools/PatMat/CommutativityExpander.java, Tools/PatMat/ErrorMsg.java, Tools/PatMat/Lexer.jlex, Tools/PatMat/Main.java, Tools/PatMat/MaximalMunchCGG.java, Tools/PatMat/Parser.cup, Tools/PatMat/README, Tools/PatMat/Spec.java, Tools/PatMat/package.html, Tools/Annotation/Lex/BooleanLiteral.java, Tools/Annotation/Lex/CharacterLiteral.java, Tools/Annotation/Lex/Comment.java, Tools/Annotation/Lex/DocumentationComment.java, Tools/Annotation/Lex/DoubleLiteral.java, Tools/Annotation/Lex/EOF.java, Tools/Annotation/Lex/EndOfLineComment.java, Tools/Annotation/Lex/EscapedUnicodeReader.java, Tools/Annotation/Lex/FloatLiteral.java, Tools/Annotation/Lex/Identifier.java, Tools/Annotation/Lex/InputElement.java, Tools/Annotation/Lex/IntegerLiteral.java, Tools/Annotation/Lex/Keyword.java, Tools/Annotation/Lex/Lexer.java, Tools/Annotation/Lex/LinePos.java, Tools/Annotation/Lex/Literal.java, Tools/Annotation/Lex/LongLiteral.java, Tools/Annotation/Lex/NullLiteral.java, Tools/Annotation/Lex/NumericLiteral.java, Tools/Annotation/Lex/Operator.java, Tools/Annotation/Lex/Separator.java, Tools/Annotation/Lex/StringLiteral.java, Tools/Annotation/Lex/Token.java, Tools/Annotation/Lex/TraditionalComment.java, Tools/Annotation/Lex/WhiteSpace.java, Tools/Annotation/Lex/package.html, Tools/Annotation/package.html: Merge magic-2-0 branch back to HEAD. @MERGE: magic-2-0@ * Tools/Annotation/.cvsignore: Merge magic-2-0 branch back to HEAD. * Tools/Annotation/Java12.cup, Tools/Annotation/Lexer.java, Tools/Annotation/Main.java, Tools/README, Test/PA/Test5/A.java, Test/PA/Test6/EscapeTest.java, Test/PA/Test3/multiset.java, Test/PA/Test4/Sum.java, Test/PA/Hashtable.template, Test/PA/Str2StrMap.java, Test/PA/Test1/complex.java, Test/PA/Test2/Server.java, Test/PA/s, Support/NullCodeGen.template, Support/_200_check-root-set, Support/_202_jess-root-set, Support/cpzip.jar, Support/datagram-root-set, Support/jasmin.jar, Support/locale-root-set, Support/mipsda-makefile.template, Support/nativecode-makefile.template, Support/precisec-makefile.template, Support/realtime.jar, Support/reflect-thunk.jar, Support/rmi-root-set, Support/samain-root-set, Support/servo.jar, Support/video.jar, Support/volano-root-set, Temp/CloningTempMap.java, Temp/Label.java, Temp/LabelList.java, Temp/Temp.java, Temp/TempFactory.java, Temp/TempList.java, Temp/TempMap.java, Temp/WritableTempMap.java, Temp/package.html, Test/EventDriven/EventDriven3, Test/EventDriven/WebServer.jar, Support/CUP.jar, Support/Jasminpatch, Support/Jasminpatch2, Support/Lex.jar, Runtime/PreciseGC/WriteBarrier.java, Runtime/Transactions/CommitRecord.java, Runtime/Transactions/TransactionAbortException.java, Runtime/Transactions/package.html: Merge magic-2-0 branch back to HEAD. @MERGE: magic-2-0@ * Runtime/AltArray/.cvsignore: Merge magic-2-0 branch back to HEAD. * Runtime/AltArray/ArrayImplJavaType.jt, Runtime/AltArray/ChunkArrayJavaType.jt, Runtime/AltArray/SimpleArrayJavaType.jt, Runtime/AltArray/package.html, NOTES/BackendTODO, NOTES/OptimizationsTODO, NOTES/codegen-out.java, NOTES/instr-selection-tool, NOTES/jls.problems, RunTime/Monitor.properties, Runtime/ArrayCopy.java, Runtime/CounterSupport.java, Runtime/Counters.java, Runtime/MZFExternalMap.java, Runtime/package.html, Main/Run.java, Main/SAMain.java, Main/Sizer.java, Main/TypesMain.java, Interpret/Tree/Method.java, Interpret/Tree/NativeMethod.java, Interpret/Tree/NativeStackFrame.java, Interpret/Tree/NullNativeMethod.java, Interpret/Tree/ObjectRef.java, Interpret/Tree/OffsetMap.java, Interpret/Tree/OffsetMap32.java, Interpret/Tree/Pointer.java, Interpret/Tree/PointerTypeChangedException.java, Interpret/Tree/README, Interpret/Tree/Ref.java, Interpret/Tree/StackFrame.java, Interpret/Tree/StaticState.java, Interpret/Tree/StringPointer.java, Interpret/Tree/Support.java, Interpret/Tree/TestRun.java, Interpret/Tree/TreeStackFrame.java, Interpret/Tree/UndefinedPointer.java, Interpret/Tree/UndefinedRef.java, Interpret/Tree/package.html, Main/CHStats.java, Main/CallGraph.java, Main/EDMain.java, Main/EDXMain.java, Main/EventDriven.java, Main/Graph.java, Main/JMain.java, Main/Lint.java, Main/Main.java, Main/ODPAMain.java, Main/Options.java, Main/PAMain.java, Main/ProfileMain.java, Main/Raw.java, Interpret/Tree/AllocationInfo.java, Interpret/Tree/AllocationStrategy.java, Interpret/Tree/ArrayPointer.java, Interpret/Tree/ArrayRef.java, Interpret/Tree/ClazPointer.java, Interpret/Tree/ConstPointer.java, Interpret/Tree/Debug.java, Interpret/Tree/DefaultAllocationStrategy.java, Interpret/Tree/DefaultFrame.java, Interpret/Tree/FieldPointer.java, Interpret/Tree/FieldValueList.java, Interpret/Tree/HCLibrary.java, Interpret/Tree/HClassInfo.java, Interpret/Tree/INClass.java, Interpret/Tree/INFile.java, Interpret/Tree/INFileInputStream.java, Interpret/Tree/INFileOutputStream.java, Interpret/Tree/INFloatDouble.java, Interpret/Tree/INObject.java, Interpret/Tree/INRandomAccessFile.java, Interpret/Tree/INRuntime.java, Interpret/Tree/INString.java, Interpret/Tree/INSystem.java, Interpret/Tree/InterfaceList.java, Interpret/Tree/InterfaceListPointer.java, Interpret/Tree/InterpretedThrowable.java, Interpret/Tree/InterpreterAllocationStrategy.java, Interpret/Tree/InterpreterCachingCodeFactory.java, Interpret/Tree/InterpreterOffsetMap.java, IR/Tree/PreciselyTyped.java, IR/Tree/Print.java, IR/Tree/README, IR/Tree/RETURN.java, IR/Tree/SEGMENT.java, IR/Tree/SEQ.java, IR/Tree/Stm.java, IR/Tree/StmList.java, IR/Tree/TEMP.java, IR/Tree/THROW.java, IR/Tree/ToCanonicalTree.java, IR/Tree/ToTree.java, IR/Tree/ToTreeHelpers.java, IR/Tree/Translation.java, IR/Tree/Tree.java, IR/Tree/TreeCode.java, IR/Tree/TreeDerivation.java, IR/Tree/TreeFactory.java, IR/Tree/TreeGrapher.java, IR/Tree/TreeKind.java, IR/Tree/TreeUseDefer.java, IR/Tree/TreeVerifyingVisitor.java, IR/Tree/TreeVisitor.java, IR/Tree/Type.java, IR/Tree/Typed.java, IR/Tree/UNOP.java, IR/Tree/Uop.java, IR/Tree/package.html, Interpret/Quads/ArrayRef.java, Interpret/Quads/FieldValueList.java, Interpret/Quads/HCLibrary.java, Interpret/Quads/INClass.java, Interpret/Quads/INClassLoader.java, Interpret/Quads/INFile.java, Interpret/Quads/INFileInputStream.java, Interpret/Quads/INFileOutputStream.java, Interpret/Quads/INFileSystem.java, Interpret/Quads/INFloatDouble.java, Interpret/Quads/INMath.java, Interpret/Quads/INObject.java, Interpret/Quads/INRandomAccessFile.java, Interpret/Quads/INResourceBundle.java, Interpret/Quads/INRuntime.java, Interpret/Quads/INString.java, Interpret/Quads/INSystem.java, Interpret/Quads/InterpretedThrowable.java, Interpret/Quads/Method.java, Interpret/Quads/NativeMethod.java, Interpret/Quads/NativeStackFrame.java, Interpret/Quads/NullNativeMethod.java, Interpret/Quads/ObjectRef.java, Interpret/Quads/QuadStackFrame.java, Interpret/Quads/Ref.java, Interpret/Quads/StackFrame.java, Interpret/Quads/StaticState.java, Interpret/Quads/Support.java, Interpret/Quads/package.html, IR/Tree/ALIGN.java, IR/Tree/BINOP.java, IR/Tree/Bop.java, IR/Tree/CALL.java, IR/Tree/CJUMP.java, IR/Tree/CONST.java, IR/Tree/CanonicalTreeCode.java, IR/Tree/Code.java, IR/Tree/DATUM.java, IR/Tree/Data.java, IR/Tree/DerivationGenerator.java, IR/Tree/ESEQ.java, IR/Tree/EXPR.java, IR/Tree/Exp.java, IR/Tree/ExpList.java, IR/Tree/INVOCATION.java, IR/Tree/JUMP.java, IR/Tree/LABEL.java, IR/Tree/MEM.java, IR/Tree/METHOD.java, IR/Tree/MOVE.java, IR/Tree/NAME.java, IR/Tree/NATIVECALL.java, IR/Tree/OPER.java, IR/Tree/OptimizedTreeCode.java, IR/RawClass/AccessFlags.java, IR/RawClass/Attribute.java, IR/RawClass/AttributeCode.java, IR/RawClass/AttributeConstantValue.java, IR/RawClass/AttributeExceptions.java, IR/RawClass/AttributeInnerClasses.java, IR/RawClass/AttributeLineNumberTable.java, IR/RawClass/AttributeLocalVariableTable.java, IR/RawClass/AttributeSourceFile.java, IR/RawClass/AttributeSynthetic.java, IR/RawClass/AttributeUnknown.java, IR/RawClass/ClassDataException.java, IR/RawClass/ClassDataInputStream.java, IR/RawClass/ClassDataOutputStream.java, IR/RawClass/ClassFile.java, IR/RawClass/Constant.java, IR/RawClass/ConstantClass.java, IR/RawClass/ConstantDouble.java, IR/RawClass/ConstantFieldref.java, IR/RawClass/ConstantFloat.java, IR/RawClass/ConstantInteger.java, IR/RawClass/ConstantInterfaceMethodref.java, IR/RawClass/ConstantLong.java, IR/RawClass/ConstantMethodref.java, IR/RawClass/ConstantNameAndType.java, IR/RawClass/ConstantString.java, IR/RawClass/ConstantUtf8.java, IR/RawClass/ConstantValue.java, IR/RawClass/ExceptionTable.java, IR/RawClass/FieldInfo.java, IR/RawClass/InnerClass.java, IR/RawClass/LineNumberTable.java, IR/RawClass/LocalVariableTable.java, IR/RawClass/MethodInfo.java, IR/RawClass/README, IR/RawClass/package.html, IR/Quads/AGET.java, IR/Quads/ALENGTH.java, IR/Quads/ANEW.java, IR/Quads/ARRAYINIT.java, IR/Quads/ASET.java, IR/Quads/CALL.java, IR/Quads/CJMP.java, IR/Quads/COMPONENTOF.java, IR/Quads/CONST.java, IR/Quads/CleanHandlers.java, IR/Quads/CloneSynthesizer.java, IR/Quads/Code.java, IR/Quads/DEBUG.java, IR/Quads/Edge.java, IR/Quads/Eval.java, IR/Quads/FOOTER.java, IR/Quads/GET.java, IR/Quads/HANDLER.java, IR/Quads/HEADER.java, IR/Quads/HandInfo.java, IR/Quads/HandlerSet.java, IR/Quads/HashMapList.java, IR/Quads/INSTANCEOF.java, IR/Quads/LABEL.java, IR/Quads/METHOD.java, IR/Quads/MONITORENTER.java, IR/Quads/MONITOREXIT.java, IR/Quads/MOVE.java, IR/Quads/NEW.java, IR/Quads/NOP.java, IR/Quads/OPER.java, IR/Quads/OperVisitor.java, IR/Quads/PHI.java, IR/Quads/Pattern.java, IR/Quads/Peephole.java, IR/Quads/Print.java, IR/Quads/Prune.java, IR/Quads/Qop.java, IR/Quads/Quad.java, IR/Quads/QuadFactory.java, IR/Quads/QuadKind.java, IR/Quads/QuadNoSSA.java, IR/Quads/QuadRSSx.java, IR/Quads/QuadSSA.java, IR/Quads/QuadSSI.java, IR/Quads/QuadVisitor.java, IR/Quads/QuadWithTry.java, IR/Quads/README, IR/Quads/RETURN.java, IR/Quads/RSSxToNoSSA.java, IR/Quads/ReHandler.java, IR/Quads/ReHandlerToSSA.java, IR/Quads/SET.java, IR/Quads/SIGMA.java, IR/Quads/SSIRename.java, IR/Quads/SSIToSSA.java, IR/Quads/SWITCH.java, IR/Quads/TESTER.java, IR/Quads/THROW.java, IR/Quads/TYPECAST.java, IR/Quads/TYPESWITCH.java, IR/Quads/TempChain.java, IR/Quads/ThreadInliner.java, IR/Quads/ToNoSSA.java, IR/Quads/Translate.java, IR/Quads/UnHandler.java, IR/Quads/XI.java, IR/Quads/package.html, IR/LowQuad/LowQuad.java, IR/LowQuad/LowQuadFactory.java, IR/LowQuad/LowQuadKind.java, IR/LowQuad/LowQuadNoSSA.java, IR/LowQuad/LowQuadSSA.java, IR/LowQuad/LowQuadSSI.java, IR/LowQuad/LowQuadVisitor.java, IR/LowQuad/PAOFFSET.java, IR/LowQuad/PARRAY.java, IR/LowQuad/PCALL.java, IR/LowQuad/PCONST.java, IR/LowQuad/PFCONST.java, IR/LowQuad/PFIELD.java, IR/LowQuad/PFOFFSET.java, IR/LowQuad/PGET.java, IR/LowQuad/PMCONST.java, IR/LowQuad/PMETHOD.java, IR/LowQuad/PMOFFSET.java, IR/LowQuad/POPER.java, IR/LowQuad/PPTR.java, IR/LowQuad/PSET.java, IR/LowQuad/README, IR/LowQuad/Translate.java, IR/LowQuad/package.html, IR/Properties/CFGEdge.java, IR/Properties/CFGraphable.java, IR/Properties/CFGrapher.java, IR/Properties/Edges.java, IR/Properties/Renameable.java, IR/Properties/UseDef.java, IR/Properties/UseDefable.java, IR/Properties/UseDefer.java, IR/Properties/package.html, IR/LowQuad/Code.java, IR/LowQuad/DerivationMap.java, IR/LowQuad/LQop.java, IR/Jasmin/Jasmin.java, IR/Jasmin/TempInfo.java, IR/Jasmin/package.html, IR/Assem/InstrCALL.java, IR/Assem/InstrDIRECTIVE.java, IR/Assem/InstrEdge.java, IR/Assem/InstrFactory.java, IR/Assem/InstrGroup.java, IR/Assem/InstrJUMP.java, IR/Assem/InstrLABEL.java, IR/Assem/InstrMEM.java, IR/Assem/InstrMOVE.java, IR/Assem/InstrVisitor.java, IR/Assem/README, IR/Assem/package.html, IR/Bytecode/Code.java, IR/Bytecode/InCti.java, IR/Bytecode/InGen.java, IR/Bytecode/InMerge.java, IR/Bytecode/InRet.java, IR/Bytecode/InSwitch.java, IR/Bytecode/Instr.java, IR/Bytecode/Liveness.java, IR/Bytecode/Op.java, IR/Bytecode/OpClass.java, IR/Bytecode/OpConstant.java, IR/Bytecode/OpField.java, IR/Bytecode/OpLocalVariable.java, IR/Bytecode/OpMethod.java, IR/Bytecode/Operand.java, IR/Bytecode/package.html, IR/Assem/Code.java, IR/Assem/Instr.java, IR/AIRE/IR_DelayMechanism.java, IR/AIRE/IR_Kind.java, IR/AIRE/IR_Mode.java, IR/AIRE/IR_Pure.java, IR/AIRE/IR_SignalKind.java, IR/AIRE/IR_SourceLanguage.java, Contrib/getopt/package.html, IR/Registration.java, IR/package.html, ClassFile/DuplicateClassException.java, ClassFile/DuplicateMemberException.java, ClassFile/Factories.java, ClassFile/HArrayField.java, ClassFile/HArrayMethod.java, ClassFile/HClass.java, ClassFile/HClassArray.java, ClassFile/HClassArraySyn.java, ClassFile/HClassCls.java, ClassFile/HClassImpl.java, ClassFile/HClassMutator.java, ClassFile/HClassPrimitive.java, ClassFile/HClassProxy.java, ClassFile/HClassSyn.java, ClassFile/HCode.java, ClassFile/HCodeAndMaps.java, ClassFile/HCodeElement.java, ClassFile/HCodeFactory.java, ClassFile/HConstructor.java, ClassFile/HConstructorImpl.java, ClassFile/HConstructorProxy.java, ClassFile/HConstructorSyn.java, ClassFile/HData.java, ClassFile/HDataElement.java, ClassFile/HField.java, ClassFile/HFieldImpl.java, ClassFile/HFieldMutator.java, ClassFile/HFieldProxy.java, ClassFile/HFieldSyn.java, ClassFile/HInitializer.java, ClassFile/HInitializerImpl.java, ClassFile/HInitializerProxy.java, ClassFile/HInitializerSyn.java, ClassFile/HMember.java, ClassFile/HMemberProxy.java, ClassFile/HMethod.java, ClassFile/HMethodImpl.java, ClassFile/HMethodMutator.java, ClassFile/HMethodProxy.java, ClassFile/HMethodSyn.java, ClassFile/HPointer.java, ClassFile/ImplGNU.java, ClassFile/ImplMagic.java, ClassFile/Linker.java, ClassFile/Loader.java, ClassFile/NoSuchClassException.java, ClassFile/NoSuchMemberException.java, ClassFile/Relinker.java, ClassFile/SerializableCodeFactory.java, ClassFile/UniqueName.java, ClassFile/package.html, Backend/StrongARM/Frame.java, Backend/StrongARM/InstrBuilder.java, Backend/StrongARM/README, Backend/StrongARM/RegFileInfo.java, Backend/StrongARM/TempBuilder.java, Backend/StrongARM/TempVisitor.java, Backend/StrongARM/TwoWordTemp.java, Backend/StrongARM/package.html, Backend/StrongARM/strongarm.flex, ClassFile/CachingCodeFactory.java, ClassFile/ClassPointer.java: Merge magic-2-0 branch back to HEAD. @MERGE: magic-2-0@ * Backend/StrongARM/.cvsignore: Merge magic-2-0 branch back to HEAD. * Backend/StrongARM/AccelRFInfo.java, Backend/StrongARM/Code.java, Backend/StrongARM/CodeGen.spec, Backend/StrongARM/CodeGen.spec.coarseInstrs, Backend/StrongARM/CodeGen.spec.instrGroups: Merge magic-2-0 branch back to HEAD. @MERGE: magic-2-0@ * Backend/Sparc/.cvsignore: Merge magic-2-0 branch back to HEAD. * Backend/Runtime2/TreeBuilder.java, Backend/Sparc/Code.java, Backend/Sparc/CodeGen.spec, Backend/Sparc/Frame.java, Backend/Sparc/InstrBuilder.java, Backend/Sparc/README, Backend/Sparc/RegFileInfo.java, Backend/Sparc/TempBuilder.java, Backend/Sparc/package.html, Backend/Runtime1/DataConfigChecker.java, Backend/Runtime1/DataGC.java, Backend/Runtime1/DataInitializers.java, Backend/Runtime1/DataInterfaceList.java, Backend/Runtime1/DataJavaMain.java, Backend/Runtime1/DataReflection1.java, Backend/Runtime1/DataReflection2.java, Backend/Runtime1/DataReflectionMemberList.java, Backend/Runtime1/DataStaticFields.java, Backend/Runtime1/DataStrings.java, Backend/Runtime1/MallocAllocationStrategy.java, Backend/Runtime1/NiftyAllocationStrategy.java, Backend/Runtime1/NullAllocationStrategy.java, Backend/Runtime1/ObjectBuilder.java, Backend/Runtime1/Runtime.java, Backend/Runtime1/RuntimeInformation.java, Backend/Runtime1/SPAllocationStrategy.java, Backend/Runtime1/StubCode.java, Backend/Runtime1/TreeBuilder.java, Backend/Runtime1/class-root.properties, Backend/Runtime1/field-root.properties, Backend/Runtime1/init-safe.properties, Backend/Runtime1/method-root.properties, Backend/Runtime1/mzf-unsafe.properties, Backend/Runtime1/package.html, Backend/Runtime1/transact-safe.properties, Backend/Runtime1/writebarrier-safe.properties, Backend/Runtime2/Runtime.java, Backend/Runtime1/AllocationStrategy.java, Backend/Runtime1/AppelAllocationStrategy.java, Backend/Runtime1/BDWAllocationStrategy.java, Backend/Runtime1/Data.java, Backend/Runtime1/DataClaz.java, Backend/Maps/MethodMap.java, Backend/Maps/NameMap.java, Backend/Maps/package.html, Backend/Pentium/README, Backend/PreciseC/Frame.java, Backend/PreciseC/IdentifyNoHandler.java, Backend/PreciseC/PGCNiftyAllocationStrategy.java, Backend/PreciseC/PGCNiftyAllocationStrategyWithStats.java, Backend/PreciseC/TreeToC.java, Backend/PreciseC/package.html, Backend/Maps/BackendDerivation.java, Backend/Maps/CHFinalMap.java, Backend/Maps/ClassDepthMap.java, Backend/Maps/DefaultClassDepthMap.java, Backend/Maps/DefaultFinalMap.java, Backend/Maps/DefaultInlineMap.java, Backend/Maps/DefaultNameMap.java, Backend/Maps/FieldMap.java, Backend/Maps/FinalMap.java, Backend/Maps/InlineMap.java: Merge magic-2-0 branch back to HEAD. @MERGE: magic-2-0@ * Backend/MIPS/.cvsignore: Merge magic-2-0 branch back to HEAD. * Backend/MIPS/BypassLatchSchedule.java, Backend/MIPS/Code.java, Backend/MIPS/CodeGen.spec, Backend/MIPS/Frame.java, Backend/MIPS/InstrBuilder.java, Backend/MIPS/RegFileInfo.java, Backend/MIPS/StackInfo.java, Backend/MIPS/TempBuilder.java, Backend/MIPS/TempVisitor.java, Backend/MIPS/package.html, Backend/JavaByte/README, Backend/Jouette/CodeGen.spec, Backend/Generic/Code.java, Backend/Generic/CodeGen.java, Backend/Generic/Frame.java, Backend/Generic/GCInfo.java, Backend/Generic/InstrBuilder.java, Backend/Generic/LocationFactory.java, Backend/Generic/MaxMunchCG.java, Backend/Generic/README, Backend/Generic/RegFileInfo.java, Backend/Generic/RegUseDefer.java, Backend/Generic/Runtime.java, Backend/Generic/RuntimeInformation.java, Backend/Generic/TempBuilder.java, Backend/Generic/package.html, Backend/CSAHack/RegAlloc/Code.java, Backend/CSAHack/RegAlloc/Color.java, Backend/CSAHack/RegAlloc/DerivationGenerator.java, Backend/CSAHack/RegAlloc/InterferenceGraph.java, Backend/CSAHack/RegAlloc/Liveness.java, Backend/CSAHack/RegAlloc/MoveList.java, Backend/CSAHack/RegAlloc/RegAlloc.java, Backend/CSAHack/RegAlloc/RegWork.java, Backend/CSAHack/RegAlloc/Set.java, Backend/CSAHack/RegAlloc/Spiller.java, Backend/CSAHack/Graph/Graph.java, Backend/CSAHack/Graph/Node.java, Backend/CSAHack/Graph/NodeList.java, Backend/CSAHack/FlowGraph/AssemFlowGraph.java, Backend/CSAHack/FlowGraph/FlowGraph.java, Backend/Analysis/BasicGCInfo.java, Backend/Analysis/ClassFieldMap.java, Backend/Analysis/ClassMethodMap.java, Backend/Analysis/GCTraceStore.java, Backend/Analysis/InitializerOrdering.java, Backend/Analysis/InsertWriteBarrier.java, Backend/Analysis/InterfaceMethodMap.java, Backend/Analysis/JLSRuntimeInformation.java, Backend/Analysis/MakeGCThreadSafe.java, Backend/Analysis/PackedClassFieldMap.java, Backend/Analysis/SortedClassFieldMap.java, Backend/Analysis/SunJDKRuntimeInformation.java, Backend/Analysis/package.html, Analysis/Tree/AlgebraicSimplification.java, Analysis/Tree/CacheEquivalence.java, Analysis/Tree/Canonicalize.java, Analysis/Tree/ConstantPropagation.java, Analysis/Tree/DeadCodeElimination.java, Analysis/Tree/DerivationChecker.java, Analysis/Tree/DominatingMemoryAccess.java, Analysis/Tree/JumpOptimization.java, Analysis/Tree/MemHoisting.java, Analysis/Tree/Simplification.java, Analysis/Tree/TreeFolding.java, Analysis/Tree/package.html, Analysis/TypeInference/AuxUniqueFIFO.java, Analysis/TypeInference/ClassCone.java, Analysis/TypeInference/FieldType.java, Analysis/TypeInference/InterProc.java, Analysis/TypeInference/IntraProc.java, Analysis/TypeInference/SetHClass.java, Analysis/Transformation/MethodMutator.java, Analysis/Transformation/MethodSplitter.java, Analysis/Transformation/package.html, Analysis/Transactions/SimpleCheckOracle.java, Analysis/Transactions/SimpleFieldOracle.java, Analysis/Transactions/SyncTransformer.java, Analysis/Transactions/TreePostPass.java, Analysis/Transactions/package.html, Analysis/SizeOpt/Field2Method.java, Analysis/SizeOpt/FieldReducer.java, Analysis/SizeOpt/MZFChooser.java, Analysis/SizeOpt/MZFCompressor.java, Analysis/SizeOpt/MZFExternalize.java, Analysis/SizeOpt/MZFWidenType.java, Analysis/SizeOpt/MostlyZeroFinder.java, Analysis/SizeOpt/ProfileParser.java, Analysis/SizeOpt/SizeCounters.java, Analysis/SizeOpt/package.html, Analysis/Transactions/AnalysisCheckOracle.java, Analysis/Transactions/ArrayCopyImplementer.java, Analysis/Transactions/BitFieldNumbering.java, Analysis/Transactions/CheckOracle.java, Analysis/Transactions/CloneImplementer.java, Analysis/Transactions/DominatingCheckOracle.java, Analysis/Transactions/FieldOracle.java, Analysis/Transactions/GlobalFieldOracle.java, Analysis/Transactions/HoistingCheckOracle.java, Analysis/RoleInference/LocalVariableNamer.java, Analysis/RoleInference/RoleInference.java, Analysis/SizeOpt/BitWidthAnalysis.java, Analysis/SizeOpt/ConstructorClassifier.java, Analysis/Realtime/AllCheckRemoval.java, Analysis/Realtime/CheckAdder.java, Analysis/Realtime/CheckAdderNoSSA.java, Analysis/Realtime/CheckAdderWithTry.java, Analysis/Realtime/CheckRemoval.java, Analysis/Realtime/CheesyPACheckRemoval.java, Analysis/Realtime/ClassReplacer.java, Analysis/Realtime/HeapCheckAdder.java, Analysis/Realtime/NoHeapCheckRemoval.java, Analysis/Realtime/PACheckRemoval.java, Analysis/Realtime/PrintFactory.java, Analysis/Realtime/QuantaChecker.java, Analysis/Realtime/README, Analysis/Realtime/Realtime.java, Analysis/Realtime/RealtimeAllocationStrategy.java, Analysis/Realtime/RealtimeRuntime.java, Analysis/Realtime/SimpleCheckRemoval.java, Analysis/Realtime/Stats.java, Analysis/Realtime/ThreadToRealtimeThread.java, Analysis/Realtime/package.html, Analysis/Quads/SCC/SCCAnalysis.java, Analysis/Quads/SCC/SCCOptimize.java, Analysis/Quads/SCC/package.html, Analysis/Quads/ArrayInitRemover.java, Analysis/Quads/ArrayUnroller.java, Analysis/Quads/BasicCSE.java, Analysis/Quads/CallGraph.java, Analysis/Quads/CallGraphImpl.java, Analysis/Quads/CallGraphImpl2.java, Analysis/Quads/CoalescingToNoSSA.java, Analysis/Quads/CollectSyncStats.java, Analysis/Quads/ComponentOfReducer.java, Analysis/Quads/DeadCode.java, Analysis/Quads/DefiniteInitOracle.java, Analysis/Quads/DispatchTreeTransformation.java, Analysis/Quads/FieldSyncOracle.java, Analysis/Quads/InitializerTransform.java, Analysis/Quads/MayReadOracle.java, Analysis/Quads/MemoryOptimization.java, Analysis/Quads/MethodInliningCodeFactory.java, Analysis/Quads/MethodTraceFactory.java, Analysis/Quads/MustParamOracle.java, Analysis/Quads/NewMover.java, Analysis/Quads/Nonvirtualize.java, Analysis/Quads/QuadClassHierarchy.java, Analysis/Quads/QuadCounter.java, Analysis/Quads/QuadInterferenceGraph.java, Analysis/Quads/QuadLiveness.java, Analysis/Quads/SSIStats.java, Analysis/Quads/SSIToSSAMap.java, Analysis/Quads/SimpleConstMap.java, Analysis/Quads/SmallMethodInliner.java, Analysis/Quads/TypeInfo.java, Analysis/Quads/TypeSwitchRemover.java, Analysis/Quads/Unreachable.java, Analysis/Quads/package.html, Analysis/PreciseGC/AllocationHoisting.java, Analysis/PreciseGC/MRA.java, Analysis/PreciseGC/MRAFactory.java, Analysis/PreciseGC/WriteBarrierConstElim.java, Analysis/PreciseGC/WriteBarrierData.java, Analysis/PreciseGC/WriteBarrierPostPass.java, Analysis/PreciseGC/WriteBarrierPrePass.java, Analysis/PreciseGC/WriteBarrierQuadPass.java, Analysis/PreciseGC/WriteBarrierStats.java, Analysis/PreciseGC/WriteBarrierTreePass.java, Analysis/PointerAnalysis/ODMAInfo.java, Analysis/PointerAnalysis/ODNodeStatus.java, Analysis/PointerAnalysis/ODParIntGraph.java, Analysis/PointerAnalysis/ODParIntGraphPair.java, Analysis/PointerAnalysis/ODPointerAnalysis.java, Analysis/PointerAnalysis/PAEdge.java, Analysis/PointerAnalysis/PAEdgeSet.java, Analysis/PointerAnalysis/PAEdgeVisitor.java, Analysis/PointerAnalysis/PAEscapeFunc.java, Analysis/PointerAnalysis/PALoad.java, Analysis/PointerAnalysis/PANode.java, Analysis/PointerAnalysis/PANodeVisitor.java, Analysis/PointerAnalysis/PASync.java, Analysis/PointerAnalysis/PAThreadMap.java, Analysis/PointerAnalysis/PAWorkList.java, Analysis/PointerAnalysis/PAWorkSet.java, Analysis/PointerAnalysis/PAWorkStack.java, Analysis/PointerAnalysis/ParActionVisitor.java, Analysis/PointerAnalysis/ParIntGraph.java, Analysis/PointerAnalysis/ParIntGraphPair.java, Analysis/PointerAnalysis/PointerAnalysis.java, Analysis/PointerAnalysis/PointsToGraph.java, Analysis/PointerAnalysis/Stats.java, Analysis/PointerAnalysis/SyncElimination.java, Analysis/PointerAnalysis/AbstrPAEdgeSet.java, Analysis/PointerAnalysis/ActionRepository.java, Analysis/PointerAnalysis/ActionVisitor.java, Analysis/PointerAnalysis/AllocationNumbering.java, Analysis/PointerAnalysis/ArtificialTempFactory.java, Analysis/PointerAnalysis/Debug.java, Analysis/PointerAnalysis/EdgeOrdering.java, Analysis/PointerAnalysis/EdgesNCallees.java, Analysis/PointerAnalysis/InstrumentAllocs.java, Analysis/PointerAnalysis/InstrumentSyncOps.java, Analysis/PointerAnalysis/InterProcPA.java, Analysis/PointerAnalysis/InterThreadPA.java, Analysis/PointerAnalysis/LightPAEdgeSet.java, Analysis/PointerAnalysis/ListCell.java, Analysis/PointerAnalysis/MAInfo.java, Analysis/PointerAnalysis/Matching.java, Analysis/PointerAnalysis/MethodHole.java, Analysis/PointerAnalysis/MyAP.java, Analysis/PointerAnalysis/NodeRepository.java, Analysis/PointerAnalysis/ODInformation.java, Analysis/PointerAnalysis/ODInterProcPA.java, Analysis/MetaMethods/MetaMethod.java, Analysis/MetaMethods/SmartCallGraph.java, Analysis/Partition/Main.java, Analysis/Partition/Partition.java, Analysis/Partition/PartitionGraphViewer.java, Analysis/Partition/WGNode.java, Analysis/Partition/WeightedGraph.java, Analysis/Maps/ConstMapProxy.java, Analysis/Maps/DefaultMap.java, Analysis/Maps/Derivation.java, Analysis/Maps/ExactTypeMap.java, Analysis/Maps/ExactTypeMapProxy.java, Analysis/Maps/ExecMap.java, Analysis/Maps/ExecMapProxy.java, Analysis/Maps/InvariantsMap.java, Analysis/Maps/MapProxy.java, Analysis/Maps/SetTypeMap.java, Analysis/Maps/TypeMap.java, Analysis/Maps/TypeMapProxy.java, Analysis/Maps/UseDefMap.java, Analysis/MetaMethods/FakeMetaCallGraph.java, Analysis/MetaMethods/GenType.java, Analysis/MetaMethods/MetaAllCallers.java, Analysis/MetaMethods/MetaCallGraph.java, Analysis/MetaMethods/MetaCallGraphAbstr.java, Analysis/MetaMethods/MetaCallGraphImpl.java, Analysis/Maps/AllInductionsMap.java, Analysis/Maps/AllocationInformation.java, Analysis/Maps/BasicInductionsMap.java, Analysis/Maps/ConstMap.java, Analysis/LowQuad/Loop/AllInductions.java, Analysis/LowQuad/Loop/BasicInductions.java, Analysis/LowQuad/Loop/Induction.java, Analysis/LowQuad/Loop/LoopAnalysis.java, Analysis/LowQuad/Loop/LoopInvariance.java, Analysis/LowQuad/Loop/LoopMap.java, Analysis/LowQuad/Loop/LoopOptimize.java, Analysis/LowQuad/Loop/MyLowQuadNoSSA.java, Analysis/LowQuad/Loop/MyLowQuadSSI.java, Analysis/LowQuad/Loop/WorkTempMap.java, Analysis/LowQuad/Loop/package.html, Analysis/Loops/Loops.java, Analysis/Loops/package.html, Analysis/LowQuad/DerivationChecker.java, Analysis/LowQuad/package.html, Analysis/Instr/BasePointerPreservingUseDefer.java, Analysis/Instr/Check.java, Analysis/Instr/DemandDrivenRegAlloc.java, Analysis/Instr/EqTempSets.java, Analysis/Instr/GraphColoringRegAlloc.java, Analysis/Instr/HTempMap.java, Analysis/Instr/IgnoreSpillUseDefer.java, Analysis/Instr/InstrMOVEproxy.java, Analysis/Instr/LocalCffRegAlloc.java, Analysis/Instr/RegAlloc.java, Analysis/Instr/RegAllocOpts.java, Analysis/Instr/RegFile.java, Analysis/Instr/SpillHeuristics.java, Analysis/Instr/TempInstrPair.java, Analysis/Instr/Verify.java, Analysis/Instr/Web.java, Analysis/Instr/WeightedSet.java, Analysis/Instr/package.html, Analysis/Loops/LoopFinder.java, Analysis/Instr/AppelRegAlloc.java, Analysis/Instr/AppelRegAllocClasses.java, Analysis/Instr/AppelRegAllocFsk.java, Analysis/Instr/AppelRegAllocStd.java, Analysis/GraphColoring/AbstractGraph.java, Analysis/GraphColoring/Color.java, Analysis/GraphColoring/ColorFactory.java, Analysis/GraphColoring/ColorableGraph.java, Analysis/GraphColoring/ColorableGraphImpl.java, Analysis/GraphColoring/ColorableNode.java, Analysis/GraphColoring/DefaultSparseNode.java, Analysis/GraphColoring/DirectedGraph.java, Analysis/GraphColoring/EdgeNotPresentException.java, Analysis/GraphColoring/Graph.java, Analysis/GraphColoring/GraphColorer.java, Analysis/GraphColoring/GraphImpl.java, Analysis/GraphColoring/GraphVisualizer.java, Analysis/GraphColoring/IllegalEdgeException.java, Analysis/GraphColoring/NoFactorySetException.java, Analysis/GraphColoring/Node.java, Analysis/GraphColoring/NodeAlreadyColoredException.java, Analysis/GraphColoring/NodeNotColoredException.java, Analysis/GraphColoring/NodeNotPresentInGraphException.java, Analysis/GraphColoring/NodeNotRemovedException.java, Analysis/GraphColoring/ObjectNotModifiableException.java, Analysis/GraphColoring/OptimisticGraphColorer.java, Analysis/GraphColoring/SimpleGraphColorer.java, Analysis/GraphColoring/SparseGraph.java, Analysis/GraphColoring/SparseNode.java, Analysis/GraphColoring/UnableToColorGraph.java, Analysis/GraphColoring/UnboundedGraphColorer.java, Analysis/GraphColoring/WrongNodeTypeException.java, Analysis/GraphColoring/package.html, Analysis/EventDriven/AsyncCode.java, Analysis/EventDriven/BMethod.java, Analysis/EventDriven/CloningVisitor.java, Analysis/EventDriven/ContCode.java, Analysis/EventDriven/ContCodeNoSSA.java, Analysis/EventDriven/ContCodeSSI.java, Analysis/EventDriven/EventDriven.java, Analysis/EventDriven/EventDrivenCode.java, Analysis/EventDriven/LockRemove.java, Analysis/EventDriven/ToAsync.java, Analysis/DataFlow/ForwardDataFlowQuadVisitor.java, Analysis/DataFlow/InstrSolver.java, Analysis/DataFlow/LiveTemps.java, Analysis/DataFlow/LiveVars.java, Analysis/DataFlow/QuadEnumerator.java, Analysis/DataFlow/ReachingDefs.java, Analysis/DataFlow/ReachingHCodeElements.java, Analysis/DataFlow/ReversePostOrderEnumerator.java, Analysis/DataFlow/ReversePostOrderIterator.java, Analysis/DataFlow/Solver.java, Analysis/DataFlow/SpaceHeavyLiveTemps.java, Analysis/DataFlow/TreeSolver.java, Analysis/DataFlow/package.html, Analysis/EnvBuilder/EnvBuilder.java, Analysis/EnvBuilder/EnvCode.java, Analysis/DataFlow/BackwardDataFlowBasicBlockVisitor.java, Analysis/DataFlow/BackwardDataFlowQuadVisitor.java, Analysis/DataFlow/CachingLiveTemps.java, Analysis/DataFlow/DESIGN, Analysis/DataFlow/DataFlowBasicBlockVisitor.java, Analysis/DataFlow/DataFlowQuadVisitor.java, Analysis/DataFlow/ForwardDataFlowBasicBlockVisitor.java, Analysis/Counters/CounterFactory.java, Analysis/Counters/EpilogMutator.java, Analysis/Counters/RuntimeMethodCloner.java, Analysis/Counters/package.html, Analysis/ContBuilder/ContBuilder.java, Analysis/DefaultAllocationInformation.java, Analysis/DomFrontier.java, Analysis/DomTree.java, Analysis/EdgesIterator.java, Analysis/FCFGBasicBlock.java, Analysis/InterferenceGraph.java, Analysis/Liveness.java, Analysis/Place.java, Analysis/ReachingDefs.java, Analysis/ReachingDefsAltImpl.java, Analysis/ReachingDefsCachingImpl.java, Analysis/ReachingDefsImpl.java, Analysis/SESE.java, Analysis/SSxReachingDefsImpl.java, Analysis/TypeInfo.java, Analysis/UseDef.java, Analysis/UseDefChecker.java, Analysis/package.html, Analysis/AllCallers.java, Analysis/AllocationInformationMap.java, Analysis/BasicBlock.java, Analysis/BasicBlockFactoryInterf.java, Analysis/BasicBlockInterf.java, Analysis/BasicBlockInterfVisitor.java, Analysis/CallGraph.java, Analysis/ClassHierarchy.java, Analysis/CycleEq.java: Merge magic-2-0 branch back to HEAD. @MERGE: magic-2-0@ * .cvsignore: Merge magic-2-0 branch back to HEAD. * GNUmakefile, SELF-BUILDING, TODO, prj.el: Merge magic-2-0 branch back to HEAD. @MERGE: magic-2-0@ 2002-02-06 witchel * Analysis/Tree/DominatingMemoryAccess.java: Commit random permuter for DA register allocator. Take out an unnecessary call to DomTree. Boy, this checkin was a long time coming! 2002-01-16 bdemsky * ClassFile/Relinker.java: (cananian change) Reverted version 1.1.4.11, which commented out some code which was, indeed, needed. Added a comment to explain when it is used. 2002-01-09 salcianu * Util/LightBasicBlocks/LightBasicBlock.java, Util/BasicBlocks/BBConverter.java: Small changes 2002-01-02 bdemsky * Analysis/LowQuad/Loop/BasicInductions.java, Analysis/LowQuad/Loop/LoopAnalysis.java: fixes 2001-12-16 salcianu * Analysis/PointerAnalysis/NodeRepository.java, Analysis/PointerAnalysis/PointsToGraph.java: Inessential changes * Util/LightBasicBlocks/LBBConverter.java, Util/LightBasicBlocks/LightBasicBlock.java, Util/LightBasicBlocks/SCCLBBFactory.java: LightBasicBlock has been modified such that it can keep pred/succ according to the exceptional flow of execution (pred = protected basic blocks, succ = handlers protecting instrs. from this basic block) LightBasicBlock has been hacked in a quite nice way, instead of subclassing. * Util/BasicBlocks/BBConverter.java, Util/BasicBlocks/CachingBBConverter.java, Util/BasicBlocks/SCCBBFactory.java: For quad-with-try, BBConverter (and all the related classes) produce FCFGBasicBlock's. Minor changes. * Analysis/Realtime/CheesyPACheckRemoval.java, Analysis/Realtime/PACheckRemoval.java: Changes to comply with the change in the MetaCallGraphImpl interface. * Analysis/DataFlow/DataFlowBasicBlockVisitor.java: We now use BasicBlockInterfVisitor instead of BasicBlockVisitor. * Analysis/FCFGBasicBlock.java: Basic blocks for the Factored Control Flow Graph (implicit and factored treatment of exceptions). * Analysis/FCFGBasicBlock.java: New file. * Analysis/BasicBlock.java: BasicBlock.Factory now implements BasicBlockFactoryInterf. * Analysis/BasicBlockFactoryInterf.java: Interface defining the common behavious for a Factory of basic blocks (BasicBlockInterf's). BasicBlock.Factory and FCFGBasicBlock.Factory both implement it. * Analysis/BasicBlockFactoryInterf.java: New file. * Analysis/BasicBlockInterfVisitor.java, Analysis/BasicBlockVisitor.java: BasicBlockInterfVisitor replaces BasicBlockVisitor. The root of the hierarchy of basic block like classes is no longer BasicBlock (as John Whaley expected when he first wrote BasicBlock.java) but BasicBlockInterf. * Analysis/BasicBlockInterfVisitor.java: New file. * Analysis/BasicBlockInterf.java: The FCFGBasicBlock class (soon to be commited) is a basic block structure for the Factored Control Flow Graph (implicit and factored treatment of exceptions). As an FCFGBasicBlock is not a normal BasicBlock, I didn't want to subclass it from BasicBlock. Instead, I introduced an interface to capture the common traits of BasicBlocks and FCFGBasicBlocks. * Analysis/BasicBlockInterf.java: New file. 2001-12-15 salcianu * Util/Graph.java, Util/Util.java: A small change to make sure that the previously adverstised magic behaviour (read my previous commit message) actually happen in all cases. * Util/Graph.java: Added method printBBCFG. It produces a VCG-format of a (light) basic block CFG. It works with both CFG and Factored CFG (implicit and factored representation of exceptions). harpoon.Main.Graph was modified to use this method (in addition to its previous functionality). Type java harpoon.Main.Graph -pass to-quad BBCFG | xvcg - and something funny should happen (if you have vcg installed). * Main/EDMain.java, Main/EDXMain.java, Main/EventDriven.java, Main/Graph.java, Main/ODPAMain.java, Main/PAMain.java, Main/SAMain.java: Small modifications to comply with the latest change in the MetaCallGraphImpl class. * Analysis/MetaMethods/MetaCallGraphImpl.java: A minor change: MetaCallGraphImpl needs a CachingCodeFactory and not a BBConvertor. The BBConvertor was used just to obtain the underlying code factory. So, why not passing it directly? 2001-12-07 bdemsky * Analysis/LowQuad/Loop/BasicInductions.java: revert ovy's changes... 2001-12-06 C. Scott Ananian * Analysis/Quads/ComponentOfReducer.java: New file. * Analysis/Quads/ComponentOfReducer.java: The ComponentOfReducer pass converts some COMPONENTOF operations into more efficient INSTANCEOF operations. * Backend/Runtime1/TreeBuilder.java: Unify 'instanceof' implementation (both class and interface case) for INSTANCEOF and COMPONENTOF tests. We now re-use the same code instead of duplicating essentially identical tests in these two places. (This paves the way for unified optimizations of the interface instanceof test.) 2001-12-04 kkz * Analysis/PreciseGC/MRAFactory.java: Bug fix. Size of map may stay the same despite changes. 2001-11-27 bdemsky * Analysis/LowQuad/Loop/LoopOptimize.java: -l (loop optimization) works for "Hello World" now... Waiting for deadcode pass to be derivation safe... So right now deadcode is turned off... 2001-11-26 bdemsky * Analysis/LowQuad/Loop/MyLowQuadNoSSA.java, IR/Quads/RSSxToNoSSA.java: Fixed derivation information for newly created temps... * Analysis/LowQuad/Loop/LoopOptimize.java, Analysis/LowQuad/Loop/MyLowQuadNoSSA.java, Analysis/LowQuad/Loop/MyLowQuadSSI.java: Fixing derivation problems with Loop Optimizations...problems still remain, but getting closer to having a working pass... * Analysis/Loops/LoopFinder.java: bug sneaked past me first time...ovy should be happy now. 2001-11-20 bdemsky * Analysis/Loops/LoopFinder.java: Shame on Scott...breaking the Loop Analysis code... So the analysis calculates the header node...then scott's code calculates the incoming edges to the header node using the CFGrapher...all is good, except the root loop has no incoming edges to the header node. Then scott's rewritten loopentrance code calls this and looks for destinations of these edges... 2001-11-20 ovy * Analysis/LowQuad/Loop/BasicInductions.java, Analysis/LowQuad/Loop/LoopAnalysis.java: Fixed two bugs in induction analysis and for-loop analysis, probably caused by code rot. -- Ovy 2001-11-19 C. Scott Ananian * ClassFile/Relinker.java: Potential sketch: un-do a hack added to the relinker when too many class/field/method equality tests depended on reference-equality. The unwrapped version of a field should almost always be the proxy. Previously, we'd try to use the 'linker' version of the proxy class when we had a local mutated version of an originally linked class. But this fails horribly when we create new classes that don't exist in the original linker. We shouldn't need to 'pretend' we've got the originally-linked class anymore. Leaving the code commented-out (instead of outright deleted) just in case there's some subtle gotcha that I'm forgetting to account for. * Main/SAMain.java: Tweak the root-set if 'mzf.compressor' is turned on. * Analysis/SizeOpt/MZFCompressor.java, Analysis/SizeOpt/MZFWidenType.java: MZFCompressor: make a better effort never to call 'convert()' on an uncallable method. Also, keep track of 'mentioned classes'. MZFWidenType: add code to widen the parameter and return types of all callable methods, and widen the declared types of all fields. This ensures proper type-safety after we've split our classes. * Analysis/SizeOpt/ConstructorClassifier.java: Add statistics code to print out some basic static statistics on the number and types of static specializations performed (these are numbers used in the PLDI'02 paper). * Runtime/MZFExternalMap.java: Make all operations on MZFExternalMap synchronized for safety when transforming multi-threaded code. * Backend/Runtime1/mzf-unsafe.properties: Add java.io.File (for 'path' field) and java.lang.ThreadGroup (because of compiled-in mentions in descriptors) to list of classes which are unsafe for us to mzf-optimize. * Analysis/SizeOpt/MZFExternalize.java: Actually turn on the field-removal code in MZFExternalize (otherwise our size statistics won't show any benefit!) * Analysis/SizeOpt/MZFChooser.java: Bug fix: we can't discriminate constructors which define fields as a simple function of the 'this' pointer, because at the point the discrimination needs to be done, 'this' isn't defined yet. 2001-11-14 C. Scott Ananian * Analysis/Counters/RuntimeMethodCloner.java, Main/SAMain.java: Bug fix: the harpoon.Analysis.Counters.RuntimeMethodCloner makes static methods out of virtual ones. When it does this, the type analysis passes no longer "know" that parameter #0 is 'this' and thus guaranteed non-null. They they complain that they can't prove that all the necessary null-checks are being done. We now add a null check to the cloned methods to fix this problem. (In doing so, we no longer can accept SSI form input to the CounterFactory; so a slight tweak to Main/SAMain was needed to give it QuadNoSSA instead.) * ClassFile/HFieldProxy.java, ClassFile/HMethodProxy.java: Be more careful about calling flushMemberMap() and updateMemberMap() when the underlying proxy's hashcode may change. In particular, we were forgetting to do this for the FieldMutator.setType() method. I also wrapped the final updateMemberMap() invocations in a finally clause, to ensure that they happen even if the underlying mutator flags an error of some sort (like a 'DuplicateMethodException', for instance). This seems to be sufficient to guarantee that HFieldProxy and HMethodProxy objects are reference-unique. * Analysis/SizeOpt/MZFCompressor.java: Be more careful about only pulling callable methods through the code factories. When chaining after FieldReducer (or any transformation which removes methods/fields) things start to break if we try to pull brand new code straight from disk all the way through the code factory path: fields and methods fail to resolve when read in from the bytecode file, for instance. We now maintain our own 'callable' Set which we can add our 'new' methods to as we create them. * Analysis/SizeOpt/MZFExternalize.java: Enable setting the 'MZF external hash map' threshold using system property harpoon.sizeopt.mzf.threshold. Default is 75%; i.e. it takes fields where more than 75% of the allocated objects have a single constant value for the field. Setting above 100% will effectively disable this transformation. * Analysis/SizeOpt/ConstructorClassifier.java, Main/SAMain.java: ConstructorClassifier now uses SimpleConstMap instead of SCCAnalysis --- which means it now also runs correctly after the BitwidthAnalysis optimizer has hyper-optimized everything. * Analysis/SizeOpt/BitWidthAnalysis.java: Print out number of classes in the class hierarchy along with all the other bitwidth statistics. We need this number to determine how effecting claz compression would be. * Analysis/Quads/SimpleConstMap.java: Add a very simple implementation of ConstMap which works just as well as SCCAnalysis as long as the HCode has been put through SCCOptimize at some point in the past. * Analysis/Quads/SimpleConstMap.java: New file. * Analysis/SizeOpt/MZFExternalize.java: Bug-fix: the INSTANCEOF test in the getter's type-check must be protected from null! We also add a pair of assertions to guarantee that the form we are creating is in fact QuadRSSx. * Main/JMain.java, IR/Quads/ReHandler.java, IR/Quads/ReHandlerToSSA.java, Analysis/LowQuad/Loop/LoopAnalysis.java, Analysis/LowQuad/Loop/LoopOptimize.java: Rename harpoon.Analysis.SSITOSSAMap to harpoon.Analysis.Quads.SSIToSSAMap. @RENAME: Analysis/SSITOSSAMap Analysis/Quads/SSIToSSAMap@ * Analysis/Quads/SSIToSSAMap.java: New file. * Analysis/Quads/SSIToSSAMap.java, Analysis/SSITOSSAMap.java: Rename harpoon.Analysis.SSITOSSAMap to harpoon.Analysis.Quads.SSIToSSAMap. @RENAME: Analysis/SSITOSSAMap Analysis/Quads/SSIToSSAMap@ * Analysis/SizeOpt/ConstructorClassifier.java: Change 'SCCAnalysis' declaration in makeClassification() routine to just plain 'ConstMap', in preparation for replacement of SCCAnalysis with a SimpleConstMap. See -- after we run the bitwidth pass, the program has been super-optimized to the point where SCCAnalysis can't reconstruct all the invariants which it knows ought to be true. So it chokes and dies when run in ConstructorClassifier. I could loosen the checks in SCCAnalysis, but I prefer to use a simpler implementation of ConstMap instead -- all the constants should have been made manifest as CONSTs by the bitwidth pass, anyway. * Analysis/SizeOpt/BitWidthAnalysis.java, Analysis/Quads/SCC/SCCAnalysis.java: Parallel changes to SCCAnalysis and BitWidthAnalysis: the raiseE logic was *still* slightly wrong! As written it would infinite loop whenever the program had a PHI edge which led to itself. The rewrite should fix all known problems with raiseE (I sure hope!). * Analysis/SizeOpt/MZFCompressor.java, Analysis/SizeOpt/MZFExternalize.java: Add 'MZFExternalize' class which transforms fields into references to an external hashmap (the interface to which is defined in Runtime/MZFExternalMap). One-line change to MZFCompressor to turn this functionality on. * Analysis/SizeOpt/MZFExternalize.java: New file. * Runtime/MZFExternalMap.java: Add 'MZFExternalize' class which transforms fields into references to an external hashmap (the interface to which is defined in Runtime/MZFExternalMap). One-line change to MZFCompressor to turn this functionality on. * Runtime/MZFExternalMap.java: New file. * Analysis/SizeOpt/MZFCompressor.java, Analysis/SizeOpt/ProfileParser.java: Extended ProfileParser so that it can tell us the percentage of fields which always contain the given 'mostly' value. Interface changes mean that tweaks to MZFCompressor are needed, as well. * IR/Quads/QuadNoSSA.java: Reworked QuadNoSSA so that its constructors only pay attention to the codename of the given Code -- it no longer requires you to cast to one of the canonical subclasses of Code (QuadWithTry, QuadNoSSA, etc). This continues my effort to make it easier to implement polymorphic transformations (transformations which always yield the same form of output as they are given as input, for example). You really shouldn't have to subclass QuadRSSx (for example) to create your own Code -- it should suffice to subclass Code and declare your form with an appropriate returned string from Code.getName(). 2001-11-13 C. Scott Ananian * Analysis/SizeOpt/ProfileParser.java: Don't abort if we don't find a field: it could just mean that the Bitwidth analysis has gotten to it before us and removed it. Print a message to stderr, so we know what's going on, but continue as if nothing was wrong. * Main/SAMain.java, bin/build-spec: Require 'mzf.compressor=true' property before turning on the MZFCompressor, and tweak build-spec to automagically include mzf profiling data on the command-line if it finds an appropriately-named profile file. * Analysis/SizeOpt/MZFCompressor.java: MZFCompressor needs to move static initializers to the top-most class, or they will not be run when needed. * Main/SAMain.java: Add NewMover. Add system property to turn on MZF profile-guided transformations. * Analysis/SizeOpt/MZFCompressor.java: bug fix: pull everything through the ConstructorClassifier before we start messing with the classes. Otherwise we get "mysterious" bugs due to the ConstructorClassifer working with inconsistent versions of the code. * Main/SAMain.java: Add code to allow us to emit code for classes with very long names. Previously, the 'new FileWriter' call would throw a FileNotFoundException when the filename was too long (filenames are created from class names; long class names produce long file names) and compilation would halt. Now we catch that exception and attempt to substitute a shorter (but still unique) name. This would be easier if Sun's 'File.createTempFile' method worked as the documentation says it does; see code comments for more info. Also added a little bit more information on the problem to the error message printed when file output fails. * Analysis/SizeOpt/ProfileParser.java: I accidentally checked in a JDK1.4-ism: there's a RuntimeException constructor in 1.4 which takes a java.lang.Throwable as an argument, but all previous JDK's just have the takes-a-String constructor. Add a call to .toString() so that we compile everywhere. * Analysis/SizeOpt/MZFCompressor.java: Bug fix: instead of copying the interfaces from the *old* class to the *new* class, we were copying them from the new class to the new class. Oops. Three-character fix. * Backend/Runtime1/mzf-unsafe.properties: Add java.io.FileInputStream to the list of classes *not* to try to mzf-optimize: the 'fd' field really is needed, although all of its uses are in native code. * Analysis/SizeOpt/MZFChooser.java: Complete implementation of MZFChooser. We now handle both constant and 'known to be a parameter' cases. Input is SSA, output is RSSx. * Analysis/SizeOpt/MZFCompressor.java: Turn on MZFWidenType. Wrap the codefactory produced in a CachingCodeFactory just to be on the safe side (since many of the transformations are not idempotent). Make the widen() and wrap() methods non-private so that MZFChooser can share them. * Analysis/SizeOpt/MZFWidenType.java: Add new 'MZFWidenType' class to correct 'instanceof'-type problems that resulted from splitting types. If we had a (x instanceof Foo) expression and then Foo was split into Foo$2, Foo$1, and Foo (where Foo inherits from Foo$1 which inherites from Foo$2), then the instanceof statement needs to be transformed into (x instanceof Foo$2) to allow us to choose to instantiate any one of the split types. Likewise for TYPESWITCH, and ANEW operations must also be modified in the same way to ensure that an array formerly of type Foo[] be able to hold items of type Foo$1 and Foo$2 as well. * Analysis/SizeOpt/MZFWidenType.java: New file. * Analysis/SizeOpt/ConstructorClassifier.java: Bug-fix: don't modify 'classification' values in Map after we recursively invoke 'classifyMethod()'. Make our own copies of the Classification object! [This fixes problem where a method which invoked a 'this' constructor would get mixed up with the method it invoked.] * Analysis/SizeOpt/MZFChooser.java: New file. * Analysis/SizeOpt/MZFChooser.java, Analysis/SizeOpt/MZFCompressor.java: Start work on the transformation to use the split types generated by MZFCompressor. Fix bug where constructors-that-aren't-HConstructors were ending up in the wrong class. * Analysis/SizeOpt/ConstructorClassifier.java: Add accessor methods for the analysis results. Also make ConstructorClassifier deal with 'null' constants better. 2001-11-12 C. Scott Ananian * Analysis/SizeOpt/MZFCompressor.java, Backend/Runtime1/mzf-unsafe.properties: Add a stop-list for classes which we can't mess with without disturbing the runtime. Tweak the naming of the split classes a bit. Don't move static methods---it's unnecessary and screws with JNI method naming. These changes suffice to compile and run 'Hello, world' successfully. * Backend/Runtime1/mzf-unsafe.properties: New file. * Analysis/SizeOpt/MZFCompressor.java: Finish initial implementation of MZFCompressor. It now actually splits fields as it should. =) * ClassFile/Relinker.java: Add 'move()' method to Relinker which allows you to easily move fields and methods from one class to another (transparently updating all existing references to the fields/methods). Also fix a buglet in Relinker.makeArray() where it was impossible to create arrays of class types created by 'createMutableClass()'. * Backend/Runtime1/DataInterfaceList.java: Make sure interface list has no duplicates. (It's not a problem if it does, but it wastes space.) * Analysis/SizeOpt/Field2Method.java: Export the getter/setter-to-field maps (and their inverses), as unmodifiable maps. * ClassFile/HConstructorProxy.java, ClassFile/HFieldProxy.java, ClassFile/HInitializerProxy.java, ClassFile/HMemberProxy.java, ClassFile/HMethodProxy.java: Bug fix: 'HMemberProxy's shouldn't change their hashcode when they are relinked (otherwise the relinked members will get lost in any hashtables they are present in). 2001-11-11 kkz * Analysis/PreciseGC/AllocationHoisting.java, Analysis/PreciseGC/MRAFactory.java, Analysis/PreciseGC/WriteBarrierQuadPass.java, Main/SAMain.java: Added dynamic dispatch handling to the anaylsis and added option switches to make it easier to run benchmarks. 2001-11-11 C. Scott Ananian * Analysis/SizeOpt/MZFCompressor.java: MZFCompressor now uses the new Field2Method transformer. * Analysis/SizeOpt/Field2Method.java: Add new 'Field2Method' transformation which turns GET/SET operations on specified fields into calls to accessor (getter/setter) methods. * Analysis/SizeOpt/Field2Method.java: New file. * Util/Collections/AggregateMapFactory.java: Bug fixes for AggregateMap: throw NoSuchElementException when appropriate in entrySet().iterator().next() method; fix implementation of entrySet().remove() (size and list weren't being updated). * IR/LowQuad/LowQuadSSI.java, Analysis/Quads/TypeInfo.java: Removed 'QuadSSI' type-casts, to allow these classes to play nicer with *any* subclass of harpoon.IR.Quads.Code which reports its 'code name' to be "quad-ssi". This makes it easier to implement analyses/transformations which work on more than one code type. 2001-11-10 kkz * Analysis/PreciseGC/WriteBarrierTreePass.java: Fix for bug. After constant propagation, some parameters are constants instead of TEMPs. * Backend/PreciseC/TreeToC.java: Changes to try to get inlined write barriers. * Analysis/PreciseGC/AllocationHoisting.java, Analysis/PreciseGC/MRA.java, Analysis/PreciseGC/MRAFactory.java, Analysis/PreciseGC/WriteBarrierQuadPass.java, Main/SAMain.java: Snapshot of working analysis. 2001-11-10 C. Scott Ananian * Analysis/SizeOpt/ConstructorClassifier.java, Analysis/SizeOpt/MZFCompressor.java, Analysis/SizeOpt/ProfileParser.java: Add interrogation methods to ProfileParser and ConstructorClassifier (also turn off debugging dump in ConstructorClassifier). Add beginnings of new MZFCompressor class which will use the MZF profiling information to optimize out mostly-zero fields. Right now all it does is sort the profiling information to determine the order in which fields ought to be 'compressed' and what value they 'mostly' have. * Analysis/SizeOpt/MZFCompressor.java: New file. 2001-11-09 C. Scott Ananian * Util/ParseUtil.java: A little better input checking in ParseUtil; also make BadLineException constructor public like it should be! * Analysis/SizeOpt/ProfileParser.java: Add a class to parse the output of the SizeCounters statistics code, to guide the operation of the (to-be-written) MZFCompressor transformation. * Analysis/SizeOpt/ProfileParser.java: New file. * Analysis/Quads/NewMover.java: Don't move NEWs past SIGMAs by default. (This can create more than one NEW corresponding to a single constructor invocation, which may very well confuse people.) * Analysis/Quads/DefiniteInitOracle.java, Analysis/Quads/MayReadOracle.java: The evil optimizations to make the benchmarks work out nicely begin. This check-in adds a gnarly special case to the MayReadOracle to help improve the accuracy of DefiniteInitOracle. Basically, you can have constructors of the form: (this example taken from _202_jess) Token(Token t) { this.tag = t.tag; ... } The MayReadOracle normally says that field 'Token.tag' is "possibly read" before the write to 'this.tag'. However, in this case we know that 't.tag' is not a write to 'this.tag' because no parameters to a constructor can be 'this' (or an alias) (excluding the very first, hidden, parameter, which is *always* 'this'). So now MayReadOracle has a 'specialHandlingForConstructors' mode where it ignores writes to fields whose object ref *must* be a non-'this' parameter. This mode probably isn't useful for anything but DefiniteInitOracle --- but that's alright, turn it off if you don't need it. * Analysis/Quads/MustParamOracle.java: Add a toString() method to facilitate debugging. * Analysis/SizeOpt/ConstructorClassifier.java: Bug fix: forgot to map parameters to 'this()' constructor invocation to the parameters of the caller (parameter #1 of the callee is not necessarily parameter #1 of the caller, etc). * Analysis/SizeOpt/ConstructorClassifier.java: Update ConstructorClassifier to collect per-field information on whether a specific constructor initializes the field with a constant, a method parameter, never initializes it, or "does something else". No public interrogation methods yet; not sure yet the best way to query the data. I'll write the query methods as I write the class transformation routine that will use them. * Analysis/SizeOpt/SizeCounters.java: Bug-fix: size counters was using wrong counter names for the rounded unread/const fields tallies. 2001-11-08 C. Scott Ananian * Analysis/Quads/MustParamOracle.java: The MustParam analysis isn't terribly useful unless its query methods are public. This commit makes them public. * Analysis/SizeOpt/ConstructorClassifier.java: First commit of a new pass to identify whether certain constructors are amenable to mostly-zero field transformations. In particular, we're looking for fields which aren't written outside of the constructor, where we can prove that the value written in the constructor is either a constant, or always the same as one of the constructor parameters. Right now all this class does is identify 'subclass final' fields (definition of this term is included in the class). I'm checking it in because I'm going home and want to transfer my work to the laptop. =) * Analysis/SizeOpt/ConstructorClassifier.java: New file. * Util/Collections/GenericMultiMap.java: GenericMultiMap was wasting most of the benefits obtained by things like the BitSetFactory by iterating over elements *itself* do implement methods like 'addAll'. I suspect I broke this while trying to add the size field to the code, sigh. Well, I've fixed it now. We use operations on collections as much as possible to get the speed gains. Also fixed the implementation of 'equals' when passed 'null'. * Analysis/Quads/NewMover.java: Extend NewMover so that it can push NEWs past SIGMAs. * Util/Collections/GenericMultiMap.java: Remove unused 'size' field; fix 'isEmpty()' implementation. * Util/Collections/GenericMultiMap.java: Bug fixes to GenericMultiMap: first, the size() method could be very wrong as we can't intercept direct modifications to the Collections returned by getValues(key). I introduced this bug on 2001-11-04, sorry about that. Second, the EntrySet() and values() iterators could terminate too soon because of an 'if' which should have been a 'while'. This was another November 4th bug. It just wasn't my day, apparently. * Analysis/Quads/NewMover.java: Bug-fix: NewMover didn't deal with METHOD quads with arity>1. Fixed now. At this point, the code is at the 'runs Hello world' stage. It does very well for expressions like 'new HashSet(new TreeSet(new HashSet()))' but (because it doesn't move NEWs past SIGMAs) doesn't optimize 'new Integer( cond ? x : y )' the way it could. * Util/Collections/GenericInvertibleMultiMap.java: Bug-fix: GenericInvertibleMultiMap would throw a ConcurrentModificationException if you called the 'remove' method on a key with more than one element in its value set. Simple fix. * Analysis/Quads/NewMover.java: Better handling of MOVEs in NewMover: the last committed version tended to let the MOVEs slip too far (out of a handler block, for instance). Now we always dump all associated MOVEs at the same point we cough up the NEW. Also broke the state information apart from the MoveVisitor traversal information. * IR/Quads/Quad.java: Have Quad.remove() return the edge which spans the now-removed quad (since if you need this, it is very difficult to get otherwise). This is consistent now with the interface to Quad.addEdge(). Of course, you can ignore the return value if you like. =) * Main/Options.java, Analysis/Quads/NewMover.java: Add the 'NewMover' transformation, which attempts to move NEW quads as close as possible to the invocation of their constructor. It is useful when transforming classes and constructors or (when doing gc-related analyses) for making the 'this' object more likely to be 'most-recently allocated'. * Analysis/Quads/NewMover.java: New file. 2001-11-07 C. Scott Ananian * Util/Collections/TestSet.java: Extend TestSet to be a much more complete test of the Set functionality. Now this class (correctly) discovers that UniqueVector, UniqueStack, and BitSetFactory implement Sets which don't adhere to the java.util.Set specification for the behavior of equals() and hashCode(). There is no way that UniqueVector and UniqueStack can adhere to the interfaces of *both* List *and* Set simultaneously. This is a bug in the Java Collections API, according to me. * Util/Collections/BitSetFactory.java: Bug this in BitSetFactory.equals() -- no longer throws NullPointerException if you give it a 'null' (returns 'false' as it should). There are other problems with this method, though: it doesn't accept *any* java.util.Set, like the Set interface contract says it should. * Util/Collections/TestSet.java: Oops: TestSet shouldn't be public. * Util/Collections/TestSet.java: Removed 'import *'. * Util/Collections/AggregateMapFactory.java, Util/Collections/BinaryHeap.java, Util/Collections/BinomialHeap.java, Util/Collections/Factories.java, Util/Collections/FibonacciHeap.java, Util/Collections/GenericMultiMap.java, Util/Collections/TestMap.java, Util/Default.java, Tools/Annotation/Java12.cup, Main/CHStats.java, Main/CallGraph.java, Main/EDMain.java, Main/EDXMain.java, Main/EventDriven.java, Main/JMain.java, Main/ODPAMain.java, Main/PAMain.java, Main/TypesMain.java, IR/Tree/ToTreeHelpers.java, IR/Quads/TESTER.java, IR/Quads/ToNoSSA.java, IR/Quads/Translate.java, IR/Quads/Pattern.java, IR/Quads/Peephole.java, IR/Quads/RSSxToNoSSA.java, IR/Quads/ReHandler.java, IR/Quads/SSIRename.java, IR/Quads/SSIToSSA.java, IR/Jasmin/Jasmin.java, IR/Bytecode/Liveness.java, ClassFile/HClass.java, ClassFile/HClassImpl.java, ClassFile/HClassProxy.java, Backend/Runtime1/DataInterfaceList.java, Backend/Maps/CHFinalMap.java, Backend/CSAHack/RegAlloc/Liveness.java, Backend/CSAHack/RegAlloc/RegAlloc.java, Backend/Analysis/BasicGCInfo.java, Backend/Analysis/InitializerOrdering.java, Backend/Analysis/InterfaceMethodMap.java, Backend/Analysis/MakeGCThreadSafe.java, Analysis/TypeInference/ClassCone.java, Analysis/TypeInference/IntraProc.java, Analysis/Tree/CacheEquivalence.java, Analysis/Tree/JumpOptimization.java, Analysis/Transformation/MethodSplitter.java, Analysis/Transactions/GlobalFieldOracle.java, Analysis/SizeOpt/BitWidthAnalysis.java, Analysis/Quads/SCC/SCCAnalysis.java, Analysis/RoleInference/RoleInference.java, Analysis/Quads/BasicCSE.java, Analysis/Quads/CallGraphImpl.java, Analysis/Quads/CallGraphImpl2.java, Analysis/Quads/CoalescingToNoSSA.java, Analysis/Quads/DeadCode.java, Analysis/Quads/FieldSyncOracle.java, Analysis/Quads/InitializerTransform.java, Analysis/Quads/MayReadOracle.java, Analysis/Quads/MemoryOptimization.java, Analysis/Quads/QuadClassHierarchy.java, Analysis/Quads/QuadLiveness.java, Analysis/Quads/TypeInfo.java, Analysis/Quads/Unreachable.java, Analysis/PreciseGC/MRAFactory.java, Analysis/PointerAnalysis/InstrumentAllocs.java, Analysis/PointerAnalysis/MAInfo.java, Analysis/PointerAnalysis/ODMAInfo.java, Analysis/LowQuad/Loop/AllInductions.java, Analysis/LowQuad/Loop/BasicInductions.java, Analysis/LowQuad/Loop/LoopAnalysis.java, Analysis/LowQuad/Loop/LoopInvariance.java, Analysis/LowQuad/Loop/LoopMap.java, Analysis/LowQuad/Loop/LoopOptimize.java, Analysis/Loops/LoopFinder.java, Analysis/Loops/Loops.java, Analysis/Instr/GraphColoringRegAlloc.java, Analysis/Instr/RegAlloc.java, Analysis/Instr/RegFile.java, Analysis/GraphColoring/GraphImpl.java, Analysis/GraphColoring/SparseGraph.java, Analysis/GraphColoring/SparseNode.java, Analysis/Instr/EqTempSets.java, Analysis/EventDriven/AsyncCode.java, Analysis/EventDriven/CloningVisitor.java, Analysis/EventDriven/EventDriven.java, Analysis/EventDriven/LockRemove.java, Analysis/EventDriven/ToAsync.java, Analysis/GraphColoring/Graph.java, Analysis/EnvBuilder/EnvBuilder.java, Analysis/AllCallers.java, Analysis/BasicBlock.java, Analysis/ClassHierarchy.java, Analysis/DataFlow/InstrSolver.java, Analysis/DataFlow/Solver.java, Analysis/DataFlow/TreeSolver.java, Analysis/DomFrontier.java, Analysis/EdgesIterator.java, Analysis/Place.java, Analysis/ReachingDefsAltImpl.java, Analysis/ReachingDefsImpl.java, Analysis/SSITOSSAMap.java: Changes to import statements necessary after the great Renaming Of Many Classes from the harpoon.Util to the harpoon.Util.Collections package. It's so nice to have sed working for me to make these changes. * Util/Collections/AbstractMapEntry.java, Util/Collections/DisjointSet.java, Util/Collections/Environment.java, Util/Collections/HashEnvironment.java, Util/Collections/LinearMap.java, Util/Collections/PairMapEntry.java, Util/Collections/PersistentEnvironment.java, Util/Collections/PersistentMap.java, Util/Collections/PersistentSet.java, Util/Collections/PersistentTreeNode.java, Util/Collections/UniqueStack.java, Util/Collections/UniqueVector.java, Util/Collections/WorkSet.java: Moved many collections-related classes from the harpoon.Util package to the harpoon.Util.Collections package. There's lots still left in harpoon.Util, but every little bit helps. This is motivated by finding out that Felix didn't find the DisjointSet when he apparently looked for it in harpoon.Util.Collections; now it will be where he was apparently expecting it. The next commit will contain the associated changes to all the files which mention these. Classes moved: Environment, HashEnvironment, PersistentEnvironment, DisjointSet, LinearMap, WorkSet, UniqueStack, UniqueVector, AbstractMapEntry, PairMapEntry, PersistentMap, PersistentSet, PersistentTreeNode. @RENAME: Util/ Util/Collections/@ * Util/Collections/AbstractMapEntry.java, Util/Collections/DisjointSet.java, Util/Collections/Environment.java, Util/Collections/HashEnvironment.java, Util/Collections/LinearMap.java, Util/Collections/PairMapEntry.java, Util/Collections/PersistentEnvironment.java, Util/Collections/PersistentMap.java, Util/Collections/PersistentSet.java, Util/Collections/PersistentTreeNode.java, Util/Collections/UniqueStack.java, Util/Collections/UniqueVector.java, Util/Collections/WorkSet.java: New file. * Util/AbstractMapEntry.java, Util/DisjointSet.java, Util/Environment.java, Util/HashEnvironment.java, Util/LinearMap.java, Util/PairMapEntry.java, Util/PersistentEnvironment.java, Util/PersistentMap.java, Util/PersistentSet.java, Util/PersistentTreeNode.java, Util/UniqueStack.java, Util/UniqueVector.java, Util/WorkSet.java: Moved many collections-related classes from the harpoon.Util package to the harpoon.Util.Collections package. There's lots still left in harpoon.Util, but every little bit helps. This is motivated by finding out that Felix didn't find the DisjointSet when he apparently looked for it in harpoon.Util.Collections; now it will be where he was apparently expecting it. The next commit will contain the associated changes to all the files which mention these. Classes moved: Environment, HashEnvironment, PersistentEnvironment, DisjointSet, LinearMap, WorkSet, UniqueStack, UniqueVector, AbstractMapEntry, PairMapEntry, PersistentMap, PersistentSet, PersistentTreeNode. @RENAME: Util/ Util/Collections/@ * Support/rmi-root-set: Add trailing newline to this file to make editors happier. * GNUmakefile: Tweaks so that 'make java' works better. * Main/SAMain.java, Analysis/SizeOpt/MostlyZeroFinder.java: Extend mostly-zero finder so that it can find other small constants if given a 'harpoon.mzf.lookfor' property. * Util/Collections/TestSet.java: Add a very small tester for Set implementations. * Util/Collections/TestSet.java: New file. * Util/Collections/DisjointSetStructure.java, Util/Collections/LLDisjointSetStructure.java: Removed Felix's DisjointSetStructure class (and LLDisjointSetStructure implementation) since: 1) he never used these classes anywhere in the FLEX codebase. 2) harpoon.Util.DisjointSet was written six months before his versions, has a much cleaner interface, and implements the complete CLR algorithm. * Util/Collections/TestMap.java: New file. * Util/Collections/MapTest.java, Util/Collections/TestMap.java: Renamed 'MapTest' to 'TestMap' so that all the testing classes would end up listed together alphabetically. @RENAME: MapTest TestMap@ * Analysis/Quads/MustParamOracle.java: Remove 'import *' statements. * Analysis/Quads/DefiniteInitOracle.java: Removed now-unused isSafe() methods from DefiniteInitOracle. * Analysis/Quads/DefiniteInitOracle.java, Analysis/Quads/MustParamOracle.java: Factor out 'must be this' analysis into separate module 'MustParamOracle'. The MustParamOracle actually works for *any* parameter (not just parameter 0, which is 'this') and is thus useful for analyses other than the DefiniteInitOracle. * Analysis/Quads/MustParamOracle.java: New file. * Analysis/Quads/DefiniteInitOracle.java: Make DefiniteInitOracle much more precise (and useful!) by using the new MayReadOracle to better eliminate definite initializations of fields which may have already been read. Our exit point code is now drastically simplified: only RETURNs are exit points (the CALL nastiness is taken care of by MayRead, which consults a FieldSyncOracle for the interprocedural information). * Analysis/Quads/FieldSyncOracle.java: Add facility to query entire *sets* of fields read/written as well as individual fields. This makes it more useful to outside analyses (in particular, the MayReadOracle). * Analysis/Quads/MayReadOracle.java: Add a new 'may-read' analysis, which will tell you which fields have possibly been read before a given edge in a cfg. This allows you to determine (for example) that a given value written to a field in a constructor is actually the *first* value of the field which is visible. * Analysis/Quads/MayReadOracle.java: New file. * Analysis/SizeOpt/BitWidthAnalysis.java: Make BitWidthAnalysis quieter about finding definitely initialized fields. * Analysis/SizeOpt/SizeCounters.java: Add better counters for unread and constant fields identified by the BitWidthAnalysis. * GNUmakefile: Cleaned up 'doc' building rules. 'doc-install' target no longer uses scp, since this seems to have stopped working on lm. * Analysis/Quads/CallGraph.java: Fix typo in javadoc. * Analysis/Quads/FieldSyncOracle.java: Make FieldSyncOracle public, since it's so gosh-darn useful. 2001-11-06 C. Scott Ananian * Analysis/Quads/DefiniteInitOracle.java: calls to methods which are guaranteed not to read (directly or indirectly) any fields in the current class are now not exit points. * Analysis/SizeOpt/SizeCounters.java: size counters was forgetting to take into account fields which we've determined are constant or unread! * Analysis/Quads/DefiniteInitOracle.java: Improvements/bug-fixes to DefiniteInitOracle: bug-fix in findThisVars that was causing the set of thisvars to always be empty -- basically we were treating the definition of the canonical 'this' in the METHOD quad as a destructive definition of a not-this variable. Oops. Rearranged the iteration code at the end so that it's a while instead of a do-while loop. This was just a clean-up. Improvements to findNextExitPoint: THROWs are not exit points, since the constructor does not complete successfully. Neither are CALLs to 'this' or 'super' constructors. Improvements to findDefInit: a call to a 'this' constructor is a definite initialization of all the fields which that constructor definitely initializes (recursive invocation of the analysis). We changed factored out a 'getNotDefInit' method and had it cache its results to make the recursive invocation work best. * IR/Quads/UnHandler.java: Optimized the translation of INSTANCEOF's null-check to aid analysis. Before, we were merging the boolean result of the instanceof, resulting in an 'unknown' value in SCC-type analyses. Now we try to directly dispatch instead, creating SIGMA functions wherein we can embed the information discovered by the INSTANCEOF. On the true edge we should now be able to tell that the variable tested is both non-null and has the desired type. * Analysis/SizeOpt/BitWidthAnalysis.java: Narrow type of 'this' for virtual method calls. * GNUmakefile: Don't force ssh version 1 any more, because lm doesn't support it. * Analysis/Quads/DefiniteInitOracle.java: Two bug fixes for DefiniteInitOracle: first: split constructors generated by the initializer-transform were fooling us. we'd see no constructors for a type (and thus, paradoxically, conclude that all fields were definitely initialized) because all the constructors had been split to execute in class initializers. second: I forgot to remove the notthisvars set from thisvars before returning it. oops. 2001-11-05 C. Scott Ananian * Analysis/SizeOpt/BitWidthAnalysis.java, Analysis/Quads/DefiniteInitOracle.java: Add an analysis to look for 'definitely initialized' fields: fields which must always be assigned before the object they are in escapes. These fields escape the 'default-zero' values of java: we are guaranteed that no one will ever see the default zero value for definitely initialized fields, and so we don't have to add the zeros in our value analyses. * Analysis/Quads/DefiniteInitOracle.java: New file. * Analysis/SizeOpt/BitWidthAnalysis.java, Analysis/Quads/SCC/SCCAnalysis.java: Parallel changes to SCCAnalysis and BitWidthAnalysis: finish the implementation of the REM, SHL, SHR, USHR, and XOR operation analysis. [Before we just assumed very conservative values for the results of these operations.] I also cleaned up the multiplication analysis a little bit. 2001-11-04 C. Scott Ananian * Analysis/SizeOpt/SizeCounters.java: Add a little bit of code to count how many pointer words are allocated in the course of the program. This will help us assess the effectiveness of pointer-shrinking techniques. * Analysis/SizeOpt/BitWidthAnalysis.java, Analysis/Quads/SCC/SCCAnalysis.java: Bug fix: gosh, this was a hard one to track down. The BitWidthAnalysis (and the SCCAnalysis that it is descended from) may under certain rare circumstances process a Wv item on the worklist (mentioning a variable in the PHI which has been raised) *before* it processes the Wq entry which would make the corresponding edge executable. Thus the evaluation of the PHI skips over a (perfectly legit) input value on an incoming edge (which hasn't yet been marked executable). By the edge *is* raised to executable, the PHI function is already in the Eq set, and so we never get a chance to re-evaluate it. Unless some input variable of the PHI is raised again, it will forever have the wrong value for its output. The solution is simple: marking an edge leading to a PHI executable should put the PHI back on the work list. I also added a simple toString() method to the Context objects, to aid in debugging. * Backend/Runtime1/class-root.properties, Backend/Runtime1/method-root.properties: New file. * Backend/Runtime1/Runtime.java, Backend/Runtime1/class-root.properties, Backend/Runtime1/method-root.properties: The method and class roots lists are now read in from properties files (wherein we can specify the proper classes/methods much more elegantly, with copious comments, etc) instead of being hard-coded in the runtimeCallableMethods() source. Look for the files Backend/Runtime1/method-root.properties and Backend/Runtime1/class-root.properties if you need to change something. Note that this makes it possible to elegantly subclass the Runtime: your runtime can override resourcePath() to have it fetch all resources from (say) harpoon/Backend/Runtime2. In your new properties files, you can 'include harpoon/Backend/Runtime1/method-root.properties' to use all of the old method roots, and then add your own afterward. * Analysis/SizeOpt/BitWidthAnalysis.java: Make my inter-procedural bitwidth analysis context-sensitive, for a user-defined level of context set with the 'harpoon.sizeopt.context' property. Levels of context greater than one are very slow! This check-in also exercises the new MapSet interface, and shows how to create a MultiMap of Maps by passing a MapFactory through Factories.mapSetFactory to create a CollectionFactory suitable for the MultiMap's value bags. * Util/Collections/AggregateMapFactory.java: Extend the entrySet() returned by AggregateMap to support the add operation in certain circumstances (those cases where the behavior of add is consistent with both Set and Map). * Util/Default.java: Add Default.entry() factory method to create Map.Entry objects. I wish this could be rolled into Default.pair(), which creates 2-entry List objects, but the short-sighted folk at Sun made the hashCode specifications for List and Map.Entry incompatible. Gah. 2001-11-03 C. Scott Ananian * Util/Collections/MapTest.java: Refactor the code slightly to allow testing MapFactories as well as direct implementations of java.util.Map. Added test clauses for AggregateMapFactory, Factories.synchronizedMapFactory(), and Factories.hashMapFactory. * Util/Collections/AggregateMapFactory.java: Create AggregateMapFactory, heavily influenced by AggregateSetFactory. This allows you to combine many small hashmaps into one large one, with hopefully improved memory utilization. Tested with MapTest. * Util/Collections/AggregateMapFactory.java: New file. * Util/Collections/Factories.java: Added 'mapSetFactory()' and 'multiMapSetFactory()' methods to the Util.Collections.Factories class, which allow you to obtain a MapSet / MultiMapSet SetFactory from any MapFactory. There's even a little optimization tweak to recognize the case where the given map type already returns appropriate MapSets as a result of the map.entrySet() method, in which case we can skip the creation of a wrapper class. * Util/Collections/GenericInvertibleMultiMap.java, Util/Collections/GenericMultiMap.java, Util/Collections/MapSet.java, Util/Collections/MultiMapSet.java: Added interface definitions for MapSet and MultiMapSet, which are Sets of Map.Entry's which let you obtain a Map and MultiMap (respectively) view. This way, the Set returned from Map.entrySet() can be used to obtain the original Map again, to do quick lookup of keys, for example. The MapSets can be stored as values in a MultiMap to obtain multi-level hash tables. An example: ((MapSet)mmap.getValues("foo")).asMap().containsKey("bar") Not the most elegant thing around (parameterized types would make this cleaner), but it will work. HashEnvironment, GenericInvertibleMultiMap, and GenericMultiMap have been slightly tweaked to return MapSet/MultiMapSets instead of plain Sets. * Util/Collections/MapSet.java, Util/Collections/MultiMapSet.java: New file. * Util/HashEnvironment.java: Added interface definitions for MapSet and MultiMapSet, which are Sets of Map.Entry's which let you obtain a Map and MultiMap (respectively) view. This way, the Set returned from Map.entrySet() can be used to obtain the original Map again, to do quick lookup of keys, for example. The MapSets can be stored as values in a MultiMap to obtain multi-level hash tables. An example: ((MapSet)mmap.getValues("foo")).asMap().containsKey("bar") Not the most elegant thing around (parameterized types would make this cleaner), but it will work. HashEnvironment, GenericInvertibleMultiMap, and GenericMultiMap have been slightly tweaked to return MapSet/MultiMapSets instead of plain Sets. * Util/Collections/MapTest.java: Added 'MapTest', which is test code (liberally borrowed from the Mauve project) to test implementations of java.util.Map for correctness. Note that because our MultiMap interface is a semantically consistent extension of Map (ie, all the Map methods behave properly if you don't use any of the MultiMap features), we can also use MapTest to (partially) test the MultiMap implementations for correctness. java.util.HashMap, GenericInvertibleMap, GenericInvertibleMultiMap, and GenericMultiMap pass this test suite with no errors. harpoon.Util.LinearMap fails in the entrySet() method checks, because it doesn't prohibit you from 'add'ing elements which are not Map.Entry's to the entrySet. This is a safety error but not a correctness problem. harpoon.Util.HashEnvironment doesn't support the remove() operation on its entrySet(), keySet(), or values() collections; the test-suite reports this failure. Otherwise it passes. * Util/Collections/MapTest.java: New file. * Util/Collections/MultiMap.java, Util/Collections/UnmodifiableMultiMap.java: Add 'addAll(MultiMap)' method to MultiMap interface. This method was mentioned in the comments to putAll(Map m), but wasn't actually declared (doh!). Also added MultiMap.size() [also inherited from Map], so that I could add a clarifying javadoc comment on its proper return value. * Util/Collections/MapWrapper.java: Bug fix! MapWrapper wasn't properly proxy'ing the toString(), hashCode(), and equals() methods, meaning that a wrapped map wouldn't behave properly as a key in a map, and wouldn't compare equal with maps with identical contents. Fixed now. * Util/Collections/GenericMultiMap.java: Rework GenericMultiMap so that the collections returned by keySet(), valueSet(), and entrySet() are fully modifiable. Also factored out 'size' field (instead of counting up the entries in the entrySet() every time) for efficiency. Also added 'allAll(MultiMap)' method. The entrySet() for a multimap returns a Set of 'Map.Entry's, where there may be multiple 'Map.Entry's with the same key (because this is a multimap). This makes it consistent with the semantics of entrySet() for a standard java.util.Map. * Util/Collections/GenericInvertibleMultiMap.java: Add standard 'takes a map' and 'takes a multimap' constructors for classes which extend java.util.Map and harpoon.Util.Collections.MultiMap, respectively. Add 'addAll(MultiMap)' method. Implement 'entrySet()' method properly. * Util/Collections/GenericInvertibleMap.java: Add the standard 'takes a Map' constructor for classes which implement java.util.Map. * Util/Default.java: Extend the default comparator to deal better with nulls: the compareTo() method we eventually invoke doesn't handle 'null' inputs for some classes in the system library (java.lang.String.compareTo(), for example). * Analysis/Quads/MethodTraceFactory.java: Remove 'import *' statements. * Analysis/Quads/MethodTraceFactory.java: New file. * Analysis/Quads/MethodTraceFactory.java: The MethodTraceFactory adds DEBUG quads to allow you to see what methods are being called in your code. This is helpful when debugging against a known-good executable: you can look for the first non-identical line to find out where your 'bad guy' starts going wrong. * Analysis/SizeOpt/BitWidthAnalysis.java: Calls to Thread.start() 'magically' cause calls to Thread.run(). This allows 205_raytrace and 227_mtrt to make it through our analysis. * Analysis/Counters/RuntimeMethodCloner.java: Add a little more information to the warnings we print out, since source file and line number information are often not present for library code. * Analysis/Counters/CounterFactory.java: Never allow counters to be added to counters code (this produces bogus numbers because the counters code will be executing while we're trying to print out the numbers). 2001-11-02 C. Scott Ananian * IR/Tree/ToTree.java, Backend/PreciseC/TreeToC.java: Add support for the DEBUG quad to the tree-form converter. Now you can debug you programs 'easily' by adding DEBUG quads to key points. [Perhaps I ought to provide a universal means for *disabling* output from DEBUG quads? I haven't done it yet.] * Analysis/SizeOpt/BitWidthAnalysis.java: Fields can't have bitwidths wider than the types they are defined to hold. * Runtime/Counters.java: Some small edits to improve the predictability (non-virtuality) of method calls in the Counters runtime -- mostly we're trying to eliminate virtual calls to Object.toString(), which we can't clone properly. 2001-11-01 C. Scott Ananian * Analysis/Counters/CounterFactory.java, Analysis/Counters/RuntimeInliner.java, Analysis/Counters/RuntimeMethodCloner.java: New (better!) anti-counter counting code. We now copy (non-virtual or final) methods referenced in harpoon.Runtime.Counters into the counters class. Then refusing to add counters to code in harpoon.Runtime.Counters ensures that the counter code isn't itself counted. Limitations: some methods are virtual and can't be cloned. * Analysis/Counters/RuntimeMethodCloner.java, Analysis/Counters/RuntimeInliner.java: New file. * Analysis/Counters/CounterFactory.java, Analysis/Counters/RuntimeInliner.java: The code executed while in the harpoon.Runtime.Counters package messes up the statistics. We create new Strings while we're trying to report how many strings have been created, for example. Not Good. The RuntimeInliner class is a first attempt at remedying this by cloning code used by the report method and placing it inline, thus making it easier to delimit what *not* to add statistics to. But inlining is an awful solution because we need to inline too much and our code size explodes all over the place. Checking this in as a first draft; I'm starting to write a better version (which adds procedures to the Counters class) right now. * Analysis/Quads/SCC/SCCAnalysis.java: Port default-case SWITCH analysis improvement from SizeOpt.BitWidthAnalysis over to Quads.SCC.SCCAnalysis. * Analysis/SizeOpt/BitWidthAnalysis.java: Improve analysis of switch statements so that we can tell when bit-width information rules out the possibility of the default case executing. * Analysis/Quads/SCC/SCCOptimize.java: Bug fix: SCCOptimize couldn't handle SWITCH quads with some non-executable edges. Fixed now. 2001-10-31 C. Scott Ananian * Analysis/SizeOpt/FieldReducer.java: Add 'no mutate' option to FieldReducer, controlled by the property harpoon.sizeopt.no-field-reducer. This allows us to generate statistics 'as if' the field reductions have taken place, without actually reducing the fields or mutating the field accesses. Also removed a stray 'hc.getElements()' call that was inserted once upon a time for debugging and then forgotten. * Analysis/SizeOpt/SizeCounters.java: Added Yet Another counter to SizeCounters so that we can see what effect rounding fields to the nearest byte will have. * Analysis/Quads/DeadCode.java: In SSI form, phis or sigmas with the same sources will always produce the same values and so the destinations of these functions should be renamed so that they refer to the same temp ("value information" in SSI parlance). The DeadCode routine tried to do this, but it forgot that renamings have a way of propagating: once I rename two temps mentioned in a PHI/SIGMA, I may have created other PHIs or SIGMAs that now have identical sources and need renaming. This latter causes problems in SCC analysis because properties of one of the temps-that-should-have-been-renamed-the-same are not transfered over to the other (ie, one temp will have a null pointer check done on it, and its 'non-null-ness' after a SIGMA will not propagate to the other). I added a little bit of code to add PHI and SIGMA uses back to the worklist after a renaming so that all appropriate renamings are done. 2001-10-30 C. Scott Ananian * Main/SAMain.java, Analysis/SizeOpt/FieldReducer.java, Analysis/SizeOpt/SizeCounters.java: Add additional 'bit counter' statistics so that we can see how many bits the field reducer could trim away in an ideal case. * Analysis/Transformation/MethodMutator.java: Make MethodMutator.codeFactory() non-final, as there are some legitimate circumstances where you might want to over-ride it (to insert a transformation *after* the method mutator, for example). * Analysis/SizeOpt/MostlyZeroFinder.java, Backend/Runtime1/DataConfigChecker.java: Remove 'import *' statements. 2001-10-29 C. Scott Ananian * Analysis/SizeOpt/MostlyZeroFinder.java: Add 'mostly zero finder' statistics code: this finds fields which are almost always zero, and gives a rough estimate of the maximum memory we could save by optimizing these fields out into hashtables. * Analysis/SizeOpt/MostlyZeroFinder.java: New file. * Main/SAMain.java: Add 'mostly zero finder' statistics code: this finds fields which are almost always zero, and gives a rough estimate of the maximum memory we could save by optimizing these fields out into hashtables. * Analysis/Transactions/AnalysisCheckOracle.java, Analysis/Transactions/BitFieldNumbering.java, Analysis/Transactions/CheckOracle.java, Analysis/Transactions/DominatingCheckOracle.java, Analysis/Transactions/HoistingCheckOracle.java, Analysis/Transactions/SimpleCheckOracle.java, Analysis/Transactions/SyncTransformer.java: New synchronization transformation code (this has been sitting in my tree uncommitted for too long). This version only allocates a shadow object on *writes*. Since there are roughly 10x more reads than writes, this should improve our performance immeasurably. The new code doesn't have runtime support yet, but I'm working on it. * Main/SAMain.java, Backend/Runtime1/DataConfigChecker.java, Backend/Runtime1/Runtime.java: Add support for configuration-checking between FLEX and the C runtime system. This code creates references in FLEX's emitted compiled code that need to match labels in the compiled C runtime. If these do not match, we'll get a linker error which (hopefully) will indicate clearly what the problem is -- for example, that FLEX expects the runtime to be compiled --with-precise-c, for example, when the runtime was not. Hopefully this will end the hours of searching for elusive "bugs" which turn out to be simply mis-configurations. * Backend/Runtime1/DataConfigChecker.java: New file. * Backend/Generic/Runtime.java: Add support for configuration-checking between FLEX and the C runtime system. This code creates references in FLEX's emitted compiled code that need to match labels in the compiled C runtime. If these do not match, we'll get a linker error which (hopefully) will indicate clearly what the problem is -- for example, that FLEX expects the runtime to be compiled --with-precise-c, for example, when the runtime was not. Hopefully this will end the hours of searching for elusive "bugs" which turn out to be simply mis-configurations. * Backend/Runtime1/Runtime.java: bug fix: field numberings are calculated and fixed in cache just as soon as TreeBuilder is created (through call to objectSize() on java.lang.Object) which is often *before* transformations which can add/remove/mutate the fields. So now we re-create all these caches at the time of the setClassHierarchy() call, which should be after all these transformations are complete. * Analysis/SizeOpt/SizeCounters.java: Collect statistics on object allocation by type (which class is responsible for the most allocated bytes?). * Analysis/Counters/CounterFactory.java: Slight modification to counter behavior: we used to skip all counter code if it was executed before the CounterFactory class was initialized. Now we just skip the locking mechanism: if the CounterFactory hasn't been initialized then we're still in single-threaded mode, so not locking is safe. This allows us to gather more statistics from the static initializer portion of the execution. 2001-10-22 kkz * Analysis/PreciseGC/AllocationHoisting.java: Code in flux. Checking this in so that other people can compile. 2001-10-21 kkz * Analysis/PreciseGC/AllocationHoisting.java: New file. * Analysis/PreciseGC/AllocationHoisting.java: Transformation for write barrier removal. 2001-10-19 kkz * Backend/Runtime1/writebarrier-safe.properties: New file. * Backend/Runtime1/writebarrier-safe.properties, Main/SAMain.java, Analysis/PreciseGC/MRA.java, Analysis/PreciseGC/MRAFactory.java, Analysis/PreciseGC/WriteBarrierQuadPass.java: State of the analysis: write barrier removal handles assignments to the most recently allocated object including those within "safe" initializers. Added concept of exception sets of object classes so that calls are no longer completely destructive for the MRA analysis. To make that work, added a properties file for "safe" native methods (i.e. those free of java-visible allocations.) Also added -x and -y options to SAMain for write barrier removal and statistics, respectively. 2001-10-18 C. Scott Ananian * Main/SAMain.java: Check that the given main() method is actually a static method with the proper signature (otherwise the Runtime will give a very strange error when you run the result). Also make the 'optimize' flag inline small methods too. * Backend/PreciseC/TreeToC.java: Fix a type-checking issue in the code generated by the preciseC backend. Under aggressive method inlining, we were generating code such as (_String_2349a)+8 where _String_2349a was defined as a 'struct _String_2349a'; the addition here would be incorrect, although in actual practice the bug was caught because 'struct _String_2349a' was an incomplete type. Casting all pointers to 'void *' fixes the bug and makes the C compiler error go away too. * IR/Tree/UNOP.java, Analysis/Tree/AlgebraicSimplification.java: Two bug fixes in Algebraic Simplification: first, the guard intended to prevent optimizing expressions involving the NULL constant was a little over-eager and accidentally prevented *any* optimization involving pointers. Second, the types of two UNOPs in div2mul_positive were incorrect, causing type errors when compiling using the precisec backend. The correctness/incorrectness of this can easily be automated, so I've added the appropriate assertion to the harpoon.IR.Tree.UNOP constructor. * Analysis/Quads/SmallMethodInliner.java: Slightly more inlining by default. 2001-10-18 salcianu * Main/PAMain.java, Analysis/PointerAnalysis/MAInfo.java, Analysis/PointerAnalysis/PANode.java: Fixing a small error 2001-10-18 C. Scott Ananian * Support/video.jar: Updated video.jar with new version of Runtime/src/cam/AltVideo.java class. 2001-10-15 kkz * Main/SAMain.java, Analysis/PreciseGC/MRA.java, Analysis/PreciseGC/MRAFactory.java, Analysis/PreciseGC/WriteBarrierQuadPass.java: More progress on MRA analysis. Now incorporates initializer optimization. * Analysis/PreciseGC/MRAFactory.java: New file. 2001-10-13 kkz * Analysis/PreciseGC/MRA.java, Analysis/PreciseGC/WriteBarrierQuadPass.java: Fixed up WBQP. Now uses MRA analysis to get rid of more write barriers. 2001-10-12 kkz * Analysis/PreciseGC/MRA.java: Most-Recently-Debugged version of Most-Recently-Allocated Object dataflow analysis. Yeah! * Analysis/PreciseGC/MRA.java: New file. 2001-10-12 C. Scott Ananian * Backend/Runtime2/TreeBuilder.java: Fixed this DerivationChecker error that Frederic found: Assertion Failure: Can't determine type for MEM. MOVE( MEM( BINOP(add, TEMP(BRIANTEMP0), CONST(4))), BINOP(add, MEM( BINOP(add, TEMP(BRIANTEMP0), CONST(4))), CONST(2))) at harpoon.Analysis.Tree.DerivationChecker.ASSERT(DerivationChecker.java:72) You could either declare the MEM an HClass.Void, or treat it as an integer. As the value of the field at this point in execution should be a hashcode (not a pointer), I changed the declaration to Int. 2001-10-04 C. Scott Ananian * Main/Raw.java: Add main routine to dump raw class file data (useful for debugging sometimes). * Main/Raw.java: New file. * Interpret/Quads/INResourceBundle.java: Removed 'import *' statement using bin/remove-stars.perl. 2001-10-02 C. Scott Ananian * ClassFile/ClassPointer.java: A little extra caution in the ClassPointer constructor (checking that we are given a valid descriptor). 2001-10-01 kkz * Main/SAMain.java, Analysis/PreciseGC/WriteBarrierStats.java: More changes to enable printing of write barrier list. * Analysis/PreciseGC/WriteBarrierQuadPass.java: Changes to enable printing of write barrier list. 2001-09-28 C. Scott Ananian * Interpret/Quads/INResourceBundle.java: Improve quad interpreter (by adding implementations of additional native methods) so that quad interpreter can interpret the quad interpreter. * Interpret/Quads/INResourceBundle.java: New file. * Interpret/Quads/INClassLoader.java, Interpret/Quads/INFileInputStream.java, Interpret/Quads/Support.java: Improve quad interpreter (by adding implementations of additional native methods) so that quad interpreter can interpret the quad interpreter. * Interpret/Quads/Method.java: Update quad interpreter to handle class CONST types. * SELF-BUILDING: More self-building details. [setting JAVA_HOME, building the quad interpreter.] 2001-09-26 C. Scott Ananian * Interpret/Quads/StaticState.java, Interpret/Quads/Method.java, Main/Run.java: Add '-quiet' option to harpoon.Main.Run quad interpreter, so that we can have 'just like java' output (without any of our debugging trace cruft) if we need to. * IR/Tree/ToTree.java: Fixed a Tree translation problem when the input contains 'conflicting phi functions'. Found in TreeMap.successor() as well as the TestPhi test case in Tests/Java/Semantics. * Main/JMain.java: Remove unnecessary import dependence on Analysis.ToSSA (which no longer exists). * Analysis/ToSSA.java: Renamed Analysis.ToSSA to IR.Quads.ReHandlerToSSA and made it non-public. New code should use IR.Quads.SSIToSSA instead. @RENAME: Analysis/ToSSA.java IR/Quads/ReHandlerToSSA.java@ * IR/Quads/ReHandlerToSSA.java: New file. * IR/Quads/ReHandler.java, IR/Quads/ReHandlerToSSA.java: Renamed Analysis.ToSSA to IR.Quads.ReHandlerToSSA and made it non-public. New code should use IR.Quads.SSIToSSA instead. @RENAME: Analysis/ToSSA.java IR/Quads/ReHandlerToSSA.java@ * IR/Quads/XI.java: make XI quads non-public, since no-one actually generates them (yet?). * Main/Options.java: Allow generation of QuadSSA form on the command-line. * Interpret/Quads/Method.java: Ease quad code type check to allow interpreting QuadSSA and QuadRSSx forms. Fix bug in PHI interpretation which would yield erroneous results when interpreting a set of 'conflicted phi' functions. * IR/Quads/RSSxToNoSSA.java: Fix bug with 'conflicting PHI functions' in RSSxToNoSSA. See the 'TestPhi' test case in Tests/Java/Semantics. Also simplified/clarified the code a bit. Do we need to worry about conflicting sigma functions? * IR/Quads/PHI.java, IR/Quads/ToNoSSA.java: Optimize ToNoSSA to avoid generating lots of unnecessary variable names when not necessary. * IR/Quads/RSSxToNoSSA.java: Simplify RSSxToNoSSA by using the Quad.replace() function (this also fixes some subtle bugs when quads have edges which point to themselves). 2001-09-25 C. Scott Ananian * IR/Quads/ToNoSSA.java: Bug fix to ToNoSSA: the destination of a phi function may well be named as one of the sources of a different phi function, so we must be careful not to overwrite dsts until all the sources have been evaluated. Think of this PHI: x1=phi(x0, y1); y1=phi(x0, x1). * Analysis/EventDriven/ContCodeNoSSA.java: ContCodeNoSSA was returning the wrong codename. * ClassFile/HCode.java: Add a newline and a call to PrintWriter.flush() to the HCode.print() generic implementation, to make this behave like the other print methods. (In particular, this makes the bytecode output 'look right'.) * Backend/Runtime1/init-safe.properties: Add some additional initializer-safe methods to Runtime1's property list. These are needed to compile harpoon.Main.Run (the quad interpreter). * Main/SAMain.java: The CounterFactory code factory needs its input *not* to be in quad-with-try form. We convert to quad-ssi, since that's what the subsequent passes will work best on. 2001-09-24 C. Scott Ananian * Backend/Runtime1/DataClaz.java, Backend/Runtime1/DataReflection2.java, Backend/Runtime1/TreeBuilder.java, Backend/Analysis/InterfaceMethodMap.java: Fix bug in invoking interface methods which have the same signature as methods inherited from java.lang.Object. These methods didn't show up in the dispatch table, but were being allocated space by the InterfaceMethodMap and dispatched via there anyway. Now we just ban these methods from the interface dispatch table outright. InterfaceMethodMap asserts that we don't expect to see these methods there and everyone else recognizes when they see an interface method inherited from Object and use the java.lang.Object direct class method dispatch entry instead. * Backend/Analysis/InterfaceMethodMap.java: Fix bogus 'equals()' method in HmNode which would cause errors if two distinct methods ended up with the same hashcode. Haven't seen a bug due to this yet, but it's only a matter of time. Replaced the 'paramTypes' field with the easier-to-compare descriptor string while I was at it. * Backend/Runtime1/init-safe.properties: Add init-safe entry for RandomAccessFile.getFilePointer(), needed by the GNU classpath implementation of the java.util.zip package, which is used when compiling FLEX with itself. 2001-09-21 C. Scott Ananian * Backend/Runtime1/init-safe.properties: We don't need to add methods in java.util.zip to the init-safe set anymore, since we're using the Classpath pure-java implementation of java.util.zip. * Main/SAMain.java: We were adding the size counters twice! What a dork I am! * bin/interpret: Rewrite the interpret script to use bin/run-java. * bin/run-java: Add Support/cpzip.jar (the GNU classpath pure-java implementation of java.util.zip) to the standard FLEX harpoon.class.path. This means we don't have to do an evil JNI implementation of Sun's java.util.zip crap in the JDK 1.1 classes.zip. * Support/cpzip.jar: GNU classpath's pure-java version of the java.util.zip package. Compiled from CVS grabbed at 6:24pm EST 2001-09-21. Java sources are included in the .jar. * Support/cpzip.jar: New file. * Backend/Runtime1/DataClaz.java, Backend/Runtime1/TreeBuilder.java: Fix our translation of the COMPONENTOF test: we weren't handling arrays of interface types correctly. We do now. [Bug found while compiling FLEX with itself; we use lots of HMethod[] arrays in FLEX, and HMethod is an interface.] 2001-09-20 C. Scott Ananian * Main/SAMain.java: Add support for the bitwidth optimizations and size counters to SAMain. * IR/Quads/ToNoSSA.java: Bug-fixes for ToNoSSA: I'm not sure how this class ever worked. Perhaps it was never really used? ToNoSSA was trying to merge temps *and* clone quads at the same time--bad idea! It would often discover a necessary merge *after* it had already cloned several quads with the *old* name of the Temp, and never go back and update them with the merged name. The fix is very simple: we go through the code first quickly and do all the merges, *then* we go back and do all the cloning. The functions of the NameMap and the CloningTempMap have been merged, with a boolean and assertions to keep the merging step separate from the cloning step. * bin/run-java: Put -D options to run-java in the right place. * Analysis/SizeOpt/BitWidthAnalysis.java: Use consistent ordering for before/after statistics. 2001-09-19 C. Scott Ananian * Support/samain-root-set: New file. * Support/samain-root-set, SELF-BUILDING: Update instructions for building FLEX with itself; you need a special root set (Support/samain-root-set) which is also added in this commit. At the moment the samain-root-set only contains the standard locale support classes. * Backend/Runtime1/init-safe.properties: Add a few more methods to the list of initializer-safe methods; these are necessary in order to compile FLEX with itself. * Backend/Runtime1/Runtime.java: Add the 'void' primitive type to the Runtime's root set, as it is referenced (using Class.forName) by the static initializer of the java.lang.Void class. (Discovered while compiling FLEX with itself.) * Backend/Runtime1/DataStrings.java: Handle java.lang.String.offset field specially in the object builder, to allow size optimizations to remove this field where possible (all string objects created have offset==0). * Analysis/Quads/SCC/SCCOptimize.java: Allow SCCOptimize to handle CALLs with one or both outgoing edges non-executable, by turning these outgoing edges into infinite loops. We saw this when running interprocedural BitWidthAnalysis, which was smart enough to detect CALL sites where either an exceptional or a normal return was impossible. * Analysis/Quads/QuadClassHierarchy.java: Correct bug seen in java.io.ObjectInputStream.inputArray() when compiling FLEX with itself: QuadClassHierarchy when given quad-with-try form as input did not count TYPECASTs as naming a class to be discovered, even though they would be turned into INSTANCEOF quads which would reference that class during the conversion to quad-no-ssa. This caused an undefined reference to _Class__3F in the output in the above method. This bug is now fixed: the type mentioned in a TYPECAST is properly discovered, just as if it were an INSTANCEOF. * bin/run-java: When 'source'ing bin/run-java, the 'exit $?' command will cause the caller script to abruptly exit, not what we want. Since what we want is the exit status of the last command anyway, we can just eliminate the exit statement ('return' might be a good alternative otherwise). * bin/build-arm-hack, bin/build-arm-pnk, bin/build-mipsda, bin/build-mipsvp, bin/build-precisec, bin/build-roles, bin/find-flex-dir: Oops -- the bin/run-java subroutine wasn't properly inheriting the various environment variables set in the bin/build-* scripts. Also export the variables set in bin/find-flex-dir, so that if this script is invoked again from a subprocess, the same settings will be used. * bin/build-arm-hack, bin/build-arm-pnk, bin/build-mipsda, bin/build-mipsvp, bin/build-precisec, bin/build-roles, bin/find-flex-dir, bin/run-java: Clean up common code in bin/build-* scripts by factoring out bin/find-flex-dir (which sets $FLEX_DIR, $HARPOON_DIR, and $RUNTIME_DIR) and bin/run-java (which invokes java with the appropriate harpoon.class.path and suchnot). * bin/find-flex-dir: New file. * bin/build-precisec: Revert revision 1.1.2.21, wherein Wes removed the '-g' option from bin/build-precisec. Bad Wes. No biscuit. How can we debug without -g? 2001-09-18 C. Scott Ananian * Util/SortedMapComparator.java: New file. * Util/SortedMapComparator.java: SortedMapComparator is a slightly more efficient version of MapComparator for use when the Maps in question are really SortedMaps. * SELF-BUILDING: Check in some notes on how to build FLEX with FLEX. * SELF-BUILDING: New file. * Backend/Runtime1/field-root.properties: Added flexible field root specification to BitWidthAnalysis (fields which are read/written by native code, and thus must be treated conservatively). The field roots are read from the 'field-root.properties' resource in the runtime's resource path. FieldReducer: eviscerate methods which the BitWidthAnalysis determines are uncallable. This avoids lots of problems caused by over-optimization of what the analysis knows to be dead-code. Also throw away writes to compile-time constant fields. * Backend/Runtime1/field-root.properties: New file. * Analysis/SizeOpt/BitWidthAnalysis.java, Analysis/SizeOpt/FieldReducer.java: Added flexible field root specification to BitWidthAnalysis (fields which are read/written by native code, and thus must be treated conservatively). The field roots are read from the 'field-root.properties' resource in the runtime's resource path. FieldReducer: eviscerate methods which the BitWidthAnalysis determines are uncallable. This avoids lots of problems caused by over-optimization of what the analysis knows to be dead-code. Also throw away writes to compile-time constant fields. * IR/Quads/Peephole.java, IR/Quads/QuadNoSSA.java, IR/Quads/QuadWithTry.java: Remove unused/unnecessary allowFarMoves parameter. * IR/Quads/Peephole.java: Bug fix to Peephole: the SwapVisitor was ignoring handler status, resulting in swaps of protected and unprotected quads. This (along with the bug described in the previous commit to this file) caused problems compiling harpoon.IR.Quads.RSSxToNoSSA, because the definition of lv2_0 was being moved across the handler boundary. This caused potential executions of the handler before lv2_0 had been defined, resulting in type errors converting to low-quad-ssi form. The Peephole visitor has been revamped, too. Instead of forbidding any change to 'protected quads' (those with handlers), we use a much simpler rule: no movement of quads is allowed across handler boundaries. [We also had to reorder the 'Qp instanceof FOOTER' rule, because the FOOTER was being interpreted as a new handler context. Now we deal with FOOTERs first.] This rule should be applicable for all well-formed code generated from java source, as no variables defined inside the try block may legitimately be referenced from outside the try or in the catch or finally, so moving definitions around inside the try block is acceptable. I *think* the rule is applicable for all bytecode which passes the verifier, too, but I'm not certain. [As part of these new simpler rules, we re-enable moves past calls when the CALL is in the same handler context as the MOVE.] The 'allowFarMoves' parameter is now unused. The rules described above work perfectly well for both quad-with-try and no-try forms. Finally, we use a UniqueStack instead of a simple Stack now for the to-do list, which results in less needlessly duplicated work. * IR/Quads/Peephole.java: Bug fix: when protected quads are replaced their replacements are not protected. 2001-09-18 vkuncak * bin/build-roles-browse: Bild & Browse dynamic role inference trivial script. * bin/build-roles-browse: New file. * bin/browse-roles: A script to run dynamic role inference. * bin/browse-roles: New file. 2001-09-18 C. Scott Ananian * Analysis/Quads/SCC/SCCOptimize.java: Add a pair of assertions to SCCOptimize to catch some things that might go wrong. [Very useful while debugging the size optimizations, which invoke SCCOptimize as a subroutine.] * IR/Quads/Translate.java: Bug fix: the Comparator given to the TreeMap mapping pairs to generated HANDLER nodes was ignoring the second component of the tuple. This caused exception handlers inside finally blocks to be incorrectly merged (because the JSR context was being ignored in the key). When compiling FLEX with FLEX, this manifested itself as a type-check error (eventually) in harpoon.ClassFile.Loader$SystemLinker.forDescriptor0(). 2001-09-17 C. Scott Ananian * Util/MapComparator.java: Remove 'import *' statements. (oops) * bin/run-java: New file. * bin/run-java: Provide a shell to invoke java with the options we use in bin/build-*. This way you can invoke (for example) harpoon.Main.Main and be assured that you're using the same classpath and other properties as when you use the bin/build-precisec script. [Maybe bin/build-precisec should invoke bin/run-java as a subroutine?] * Util/MapComparator.java: Added a comparator for Maps, which creates a sorted list of key,value pairs and then invokes ListComparator on that. * Util/MapComparator.java: New file. * bin/build-precisec: Add 'MAKEOPT' variable for specifying make options (like '-j2') on the command-line to bin/build-precisec. * Util/ParseUtil.java: Added parse utility function to parse a field name from a string. * Util/Default.java: Made the 'EMPTY_MAP' implementation a SortedMap for maximal utility. [since an empty map is trivially also a sorted map] * IR/Bytecode/InRet.java: The 'toString' method of the 'ret' bytecode opcode previously didn't include its operand. Fixed now. * Backend/Runtime1/ObjectBuilder.java: Make FLEX output files repeatable by using the same seed for objectbuilder's hashcodes. 2001-09-17 bdemsky * bin/build-roles: Build role script * bin/build-roles: New file. * Backend/Runtime1/ObjectBuilder.java: Role Discovery updates... ObjectBuilder has to give default values to UID fields... Safe to always do, because normal java.lang.Object doesn't have a UID field. 2001-09-13 C. Scott Ananian * IR/Tree/ToTree.java: Rewrite dfsTraverse to use an explicit stack instead of recursion: this should help us compile larger programs, even in the face of java's silly small-stack restrictions. * IR/Tree/ToTree.java: Rewrite dfsTraverse to take a single Edge, in preparation for making it non-recursive. * GNUmakefile: Use SSH protocol 1 when doing 'make install' 'make srcdoc-install' etc. 2001-09-12 C. Scott Ananian * bin/cvsblame.pl: Add support for :ext: format CVSROOT strings where 'host' is specified instead of 'user@host'. * Analysis/SizeOpt/FieldReducer.java: Removed 'import *' statements via script. 2001-08-30 kkz * Runtime/PreciseGC/WriteBarrier.java: Added unique ids for each call site. * Analysis/PreciseGC/WriteBarrierConstElim.java: New file. * Analysis/PreciseGC/WriteBarrierConstElim.java: Pass for removing write barriers for sources that are constants. * Main/SAMain.java: Changes to SAMain to include the new write-barrier passes. * Analysis/PreciseGC/WriteBarrierQuadPass.java, Analysis/PreciseGC/WriteBarrierStats.java: New file. * Analysis/PreciseGC/WriteBarrierQuadPass.java, Analysis/PreciseGC/WriteBarrierStats.java: Pass to add write barriers to replace WriteBarrierPrePass, which is not as accurate, and a pass to tag each write barrier call site with a unique id for statistics-gathering purposes. * Analysis/PreciseGC/WriteBarrierPrePass.java: Minor changes. This pass is now superseded by WriteBarrierTreePass anyhow. But wanted to keep repository up-to-date with newest version. * Analysis/PreciseGC/WriteBarrierTreePass.java: New file. * Analysis/PreciseGC/WriteBarrierTreePass.java: Pass for converting write barrier calls to a more efficient in-line implementation. Currently just calls a c function. Will be made more efficient. * Analysis/PreciseGC/WriteBarrierData.java: Data pass for getting runtime statistics about write-barriers. * Analysis/PreciseGC/WriteBarrierData.java: New file. 2001-08-28 kkz * Analysis/Tree/ConstantPropagation.java: Rewrote constant propagation for Tree form. Previous incarnation had broken somewhere along the way, using a reaching definitons pass for Tree form that no longer works, and traversing the Tree in some custom way that also fails. New incarnation uses the Analysis/Transformation/MethodMutator framework, and the CFGrapher for Trees to traverse the Tree. Pushed Spec through this pass, so it should work. The way in which we get to the parent Stm of an Exp may be fragile, so may need a better solution. * Analysis/ReachingDefsImpl.java: Changed to use CFGrapher so that we can use this analysis pass with Tree form. Also added case to handle unreachable code, for which BasicBlock factory does not generate BasicBlocks. Finally, removed debugging statements left over from ages and ages hence. 2001-08-22 wbeebee * Main/SAMain.java: Somehow, the code for SAMain was reverted... this caused all my results for my thesis to be wrong 2 days before the deadline... grrrr... The MULTITHREADED option needs to be accessable to both the precise malloc allocation strategy and the realtime malloc allocation strategy, since the realtime malloc sometimes calls the precise malloc - if the MULTITHREADED option is not available to RTJ, this causes hard-to-debug non-deterministic crashes to happen as random objects move during garbage collection. Please check for other random reversions... 2001-08-21 kkz * Runtime/PreciseGC/WriteBarrier.java: Dummy class and method used by Analysis.PreciseGC.WriteBarrierPrePass. * Runtime/PreciseGC/WriteBarrier.java: New file. 2001-08-20 kkz * Analysis/PreciseGC/WriteBarrierPostPass.java, Analysis/PreciseGC/WriteBarrierPrePass.java: New file. * Analysis/PreciseGC/WriteBarrierPostPass.java, Analysis/PreciseGC/WriteBarrierPrePass.java: New passes for adding write barriers. Analysis is done in LowQuad form and a dummy write-barrier is inserted. The post-pass removes the dummy write-barrier and substitutes a real one, which is currently just a C function call. 2001-08-17 C. Scott Ananian * IR/Tree/ToTree.java: Fix bug Karen found in derivation information: two cases in ToTree where we weren't renaming the temps embedded in the derivations of the previous IR so that they corresponded to the correct temps in the current IR. Pretty easy to fix; the hard part was knowing where to look. 2001-08-15 wbeebee * Support/realtime.jar, Analysis/Realtime/Realtime.java: Changed rootset -> new MemAreaStack constructor. 2001-08-14 kkz * Backend/Analysis/InsertWriteBarrier.java: A Tree pass that inserts a C function call write-barrier. Very in-efficient, but good for debugging for now. * Backend/Analysis/InsertWriteBarrier.java: New file. 2001-08-13 wbeebee * bin/build-precisec, Analysis/Realtime/CheckAdderWithTry.java, Analysis/Realtime/Realtime.java, Support/realtime.jar, Analysis/Realtime/CheckAdderNoSSA.java: Brand new version of benchmarks and Realtime Java. RTJ was completely redesigned and reimplemented -> no more failed attempts at thread-local state, everything uses atomic operations. Updated Realtime directory to include new Reference Count Memory Area. A roughly 15-page detailed account of all of the changes in this commit will be found in my thesis. It works on ToyArray, ToyTree, Barnes, Water with NoHeapRealtimeThread support. 2001-08-02 pnkfelix * Analysis/Instr/IgnoreSpillUseDefer.java: FSK: Added nice documentation (a year late!) to IgnoreSpillUseDefer, FSK: since it really *is* needed for precise-gc analyses. * Analysis/Instr/BasePointerPreservingUseDefer.java: FSK: Implementation of a BasePointerPreservingUseDefer is now in FSK: place. This, combined with the TempLocator stuff we wrote FSK: oh so long ago, forms the foundation of regalloc support for FSK: precise-gc. * Analysis/Instr/BasePointerPreservingUseDefer.java: New file. * Backend/Generic/RegFileInfo.java, Analysis/Instr/AppelRegAllocClasses.java, Analysis/Instr/AppelRegAllocFsk.java, Analysis/Instr/RegAlloc.java, Analysis/Instr/AppelRegAlloc.java: FSK: Various changes to support indication of the illegal FSK: register set (something which I included in my thesis FSK: but was not needed for StrongARM, and so I, um, punted it FSK: until now) 2001-07-30 kkz * Backend/Runtime1/DataClaz.java: Cleanup of code for generating the auxiliary GC bitmap. 2001-07-25 kkz * Backend/Runtime1/DataClaz.java: The last change to the format of the GC data layout broke the semi-precise collector. Reverting those changes plus adding a minor optimization. The code in here is due for a cleanup, so checking in the working code now. If you take this checkin you will need to update runtime. 2001-07-25 pnkfelix * Util/Collections/BinaryTree.java, Util/Collections/IntervalTree.java: FSK: 1. BinaryTree: added more documentation, made some constraints FSK: clearer in the spec, and took out a useless helper method. FSK: 2. Added a useful extension of RBTree, IntervalTree. This FSK: also serves as a reasonable example of how extensions FSK: to trees (in terms of adding state to the nodes and FSK: maintaining invariants on that state) should work. * Util/Collections/IntervalTree.java: New file. * Util/Collections/BinaryTree.java, Util/Collections/RedBlackTree.java: FSK: Wrote a BinaryTree implementation and made it FSK: extensible to allow for RedBlackTree to inherit FSK: from it. Am taking my time trying to think of FSK: a nice general Tree interface. * Util/Collections/BinaryTree.java, Util/Collections/RedBlackTree.java: New file. 2001-07-24 pnkfelix * Analysis/Instr/AppelRegAllocClasses.java, Analysis/Instr/SpillHeuristics.java: FSK: Attempted to further fine tune the use of alternate bitstring FSK: and hashset reps for adjmatrix, but the overhead of the FSK: mechanism does not outweigh the gains. FSK: An email from Emmett reminded me that I need to update FSK: the MIPS CodeGen.spec, so I guess I'll do that before FSK: Derivation support. * Analysis/SizeOpt/BitWidthAnalysis.java: FSK: jikes was complaining about the need for explicit qualification, FSK: since "get(Temp)" is present both in the superclass (HashMap) of FSK: the inner class MyTempMap and in MyTempMap's containing class. FSK: However, Scott's casting get(Temp) to a (Temp) here, and the FSK: containing class's declaration of "get(Temp)" returns a FSK: LatticeVal (which cannot be an instanceof Temp), so I'm figuring FSK: he really wanted a call to "super.get(Object)" here. * Analysis/Instr/AppelRegAlloc.java, Analysis/Instr/AppelRegAllocClasses.java, Analysis/Instr/SpillHeuristics.java: FSK: 1. Switched code to use only Chaitin spill heuristic FSK: to do some speed comparisons (in order to determine FSK: how much slowdown is due to using multiple spill FSK: heuristics) FSK: 2. Added a BitSet rep for the Adj. Matrix, but FSK: conditionalized it based on number of nodes, FSK: because our interference graphs tend to become FSK: very sparse as the number of nodes grows, and FSK: the difference between the O(V^2) bitset and FSK: the O(E) hashset can be mind boggling. FSK: FSK: Am considering implementing Linear-Scan Allocation FSK: prepass in an attempt to kill off the time we're FSK: wasting on _222_mpegaudio.p. But support for FSK: Derivations is a higher priority, so I'm tabling FSK: LinearScan for now. 2001-07-20 wbeebee * Analysis/Realtime/Realtime.java, Analysis/Realtime/RealtimeRuntime.java: Can now run NoHeapRealtimeThreads without the slow heap checks. 2001-07-19 C. Scott Ananian * Analysis/Quads/SCC/SCCOptimize.java: Don't try to rewrite the METHOD quad if the parameters are constants. Add an assertion that *some* out-going edge of a SIGMA must be executable: no roach motels (check-in but can't check out). * Analysis/SizeOpt/BitWidthAnalysis.java: Fix inter-proocedural bug: returnMap wasn't dealing with void methods well. Also, fieldMap had some ordering issues, such that if the field was uninitialized (lattice value null) on the first GET, it would "forget" to add itself to the fieldMap so that the initialization of the field would cause the GET to be re-evaluated. * Analysis/SizeOpt/BitWidthAnalysis.java, Analysis/SizeOpt/FieldReducer.java: Added some accessor methods to BitWidthAnalysis so that we can see the results of the analysis. Also printed out more accounting data for our info, and added some initializations of "special" fields. We now *should* do the right thing with method parameter/return value/exception values; but we seem to be over-optimizing at the moment. Working on it. Also added new FieldReducer code factory which uses the results of the BitWidthAnalysis to actually reduce the size of the objects and allocations by removing unused or constant fields and reducing the size of fields when it can. * Analysis/SizeOpt/FieldReducer.java: New file. * Analysis/SizeOpt/BitWidthAnalysis.java, Analysis/Quads/SCC/SCCAnalysis.java: Parallel improvements to SCCAnalysis and BitWidthAnalysis: use 'narrowest' type in sigma for INSTANCEOF-CJMP and OPER-CJMP; take exact types into consideration when analyzing COMPONENTOF tests; use bitwidth of tested value when analyzing SWITCH cases. Added 'isLowerThan()' method to the lattice objects (this method always returns false when the two lattice values are the same type, even when further examination of the type may yield more means of comparison). Also added some quick-and-dirty accounting to BitWidthAnalysis so we can see how well we're doing. * Analysis/SizeOpt/BitWidthAnalysis.java: Update BitWidthAnalysis to the most current version of SCCAnalysis. * Analysis/Quads/SCC/SCCAnalysis.java: Lots of fixes to SCCAnalysis. Revamped the value lattice so that xOperBooleanResult and xInstanceofResult extend *both* xBitWidth *and* xIntConstant (depending on whether the result of the comparison is known). This (along with some changes in handleSigmas) ensures that the information propagated from the CJMP source makes its way into the sigma functions regardless of whether the destination of the jump is statically known or not. Refactored the "no information known" handleSigmas function into its own method, too, for more uniform handling of the branch condition. Unified the 'left is source' and 'right is source' legs of the handleSigmas(xOperBooleanResult) method, and fixed some bugs in the handling of ICMPGT/LCMPGT. Also added a whole bunch of assertions to visit() methods to ensure that the static properties of the quads (object references not null, etc) are in fact being properly analyzed. This assertions now hold for *almost* the entire SPEC suite: in _228_jack we throw an assertion failure because UnHandler is smarter than SCCAnalysis: in particular, UnHandler detects an aliasing relation between stk0 and lv1 which means that a null-check on lv1 protects stk0 as well. SCCAnalysis can't figure this out yet. After lunch I'll work on trying to make SCCAnalysis smart enough to figure this out: SSI form handles *most* of these aliasing questions by only having one temp per value; but here's obviously a case where that rough generalization breaks down. Oh -- and all of SPEC (with the exception of _228_jack, discussed above) executes correctly with SCC optimization turned on, so this code has a very good chance of being correct. * IR/Quads/UnHandler.java: Fix bug in UnHandler where creating an alias from x to y and then from y to x would screw up the data structures. This would cause needed null pointer checks (in a very few instances, like spec.benchmarks._202_jess.jess.Rete.standDown() ) to not be generated by the UnHandler. I caught this while debugging SCCAnalysis and trying to figure out why certain static properties of the quad form (in this case, that the object reference of a non-static GET quad be non-null) were not provable by the analysis. Turned out the property wasn't true in some cases (!) due to this bug. Go, go, analysis. 2001-07-18 C. Scott Ananian * Analysis/Quads/SCC/SCCAnalysis.java: Re-vamped the value lattice for SCCAnalysis, adding a 'merge()' method and consequently greatly simplifying the visit(PHI) method of the analysis. Also tweaked raiseV; this new version doesn't need the higherThan() method, and its associated complicated and error-prone contract. There's some new debugging support in the constructor, as well: that's just a freebie. 2001-07-18 wbeebee * Analysis/Realtime/Realtime.java: There's no reason for such a powerful debugging tool as DEBUG_REF to be reserved for only the NOHEAP_CHECKS elite. 2001-07-17 C. Scott Ananian * Analysis/SizeOpt/BitWidthAnalysis.java: Today's work on BitWidthAnalysis: fix a lattice structure bug in the higherThan() method; fix has been mirrored in SCCAnalysis, but I'm waiting for the SPEC build to complete so I can check that it didn't break anything before committing over there. BitWidthAnalysis now takes a root set, instead of just a main method, and takes class initializers into account so that we get correct analysis results in the presence of the runtime. We implemented correct CALL/THROW/RETURN handling for interprocedurality, but some of the fancy bits are turned off -- bug I need to fix: CALL should merge in all currently-known RETURN/THROW values when it is processed, as they won't be touched again by the algorithm unless the value they return has actually changed as a result of the new CALL. For code re-use, it might be best for RETURN/THROW just to put all calls in the callMap on the Wq worklist, so that all RETURN/THROW processing is in the visit(CALL) method. (At the moment, we assume the conservative "native method" return values for all methods.) Also, I need to implement a LatticeVal.merge() method and change raiseV and visit(PHI) to use it. At the moment, CALL/THROW/RETURN and field set/get aren't working correctly because values are being overwritten, not merged. 2001-07-17 wbeebee * Analysis/Realtime/RealtimeRuntime.java: Scott fixed a bug -> I was getting the wrong linker to lookup a class. Always use the linker from the frame. HClass.getLinker() shouldn't be used if you just want to lookup a class. 2001-07-17 C. Scott Ananian * Backend/Analysis/PackedClassFieldMap.java: Assert that the result of the fieldList() method is correctly ordered, and that no fields overlap. * Analysis/SizeOpt/BitWidthAnalysis.java: Modifications to BitWidthAnalysis (nee SCCAnalysis) to support an inter-procedural field size value lattice. Haven't finished making the changes to CALL/RETURN/THROW to support actual inter-procedurality, but there's a comment in the visit(CALL q) method which explains what still needs to be done. It compiles; committing this as a check-point. 2001-07-16 C. Scott Ananian * Backend/Runtime1/TreeBuilder.java: Use PackedClassFieldMap by default. This results in slightly less memory allocation during execution (about 1% on spec). * Analysis/SizeOpt/BitWidthAnalysis.java: Imported current state of SCCAnalysis into SizeOpt package for transmogrification into an *inter*procedural bitwidth analysis routine, which will determine bitwidths of *object fields* as well as local variables. @SPLIT: Analysis/Quads/SCC/SCCAnalysis Analysis/SizeOpt/BitWidthAnalysis@ * Analysis/SizeOpt/BitWidthAnalysis.java: New file. 2001-07-16 wbeebee * Analysis/Realtime/CheckAdderNoSSA.java, Analysis/Realtime/CheckAdderWithTry.java, Analysis/Realtime/HeapCheckAdder.java, Analysis/Realtime/Realtime.java, Analysis/Realtime/RealtimeAllocationStrategy.java, Support/realtime.jar: Fixed HeapChecks to "do the right thing" (the 5 places mentioned in my thesis, etc.) HeapChecks now produce the proper locking on the Stats class when updating statistics, and can respond to starting and stopping statistics gathering at any time (to fix a bug with collecting while reporting). heapCheckRef now has another argument - the type of access we're doing, so that can be added to the debug info as well (READ, WRITE, NATIVE, CALL, METHOD). Changed static references to come from ImmortalMemory's instead of the erroneous HeapMemory's - which caused problems with NoHeapRealtimeThreads. Realtime.java now accepts additional command-line options DEBUG_REF, HEAP_CHECK, and tries to handle FAKE_SCOPES as well - but FAKE_SCOPES is still a little buggy. 2001-07-12 wbeebee * Analysis/Realtime/RealtimeRuntime.java: Whoops! Had been running Brian's stuff by mistake - showed up as a Monitor error... ap.nosync() seems to default to true when Alex's analysis hasn't been run... This is the second time I've inverted the case of an if in the same method - one would think that after having done it once, I would have learned... 2001-07-11 C. Scott Ananian * Backend/Analysis/PackedClassFieldMap.java: Added new 'PackedClassFieldMap' which should do an even *better* job of assigning field offsets so as to minimize object size. Small fields can now be allocated over inheritance boundaries for denser packing. * Backend/Analysis/PackedClassFieldMap.java: New file. * Backend/Runtime1/TreeBuilder.java, Backend/Maps/FieldMap.java, Backend/Analysis/ClassFieldMap.java: Removed default implementation of FieldMap.fieldOffset(), since no one would want to use an implementation without decent caching. The (nearly identical) implementation in ClassFieldMap is more illustrative, and executes in reasonable time. We don't want to put caching in the abstract superclass FieldMap, because different implementations (like the one we're about to check in) may implement the caching in very different ways. So just leave the method abstract. Added fieldAlignment the abstract FieldMap superclass, since any correct implementation of FieldMap will have to know about proper field alignments. The default is now more reasonable, too: instead of defaulting to 'no alignment' we now default to 'align to field size' which is much more universally correct. Added an option to Runtime1/TreeBuilder (-Dharpoon.runtime1.single-word-align=true) to allow single-word alignment of double-word quantities, on architectures (x86, strongARM) where that is sufficient. 2001-07-11 wbeebee * Support/realtime.jar, Analysis/Realtime/HeapCheckAdder.java: Fixed HeapCheckAdder to now use the following rules to determine when to do a check: - Check a READ of a pointer (what's returned is a base pointer) - Check a NATIVECALL return value - Check a CALL return value (could be native - you can't be sure statically). If this turns out to slow too many things down, could do type inference to see if it COULD be native - and then only put the check in then. - Check the formals to a METHOD call (all but the first, which is mysteriously undeclared in some calling conventions??) - Check writes to pointers which were formerly pointing to the heap (Scott and I had some discussion about this - these checks may be slow, but I think they should be there - the RTJ spec. is ambiguous and unhelpful, as always - see top of pg. 27 for details) If they're too slow, then I'll remove them - but that may necessitate Karen doing atomic updates on forwarding pointers and check to see if forwarding pointers got clobbered, and our programs may not be compatible with other RTJ implementations if we don't do the checks, and there may be a whole slew of problems that I just can't think of right now. And, of course, you can always do escape analysis to determine which pointers can escape a run method boundary or can touch a .newInstance or .newArray, to put checks only around those. If the checks turn out to be relatively fast, though, then it may not make any sense to waste time on any of this... 2001-07-11 C. Scott Ananian * Backend/Generic/Runtime.java, Backend/Runtime1/TreeBuilder.java, IR/Tree/ToTree.java: Fix bug Karen found: our allocation strategy for multi-dimensional arrays was calling the alloc function while there were still incompletely-initialized arrays on the heap. This was causing great problems when/if the alloc function triggered a gc. So we now zero all arrays immediately and *then* create/set the subarrays. Initialization optimization may pass 'initialize=false' to the runtime treebuilder for the *lowest-dimension arrays only* if it would prefer to manually initialize the elements. Remember that initialization *must occur* before the first call to (a function which calls) alloc. * Analysis/Counters/CounterFactory.java: Allow code which inserts counters to determine if those counters are enabled or not by making CounterFactory.isEnabled() public. * Backend/Analysis/ClassFieldMap.java, Backend/Analysis/SortedClassFieldMap.java: Committed a SortedClassFieldMap which attempts to order fields so as to reduce class object size. Trivial changes to ClassFieldMap to enable clean subclassing. * Backend/Analysis/SortedClassFieldMap.java: New file. * Analysis/SizeOpt/SizeCounters.java: Renamed counters to support partial enabling/disabling. Refactored ANEW instrumentation to produce *zero* code insertion when the relevant counters are not enabled. * Analysis/SizeOpt/SizeCounters.java: Better counting for array allocations. * Analysis/SizeOpt/SizeCounters.java: Use objectsize and headersize from Runtime.TreeBuilder instead of rolling our own. This is now possible because the Frame can be constructed before the classHierarchy. 2001-07-10 C. Scott Ananian * Main/SAMain.java: JDK1.1 compatability fix. * Main/EDMain.java, Main/EDXMain.java, Main/SAMain.java, IR/Tree/ToTree.java, Interpret/Tree/DefaultFrame.java, Backend/StrongARM/CodeGen.spec.coarseInstrs, Backend/StrongARM/CodeGen.spec.instrGroups, Backend/StrongARM/Frame.java, Backend/StrongARM/CodeGen.spec, Backend/Sparc/CodeGen.spec, Backend/Sparc/Frame.java, Backend/Runtime1/DataReflection1.java, Backend/Runtime1/DataReflection2.java, Backend/Runtime1/DataReflectionMemberList.java, Backend/Runtime1/DataStaticFields.java, Backend/Runtime1/DataStrings.java, Backend/Runtime1/MallocAllocationStrategy.java, Backend/Runtime1/ObjectBuilder.java, Backend/Runtime1/Runtime.java, Backend/Runtime1/SPAllocationStrategy.java, Backend/Runtime1/StubCode.java, Backend/Runtime1/TreeBuilder.java, Backend/Runtime2/Runtime.java, Backend/Runtime2/TreeBuilder.java, Backend/Runtime1/AppelAllocationStrategy.java, Backend/Runtime1/DataClaz.java, Backend/Runtime1/DataGC.java, Backend/Runtime1/DataInitializers.java, Backend/Runtime1/DataInterfaceList.java, Backend/Runtime1/DataJavaMain.java, Backend/PreciseC/Frame.java, Backend/PreciseC/PGCNiftyAllocationStrategyWithStats.java, Backend/MIPS/CodeGen.spec, Backend/MIPS/Frame.java, Backend/Generic/Frame.java, Backend/Generic/Runtime.java, Backend/Analysis/BasicGCInfo.java, Backend/Analysis/GCTraceStore.java, Backend/Analysis/MakeGCThreadSafe.java, Analysis/Tree/CacheEquivalence.java, Analysis/Transactions/TreePostPass.java, Analysis/Realtime/HeapCheckAdder.java, Analysis/Realtime/QuantaChecker.java, Analysis/Realtime/RealtimeRuntime.java: Refactor Frame-Runtime interface to allow creation of Frame and Runtime *before* we know the class hierarchy or call graph. This gets around several chicken-and-egg problems in Main/SAMain. The public final fields Runtime.treeBuilder and Runtime.nameMap have been turned into accessor methods Runtime.getTreeBuilder() and Runtime.getNameMap(). In a sane language, transforming a field to an accessor method would be completely invisible outside the class; unfortunately Java is not so sane. Most of the changes in this commit are simply dealing with the field-to-method conversion. Sigh. Incidentally, this is one of the features which (if I recall correctly) the C# language actually gets right. Or maybe it's not. I can't remember... * Analysis/SizeOpt/SizeCounters.java, Analysis/SizeOpt/package.html: Add simple size counter code to get numbers on object sizes/allocation frequency/etc. Also added a description of the 'harpoon.Analysis.SizeOpt' package. * Analysis/SizeOpt/SizeCounters.java, Analysis/SizeOpt/package.html: New file. * Analysis/Counters/CounterFactory.java: Allow counters to be incremented by both long and integer values. 2001-07-10 wbeebee * Support/realtime.jar, Analysis/Realtime/Realtime.java, Analysis/Realtime/HeapCheckAdder.java: Handles derived pointers correctly, by checking all base pointers. Heap checks now work! They're not the most efficient in the world, but they're correct!!! 2001-07-09 C. Scott Ananian * Backend/Runtime1/StubCode.java, Backend/PreciseC/TreeToC.java: Fix Karen's bug more-or-less correctly. As the note in TreeToC indicates, we still require tree form to have only one type over the lifetime of a temp (this is not quite the same as SSx form). But now we correctly generate StubCode that adheres to this requirement. I also moved the monitorEnter/Exit call so that we don't have to push anything on the precise variable stack around the call. This commit also reverts my ugly ugly Friday workaround that I promised to remove today. * Analysis/Tree/AlgebraicSimplification.java, Analysis/Tree/Simplification.java: As Wes pointed out, masking 'null' causes AlgebraicSimplification to attempt to do constant propagation on the (NULL & ~3) expression, failing because BINOP.evalValue() doesn't like nulls. And well it shouldn't: there's no guarantee that 'null' will really be zero. With pointer masking especially, 'null' could be any sufficiently small integer. So disable constant folding of 'null' constants. 2001-07-09 wbeebee * Support/realtime.jar, Backend/Runtime2/TreeBuilder.java, Analysis/Realtime/HeapCheckAdder.java, Analysis/Realtime/RealtimeRuntime.java: Fixed a bugs in HeapCheckAdder in creating MEM's with boolean types... fixed a bug in RealtimeRuntime that was inverting the sense of NOHEAP_CHECKS, and eliminated minor unnecessary false|| in TreeBuilder. 2001-07-09 C. Scott Ananian * Backend/Runtime1/Runtime.java, Backend/Runtime1/TreeBuilder.java, Backend/Runtime2/Runtime.java, Backend/Runtime2/TreeBuilder.java, Analysis/Realtime/RealtimeRuntime.java: Revert Wes' changes to make TreeBuilder constructor protected again, to indicate that it should only be invoked by either another class in its package (Runtime) or a subclass. Also added harpoon.runtime1.pointer.alignment property to runtime1 to allow pointer masking to be enabled from the command-line. * IR/Tree/ToTree.java, Backend/Runtime1/TreeBuilder.java, Backend/Generic/Runtime.java: Add proper pointer masking to reference comparisons. Note difference between Qop.ACMPEQ (which works on (unmasked) reference values) and LQop.PCMPEQ (which works on (masked) pointer values) here. * Backend/Runtime1/TreeBuilder.java: Refactor TreeBuilder code to catch quite a number of pointer-masking cases which had slipped through the first time. Thanks to Wes for finding these. We now rely more heavily on the _claz_() and fieldBase() methods in componentOf/instanceOf/initialization/etc which take care of the proper pointer masking for us. 2001-07-08 pnkfelix * Analysis/Instr/AppelRegAlloc.java: FSK: took out obsolete todo: note * Analysis/Instr/AppelRegAlloc.java, Analysis/Instr/AppelRegAllocClasses.java, Analysis/Instr/AppelRegAllocFsk.java, Analysis/Instr/AppelRegAllocStd.java, Analysis/Instr/RegAllocOpts.java, Analysis/Instr/SpillHeuristics.java: FSK: 1. Refactored out the key changes I've made to the FSK: standard Appel algorithm (at least the ones that FSK: are relevant to my thesis) into two concrete FSK: subclasses. FSK: 2. Refactored out the SpillHeuristics stuff into its FSK: own class, because it was big, heinous, confusing, FSK: and potentially not worth the effort (measuring the FSK: actual benefit of alternate spill-heuristics in FSK: the presence of optimistic-coloring is probably FSK: a paper in itself, or at least an interesting set FSK: of statistics. C:P ) FSK: 3. Added a new option to the reg-alloc-options reader FSK: to use the ARAFsk subclass instead of the ARAStd FSK: subclass. Who in their right mind chooses Reflection FSK: over this! C:) FSK: 4. Made some small interface modifications and documentation FSK: updates to Generic.RegFileInfo (to go along with my FSK: extensions) FSK: 5. Made StrongARM.RegFileInfo properly implement the FSK: extensions to Generic.RegFileInfo. * Analysis/Instr/AppelRegAllocFsk.java, Analysis/Instr/AppelRegAllocStd.java, Analysis/Instr/SpillHeuristics.java: New file. * Backend/Generic/RegFileInfo.java, Backend/StrongARM/RegFileInfo.java: FSK: 1. Refactored out the key changes I've made to the FSK: standard Appel algorithm (at least the ones that FSK: are relevant to my thesis) into two concrete FSK: subclasses. FSK: 2. Refactored out the SpillHeuristics stuff into its FSK: own class, because it was big, heinous, confusing, FSK: and potentially not worth the effort (measuring the FSK: actual benefit of alternate spill-heuristics in FSK: the presence of optimistic-coloring is probably FSK: a paper in itself, or at least an interesting set FSK: of statistics. C:P ) FSK: 3. Added a new option to the reg-alloc-options reader FSK: to use the ARAFsk subclass instead of the ARAStd FSK: subclass. Who in their right mind chooses Reflection FSK: over this! C:) FSK: 4. Made some small interface modifications and documentation FSK: updates to Generic.RegFileInfo (to go along with my FSK: extensions) FSK: 5. Made StrongARM.RegFileInfo properly implement the FSK: extensions to Generic.RegFileInfo. * Backend/StrongARM/CodeGen.spec.instrGroups: FSK: Discovered this particular nastiness: was creating FSK: a NO_SPILL group that was too long. This, combined FSK: with some overly conservative conflict mechanisms FSK: and a bad weighting on the edges in the interference FSK: graph led to the register allocator coughing up FSK: blood. I've fixed the weighting, but this was bad FSK: anyway (over-constrains allocation) so I've broken FSK: up the NO_SPILL area into two sections. 2001-07-07 pnkfelix * IR/Assem/InstrGroup.java: FSK: [checkpointing state of system before revision] FSK: Fixed up some javadoc in InstrGroup. * Analysis/Instr/RegAlloc.java: FSK: Removing unused method [phasing out notion of component temps] * Analysis/Instr/AppelRegAlloc.java: FSK: [making a full snapshot of the state of my system] FSK: The main changes here are that it now uses the spillable FSK: cache in the Web objects instead of recomputing its value FSK: each time, and the cleaning rewrite happens earlier in FSK: the control flow. FSK: Also removed a lot of crufty assertions left over from FSK: when my buggy code was breaking invariants left and right, FSK: and put some notes about things to look into regarding FSK: move coalescing and pre-spilling. * Backend/StrongARM/RegFileInfo.java: FSK: Alas, this also needed to be checked in. FSK: [perhaps I should have done a "test-checkin" FSK: by manually copying the changed interface FSK: to CTF first. But when I have done that in FSK: the past I've ended up forgetting to actually FSK: do the end checkin and have gotten burned for FSK: it] * Analysis/Instr/LocalCffRegAlloc.java, Backend/MIPS/RegFileInfo.java: FSK: oops. Interface revision in last checkin broke FSK: these files, so I'm checking them in. * Backend/Generic/RegFileInfo.java: FSK: Taking cruft out of interface for Generic.RegFileInfo. 2001-07-06 C. Scott Ananian * Backend/Runtime1/StubCode.java: This is an extremely ugly and unsafe hack that should, however, get the precise garbage collector working for Karen while I'm away for the weekend. I'll revert this change on Monday. 2001-07-06 wbeebee * Backend/Runtime1/TreeBuilder.java, Backend/Runtime2/Runtime.java, Backend/Runtime2/TreeBuilder.java, Analysis/Realtime/HeapCheckAdder.java, Analysis/Realtime/RealtimeRuntime.java: Now supports Scott's pointerAlignment field on TreeBuilder. Various changes to HeapCheckAdder to correctly deal with derived pointers in light of Scott's new changes. Was also happy to remove the GROSS HACK from Runtime2/TreeBuilder to get around dynamic inheritance, as just constructing the TreeBuilder of the correct Runtime in initTreeBuilder in RealtimeRuntime works just fine. 2001-07-06 C. Scott Ananian * Backend/Runtime1/TreeBuilder.java: As Wes correctly pointed out, I was missing a PTRMASK operation in the hashcode initialization code. Have to make sure that the low bits are available for other uses in the hashcode field. * Backend/Runtime1/TreeBuilder.java, IR/Tree/DerivationGenerator.java: Add support for masked pointers to Runtime1. There's a hack in DerivationGenerator to make it give proper derivations after a pointer AND, but it's a little overbroad, and will give derivations even when the AND completely obliterates the original pointer. It is currently the responsibility of the implementor to DECLARE a proper type for such constructions, to override the DerivationGenerator's guess. At some future point I may make the DerivationGenerator smarter about which pointer ANDs it generates derivations for, but not at the present moment (I'm about to leave the state for the weekend---ah, summertime!). There's also a loose end with respect to pointer comparisons. The code currently assumes that any twiddled low bits of the pointer are integral to it; it will not compare as equal with a pointer with different low bits. Sometimes you may want to mask the low bits before doing the comparison. At the time I wrote Generic.Runtime.TreeBuilder I never thought that *pointer-comparison* would be potentially runtime-dependent. I will probably eventually add another method to the generic TreeBuilder to allow the Runtime to specify proper handling of the compare operation. The Runtime1.TreeBuilder constructor could use some prettify-ing, too, but I want to make sure it's (eventually) possible to specify masking both programmatically (enabling realtime java also automagically enables pointer masking, for example) and from the command-line (-Dharpoon.runtime1.pointer_masking=true, or some such). Not done yet, but will be done after the weekend. Now it's time for people to bang on this code with pointer masking enabled and allocators that (say) set the low bit, and see if I missed any masking cases. I don't think so, but I'm not infallible. * Backend/Runtime1/ObjectBuilder.java: Reverting last change to ObjectBuilder. Not sure why, but changing the object alignment from 4 to 8 causes a segfault using the precise-c backend on SPEC _200_check. Maybe gcc or gas on x86 has some problem with 8-byte alignments? I'll debug this further after the weekend. We didn't really need 8-byte object alignments on any of our current platforms anyway. 2001-07-06 pnkfelix * Analysis/Instr/AppelRegAllocClasses.java: FSK: Added code to cache the isSpillable() property in the FSK: Web objects themselves, rather than needed to reloop FSK: over the defs/uses each time one chooses a spill. * Analysis/Instr/DemandDrivenRegAlloc.java: FSK: Code cleanups. I'm preparing to take care of removing some FSK: old crufty aspects of the allocation interface, but to do FSK: so I need to make sure that this legacy code doesn't cause FSK: compile breakage. 2001-07-06 C. Scott Ananian * Backend/Runtime1/ObjectBuilder.java: We should align objects to double-word boundaries so that longs and doubles are correctly aligned on those machines which require them to be double-word aligned. On x86 and StrongARM, they are not required to be aligned and malloc only 4-byte aligns the objects it returns, so it's not a big deal here, but SPARC is (as I recall) more strict. 2001-07-05 C. Scott Ananian * Backend/PreciseC/TreeToC.java: precise-c backend should handle derived pointers correctly when pointer-twiddling now. * Backend/Runtime1/TreeBuilder.java: Tweak harpoon.runtime1.nosync options: document better at top, make a private static final variable so that JITs can optimize, return objectref instead of CONST(0) because objectref expression might have side-effects. * IR/Tree/ToTree.java: Tweak property name for dispatch-checking option in ToTree. Use Boolean.getBoolean() instead of a raw System.getProperty() call. * IR/Quads/UnHandler.java: Allow the user to turn off generation of all array-bounds checks, for benchmarking purposes *only*! This basically allows you to hand-wave around performance decreases hypothesized to be due to non-optimization of array bounds checks tests. The Titanium compiler does it, why can't we? * Backend/Runtime1/TreeBuilder.java: Fix bug where derived pointers to static objects (pointed to by a NAME tree) were confusing the DerivationGenerator. You usually only saw this when using optimizations in your build. Since the gc doesn't need to know about static objects, we leave them typed HClass.Void instead of giving them a more precise type. Then nobody gets worried when we can't find a temp to associate with a derived pointer to the static object, later. 2001-07-04 bdemsky * Analysis/RoleInference/RoleInference.java: fixed bug in AGET handling code. * Analysis/RoleInference/RoleInference.java: Updates to roleinference pass to support load annotating. * Util/TypeInference/TypeInference.java: Bug in alex's treatment of AGET quad...Fixed now. 2001-07-04 C. Scott Ananian * Backend/Runtime1/StubCode.java: Fix bug in StubCode found by Karen: synchronized native methods were declaring their wrapped temps as unwrapped variables, which caused the precisec backend to spill the wrapped object to the object pointer stack --- only unwrapped objects belong on the object pointer stack. also, the spilling caused stack corruption, which was also a Bad Thing. Anyway, giving the temp the correct type fixes all these things, although you'll only notice the improvement if you were actually using a precise garbage collector. 2001-07-04 pnkfelix * Backend/StrongARM/RegFileInfo.java: FSK: Discovered last night (or I guess the night before last.. FSK: umm, Monday night) that Scott's allocator was using a FSK: slightly larger register pool than I was, which led to FSK: a suprisingly large decrease in performance for my FSK: allocator. This fixes that. 2001-07-03 pnkfelix * Analysis/Loops/LoopFinder.java: FSK: Rewrote another recursive function to use an explicit stack object. * Analysis/Instr/AppelRegAlloc.java: FSK: Checkpointing state of AppelRegAlloc as it currently compiles FSK: all of spec correctly as far as I can tell. FSK: FSK: 1. Added flag for whether to print Depth->Spill information during FSK: compilation. FSK: 2. Added an extension to cleaning that refuses to spill temps that FSK: will not be used after the basic block is finished. FSK: 3. Added a "dontSpillTheseDefs" field for supporting the above feature. FSK: Note to self: look into spill filtering smarter, as its current FSK: implementation could be quite inefficient in certain bad cases FSK: (which we probably don't encounter due to SSA form...) FSK: 4. Added a trivial move coalescing pass as a simple way to FSK: filter out some *really* dumb spill code. FSK: (e.g. ld a [b]; mov a, a; st a [b];) FSK: 5. Added a lot of really ugly timing calls because profiling with FSK: -Xrunhprof takes too damn long and I don't need such fine grain FSK: results. FSK: 6. Added Scott's simple spill heuristic to the set of heuristics I use, FSK: which enables building the LoopDepth map lazily. Also added a break FSK: out of the loop when no spilling is required (results in mucho FSK: speedup, at least 2x) FSK: 7. Added various code for lazy construction of LoopDepth map. Can now FSK: appeciate C's interpretation of the "static" keyword... FSK: 8. Reenabled move coalescing <> FSK: 9. Fixed a brown paper bag bug in the move coalescer [ s/&&/||/ ] FSK: A. Fixed another brown paper bag bug which was causing FSK: mucho problemo: adjacency(n) != adjList[n]. In my defense, those are FSK: really close textually... Andrew Appel should revise his naming FSK: conventions before writing his next textbook. C:P FSK: B. Fixed a yucky bag bug that was all my own. Don't allow code FSK: controlled by PRINT_XXX_INFO flags to have side-effects... I'm FSK: sure that one could write a thesis combining software macros with a FSK: type/effect-analysis to ensure such invariants at compile time. * Analysis/DomTree.java: FSK: Rewrote two recursive functions to use explicit stack FSK: objects because we were getting stack overflows FSK: on running LoopFinder analysis on _222_mpegaudio.p * Analysis/Instr/AppelRegAllocClasses.java: FSK: Changed my system to snapshot nearly all of the state FSK: before applying each spill heuristic. Not sure how FSK: much that hurt me on compile-time performance. This FSK: works correctly though, so I'm checking it in before FSK: I experiment with optimizing it out later. * Backend/StrongARM/CodeGen.spec.instrGroups: FSK: Some fixes to the InstrGroup-ified specfile that I made FSK: not too long ago but didn't check in. I think nearly FSK: all of the NO_REORDER groups turned out also be FSK: AGGREGATE groups... perhaps there should have been a FSK: group type hierarchy? Maybe. But I don't want to even consider FSK: such things for the time being. Maybe the real answer is I should FSK: have abstracted this into a pair of helper procedures in this spec FSK: file... 2001-07-03 wbeebee * Backend/Runtime1/TreeBuilder.java, Backend/Analysis/GCTraceStore.java, Analysis/Realtime/HeapCheckAdder.java, Analysis/Realtime/Realtime.java, Analysis/Realtime/RealtimeAllocationStrategy.java: Fixed a nasty bug in TreeBuilder. We should probably assert that the arguments to a BINOP are of the specified optype for all ops that this makes sense. HeapCheckAdder now works - also updated Realtime and RealtimeAllocationStrategy to now emit DEBUG_REF information when HEAP_CHECKS is turned on. GCTraceStore was cleaned up a little bit. 2001-07-03 C. Scott Ananian * Main/SAMain.java: The MemoryOptimization pass needs a caching code factory in front of it. * Analysis/Transformation/MethodSplitter.java: MethodSplitter was clearing entries from its codefactory cache before it was really done with them. The fixed version is safe, but it retains some entries in its cache longer than it ought. Eventually we should add a 'clearAll' method to CodeFactories which one could use to remedy such a situation after it has been determined that all methods have been processed through a certain HCodeFactory. * Analysis/Quads/SmallMethodInliner.java: Update SmallMethodInliner to much more accurately bloat the executable with inlined methods. The system property harpoon.inliner.percent allows you to specify more-or-less exactly how much code-size bloat you want, due to inlined methods. * Analysis/Quads/InitializerTransform.java: Fixed buglet in InitializerTransform that caused it to clear methods from its CodeFactory cache before it was really done using them. No effect on generated code; this fix ought to simply make compile times a little bit quicker. 2001-07-02 C. Scott Ananian * Util/Collections/BinaryHeap.java: More efficient implementation of updateKey(). * Util/Collections/AbstractHeap.java, Util/Collections/BinaryHeap.java, Util/Collections/BinomialHeap.java, Util/Collections/FibonacciHeap.java: Fixed an interface buglet: the protected setKey() method of AbstractHeap should really return the old key of the Map.Entry. * Util/Collections/AbstractHeap.java, Util/Collections/BinaryHeap.java, Util/Collections/BinomialHeap.java, Util/Collections/FibonacciHeap.java, Util/Collections/Heap.java: Added 'updateKey()' method to Heap interface. This usually has poorer performance guarantees than 'decreaseKey()' and is almost (but not quite exactly) the same as a 'delete()' followed by an 'insert()' with the new key value (delete-than-insert would change the Map.Entry associated with the key-value pair, while 'updateKey()' maintains it). Refactored some code in AbstractHeap to make this easier to implement, without undue code duplication. Also added testcases for the updateKey() method to the various heap implementations. It is possible to slightly-more-efficiently implement 'updateKey()' by changing the BinomialHeap and FibonacciHeap data structures slightly. I believe the time-bounds change to requiring O(lg n) time for m calls to 'updateKey()' instead of O(m lg n). Implementation is deferred until it can be shown truely necessary. See the discussion at the end of section 3 of "A Data Structure for Manipulating Priority Queues" by Jean Vuillemin in Communications of the ACM 21(4) for the change to BinomialHeap; and the "good-tree/bad-tree" variant of FibonacciHeap discussed in section 3 of "Fibonacci Heaps and Their Uses in Improved Network Optimization Algorithms" by Fredman and Tarjan in Journal of the ACM 34(3). A trivial modification applies to BinaryHeap to make updateKey more efficient (calling downHeap rather than upHeap if the key is increasing); I will implement this in the next commit. 2001-07-02 wbeebee * Support/realtime.jar, Main/SAMain.java, Backend/Analysis/GCTraceStore.java: Added GCTraceStore, and support for it. GCTraceStore adds a C function call for every store to a memory location of type POINTER. Also, cleaned up HeapCheckAdder a little. * Backend/Analysis/GCTraceStore.java: New file. * Analysis/Realtime/HeapCheckAdder.java, Analysis/Realtime/Realtime.java: Added GCTraceStore, and support for it. GCTraceStore adds a C function call for every store to a memory location of type POINTER. Also, cleaned up HeapCheckAdder a little. * Analysis/Realtime/PrintFactory.java: New file. * Analysis/Realtime/HeapCheckAdder.java, Analysis/Realtime/PrintFactory.java, Analysis/Realtime/Realtime.java, Analysis/Realtime/RealtimeAllocationStrategy.java, Analysis/Realtime/RealtimeRuntime.java, Analysis/Realtime/package.html: Now supports RTJ_DEBUG_REF in the compiler - also made some improvements to try to support NoHeapRealtimeThread checks against the heap in HeapCheckAdder.java. Updated package.html to describe the new RTJ resources that I found, and added PrintFactory (which may be moved out to a more general location) that facilitates printing HCodes that pass through an HCodeFactory (of any form). 2001-06-30 C. Scott Ananian * Util/Collections/Heap.java: Add javadoc references to FibonacciHeap implementation. * Analysis/Tree/DerivationChecker.java: Better error message output from DerivationChecker if it finds something wrong. * Main/SAMain.java: Turn on tree-form derivation checkers. * Analysis/Tree/Canonicalize.java: Fix bug in Canonicalize where derivation information would get lost from a MOVE(MEM(...), ...) subtree. * Analysis/Quads/MemoryOptimization.java: Allow memory optimization of final fields across synchronizations, since writes to final fields cannot escape a thread. We also tweak the optimization across calls, but this is expected to have less (read, no) effect, since we'll never see writes to final fields. 2001-06-29 C. Scott Ananian * Analysis/Tree/DerivationChecker.java: Added a new derivation-checker for tree form, based on the lowquad-form checker. @SPLIT: Analysis/LowQuad/DerivationChecker Analysis/Tree/DerivationChecker@ * Analysis/Tree/DerivationChecker.java: New file. * Analysis/LowQuad/DerivationChecker.java: Whoops: actually checked in an (entirely unnecessary) import * statement. * Analysis/LowQuad/DerivationChecker.java: Moved low-quad derivation checker to more-appropriate Analysis package instead of IR. @RENAME: IR/LowQuad Analysis/LowQuad@ * Analysis/LowQuad/DerivationChecker.java: New file. * IR/LowQuad/DerivationChecker.java: Moved low-quad derivation checker to more-appropriate Analysis package instead of IR. @RENAME: IR/LowQuad Analysis/LowQuad@ * Backend/PreciseC/TreeToC.java: Fix bug which Wes found in the AND-with-pointer-argument-type construct. We should look at this closely if we ever port to a 64-bit architecture (actually, I think we've already got a sparc-64 port at least partially complete). In particular, the non-pointer portion of the mask MUST be an INTEGER for 32-bit archs and a LONG for 64-bit archs for this all to work correctly. Otherwise masks like "~3" will silently truncate the top 32-bits of the pointer on 64-bit archs. 2001-06-28 C. Scott Ananian * Backend/PreciseC/TreeToC.java: Allow AND operations on a pointer and an int (masking). 2001-06-27 C. Scott Ananian * GNUmakefile: Added Support/*-root-set to harpoon.tgz file 2001-06-26 kkz * Backend/Runtime1/DataClaz.java: Added support for handling arrays with fields in the GC. If you get this update you also need to make update the runtime. 2001-06-25 bdemsky * IR/Quads/Peephole.java: Brian needs to learn to spell. * IR/Quads/Peephole.java: Don't do optimization for METHOD quads. 2001-06-22 wbeebee * Support/realtime.jar: Started implementing compiler support for NoHeapRealtimeThreads. Cleaned up QuantaChecker. * Analysis/Realtime/HeapCheckAdder.java: New file. * Analysis/Realtime/HeapCheckAdder.java, Analysis/Realtime/QuantaChecker.java, Analysis/Realtime/Realtime.java, Main/SAMain.java: Started implementing compiler support for NoHeapRealtimeThreads. Cleaned up QuantaChecker. 2001-06-22 pnkfelix * IR/Assem/InstrGroup.java: FSK: heh heh. defs were getting skipped by InstrGroup. C:P FSK: (this is a backlash from when the semantics of InstrGroup FSK: were not well defined...) * Analysis/Instr/AppelRegAllocClasses.java: FSK: Added flag to disable snapshotting the NodePairSet, as a FSK: performance boost. * Backend/StrongARM/CodeGen.spec.instrGroups: FSK: 1. Noted that there's a untemplatized Label param. FSK: Doesn't break things now, but it would if we FSK: did jump retargetting. Added comment to fix it later FSK: (don't have time to test a fix of it right now) FSK: 2. Made InstrENTRY's defs for the method parameter registers. FSK: I think things should have been this way from the start. FSK: Not having it didn't break things, but it should have, which FSK: means that there's probably hacks distributed around the FSK: code base to get around it. C:P FSK: 3. Made a long-comparison operation an aggregate instr. FSK: Originally thought to be unnecessary, but if I manage to FSK: get rid of InstrDUMMYs using conservative group usedefing, FSK: then it will certainly break things to have this be FSK: non-aggregate. 2001-06-21 pnkfelix * Analysis/Instr/AppelRegAlloc.java: FSK: Darn; the last checkin I put in causes a compile FSK: error because I narrowed the permissions on FSK: two of the methods in AppelRegAllocClasses. C:P FSK: FSK: Anyway, this will fix that (since the new AppelRegAlloc FSK: doesn't call those methods at all) and also FSK: FSK: 1. Moves the decision to commit to a SpillHeuristic to FSK: AFTER optimistic coloring is performed. Thus, the FSK: SpillHeuristic selects a spill-set of variables to FSK: based on pessimistic spilling but the final cost is based on FSK: the actual spills performed. FSK: Actually, that makes me realize that the SpillHeuristics FSK: no longer need to maintain an expected cost during graph FSK: reduction. So I should take the accumExpCost and maxExpSpills FSK: fields out. FSK: FSK: 2. Optionally prints a SLEW of information about the costs FSK: gathered. This is useful because I have discovered that the FSK: alternate spill heuristics *DO* make a positive difference in FSK: the number of spills once the min heuristic function is chosen FSK: properly. Its just that they aren't useful very often. Might FSK: be interesting to actually chart how often they are used. FSK: FSK: 3. Also added a note to myself to investigate whether I was on FSK: crack when I disabled move coalescing. FSK: FSK: 4. Oh yeah, forgot to mention in my last message that the FSK: NodePairSet field has migrated up to AppelRegAllocClasses FSK: along with everybody else. I actually think I might be able FSK: to justify this seperation of concerns now. Should I still FSK: switch AppelRegAllocClasses to a non-superclass of FSK: AppelRegAlloc? A lot of rewriting without much justification, FSK: except that the snapshot code might be simplified FSK: significantly by making the ARAC a seperate entity. FSK: FSK: And a final comment that the code wrapped around the appel-loop FSK: has gotten really hairy. It was bad enough before, but now the FSK: control flow is really convoluted. Should look into cleaning FSK: that up. * Analysis/Instr/AppelRegAllocClasses.java: FSK: Added a bunch of code for taking snapshots of the register FSK: allocation state and for writing it to a string for sanity FSK: checking. However, on further investigation, it seems that the FSK: reasons that multiple spill-heuristics were giving poor output FSK: may have been due to something other than lack of sufficient FSK: state in the snapshots. FSK: FSK: Notably, the three spill-heuristics [given by Pinter] have a FSK: *much* larger average error in their cost estimate after FSK: optimistic coloring is applied than the spill-heuristic given by FSK: Chaitin. FSK: FSK: This means that if you commit to a spill-heuristic too soon (for FSK: example, basing your decision only on the expected maximum number FSK: of spills) then you will get POORER output than if you had just FSK: used Chaitin's alone. FSK: FSK: I find this quite amazing, given that Chaitin's heuristic is so FSK: simple. I wonder what demons he had to sacrifice a lamb for to FSK: find that particular cost function 2001-06-20 pnkfelix * Analysis/Instr/AppelRegAlloc.java, Analysis/Instr/AppelRegAllocClasses.java: FSK: Earlier refactoring was a little bit overzealous; moved FSK: a field back down to AppelRegAllloc. * Analysis/Instr/AppelRegAlloc.java, Analysis/Instr/AppelRegAllocClasses.java: FSK: moved the Move class up into AppelRegAllocClasses as FSK: a refactoring of the code in preperation for implementing FSK: graph-reset properly. * Analysis/Instr/RegAllocOpts.java: FSK: Clarified some of the documentation for the regalloc options file. * Analysis/Instr/RegAlloc.java: FSK: Added "reachableInstrs()" helper method to RegAlloc, which FSK: generates an iterator over the, you guessed it, reachable FSK: Instrs. FSK: Thanks to Scott for pointing out that the AppelRegAlloc I FSK: checked in last night fails to compile without this. 2001-06-19 pnkfelix * Analysis/Instr/AppelRegAlloc.java: FSK: 1. Finally fixed cleaning so that FSK: a.) extra defs are removed (opportunity rarely encountered FSK: though) FSK: b.) the first uses after a def in a BB isn't reloaded from FSK: memory (much more common) FSK: This was actually much harder to do than I expected it to be. FSK: Notably, turning off cleaning isn't just setting a bit; you FSK: also want to tell the spiller that its okay to respill temps FSK: that you had spilled earlier with cleaning on, because FSK: sometimes those are the ones that are forcing your hand. The FSK: paper that talked about cleaning didn't really make this point FSK: clear... FSK: (I hadn't encountered this before because the "long" ranges FSK: resulting from cleaning were never that long until (b) above FSK: was implemented. Then I got my shit tossed.) FSK: FSK: Anyway, the way I ended up doing this was to remove all FSK: previous spill code, and *then* set a bit. This sounds FSK: inefficient, but this situation is rarely encountered, and its FSK: done at most once per method, so its acceptable. FSK: FSK: Also, added some code to turn off cleaning earlier than just FSK: two cycles into allocation if necessary. Notably, if our FSK: spiller can't find a node to spill, that's a sign that FSK: cleaning is screwing us over. FSK: FSK: 2. Put in the warning about emitting unreachable code, just like FSK: we have in GraphColoringRegAlloc. This is a side-effect of FSK: the need to hack in allocation on unreachable code. FSK: Preferably we'd want to get rid of the original source of the FSK: unreachable code, but that's not a project I'd want to get FSK: myself into at this point. FSK: FSK: 3. Switched from only gather global (program-wide) spill FSK: statistics to gathering and printing both method-local and FSK: global stats. This was a side-effect of the removing all FSK: spill code thing; it was easier to reset a local dataset than FSK: to try to backtrack on a global one. Plus the numbers are FSK: much more readable this way (though the actual information FSK: content is pretty much unchanged). * Main/SAMain.java: FSK: No one else uses the -P option but us lowly assembly-targetting folk, FSK: but I'm still gonna maintain it. FSK: It was dying because of the peephole optimizations I put into print() FSK: for Emmett. So I fixed it to use something other than print(). * Analysis/BasicBlock.java: FSK: Made an expensive assertion message a little easier to turn FSK: on and off (haven't found the need for a debug flag for this FSK: one yet though) FSK: Added a toString() method to BasicBlock.Factory that FSK: prints its BasicBlocks [ for nice low-cost use with the FSK: Util.assert(String,Object) method ] * IR/Assem/Instr.java, IR/Assem/InstrDIRECTIVE.java, IR/Assem/InstrLABEL.java: FSK: Added a little more intelligence about handling groups FSK: when replacing and removing Instrs, including an assert FSK: for a case I'm not sure how to handle yet. FSK: Also added "isDirective()" and "isLabel()" predicate FSK: methods to Instr's specification, and corresponding implementations FSK: where known to me to be appropriate. * IR/Assem/InstrGroup.java: *** empty log message *** * IR/Assem/InstrGroup.java: FSK: A collection of fixes reflecting the change from the FSK: Group->!Instr representational mapping to the entry/exit pair of FSK: mappings. Am a bit unnerved by the fact that this "legacy code" FSK: bug (if you can call code that young legacy) didn't arise FSK: earlier, but it was definitely wrong, so I'm thankful for having FSK: caught it. 2001-06-18 witchel * Analysis/Tree/DominatingMemoryAccess.java: Rip out my old crufty code. This is in preparation for turning DominatingMemoryAccess into a lean, mean, multi-use analysis machine. * Backend/MIPS/CodeGen.spec: Replace broken long to float conversion with a working long to float conversion. 2001-06-18 C. Scott Ananian * Main/EventDriven.java, Backend/Runtime1/DataGC.java, Backend/Runtime1/SPAllocationStrategy.java, Backend/Generic/GCInfo.java, Backend/Analysis/BasicGCInfo.java, Backend/Analysis/MakeGCThreadSafe.java, Analysis/Quads/QuadLiveness.java, Analysis/EventDriven/AsyncCode.java, Analysis/EventDriven/ContCode.java, Analysis/EventDriven/ContCodeNoSSA.java, Analysis/EventDriven/ContCodeSSI.java, Analysis/EventDriven/EventDriven.java, Analysis/EventDriven/EventDrivenCode.java, Analysis/EventDriven/LockRemove.java, Analysis/EventDriven/ToAsync.java, Analysis/EnvBuilder/EnvBuilder.java, Analysis/EnvBuilder/EnvCode.java, Analysis/ContBuilder/ContBuilder.java, Analysis/Liveness.java, Analysis/ReachingDefsImpl.java, Analysis/AllCallers.java: Ran bin/copyright.perl to update Karen's email address as per her commit. * Main/SAMain.java: Turn on the small method inliner. * Analysis/Quads/MethodInliningCodeFactory.java: Final bug fix to MethodInliningCodeFactory. It