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: