aboutsummaryrefslogtreecommitdiff
path: root/lib
AgeCommit message (Collapse)Author
2004-04-23* Allow aggregating extracted function arguments (controlled by flag)Misha Brukman
* Commandline option (for now) controls that flag that is passed in git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13141 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-23Fix a typo.Brian Gaeke
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13136 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-23Move the scev expansion code into this pass, where it belongs. There isChris Lattner
still room for cleanup, but at least the code modification is out of the analysis now. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13135 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-23Eliminate all of the SCEV Expansion code which is really part of theChris Lattner
IndVars pass, not part of SCEV *analysis*. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13134 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-23Merge TargetRegInfo.h into SparcV9RegInfo.h, which is its only subclass.Brian Gaeke
This prepares us to be able to de-virtualize and de-abstract it, and take the register allocator bits out and move them into the register allocator proper... git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13127 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-23Include SparcV9RegInfo.h instead of TargetRegInfo.h.Brian Gaeke
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13126 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-23Include SparcV9RegInfo.h instead of TargetRegInfo.h. This serves as a bit ofBrian Gaeke
documentation that this module needs to be made independent of the register file description of the current target. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13125 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-23Get rid of the old byte-at-a-time emission code used when the Sparc JIT wasBrian Gaeke
being tested on X86, as per Chris's request. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13124 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-23Go back to the interpreter main loop after performing intrinsic lowering,Brian Gaeke
because 1) the first instruction might not be a call site, and 2) CS and SF.Caller were not getting set to point to the new call site anyway (resulting in a crash on e.g. call %llvm.memset). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13122 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-23Use emitWordAt() to emit forward-branch fixups.Brian Gaeke
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13120 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-23Emit SPARC machine code a word at a time instead of a byte at a time.Brian Gaeke
Use emitWordAt() to emit forward-branch fixups. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13119 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-23Implement emitWordAt() for the JIT emitter.Brian Gaeke
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13118 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-23Implement emitWordAt() for the debug emitter and the file printer emitter. (IBrian Gaeke
am not so sure about the file printer emitter, but the debug emitter change should be harmless.) git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13117 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-22Clarify the logic: the flag is renamed to `deleteFn' to signify it will deleteMisha Brukman
the function instead of isolating it. This also means the condition is reversed. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13112 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-22Add a flag to choose between isolating a function or deleting the function fromMisha Brukman
the Module. The default behavior keeps functionality as before: the chosen function is the one that remains. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13111 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-22Disable a previous patch that was causing indvars to loop infinitely :(Chris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13108 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-22Fix an extremely serious thinko I made in revision 1.60 of this file.Chris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13106 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-21Implement a todo, rewriting all possible scev expressions inside of theChris Lattner
loop. This eliminates the extra add from the previous case, but it's not clear that this will be a performance win overall. Tommorows test results will tell. :) git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13103 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-21This code really wants to iterate over the OPERANDS of an instruction, notChris Lattner
over its USES. If it's dead it doesn't have any uses! :) Thanks to the fabulous and mysterious Bill Wendling for pointing this out. :) git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13102 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-21Implement a fixme. The helps loops that have induction variables of differentChris Lattner
types in them. Instead of creating an induction variable for all types, it creates a single induction variable and casts to the other sizes. This generates this code: no_exit: ; preds = %entry, %no_exit %indvar = phi uint [ %indvar.next, %no_exit ], [ 0, %entry ] ; <uint> [#uses=4] *** %j.0.0 = cast uint %indvar to short ; <short> [#uses=1] %indvar = cast uint %indvar to int ; <int> [#uses=1] %tmp.7 = getelementptr short* %P, uint %indvar ; <short*> [#uses=1] store short %j.0.0, short* %tmp.7 %inc.0 = add int %indvar, 1 ; <int> [#uses=2] %tmp.2 = setlt int %inc.0, %N ; <bool> [#uses=1] %indvar.next = add uint %indvar, 1 ; <uint> [#uses=1] br bool %tmp.2, label %no_exit, label %loopexit instead of: no_exit: ; preds = %entry, %no_exit %indvar = phi ushort [ %indvar.next, %no_exit ], [ 0, %entry ] ; <ushort> [#uses=2] *** %indvar = phi uint [ %indvar.next, %no_exit ], [ 0, %entry ] ; <uint> [#uses=3] %indvar = cast uint %indvar to int ; <int> [#uses=1] %indvar = cast ushort %indvar to short ; <short> [#uses=1] %tmp.7 = getelementptr short* %P, uint %indvar ; <short*> [#uses=1] store short %indvar, short* %tmp.7 %inc.0 = add int %indvar, 1 ; <int> [#uses=2] %tmp.2 = setlt int %inc.0, %N ; <bool> [#uses=1] %indvar.next = add uint %indvar, 1 *** %indvar.next = add ushort %indvar, 1 br bool %tmp.2, label %no_exit, label %loopexit This is an improvement in register pressure, but probably doesn't happen that often. The more important fix will be to get rid of the redundant add. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13101 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-21Fix an incredibly nasty iterator invalidation problem. I am too spoiled by ↵Chris Lattner
ilists :) Eventually it would be nice if CallGraph maintained an ilist of CallGraphNode's instead of a vector of pointers to them, but today is not that day. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13100 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-21I'm allergic to the word `stuff'.Misha Brukman
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13096 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-21Make SparcV9RegInfo::getRegType() return the right answer for registersBrian Gaeke
of IntCC, FloatCC, and Special types. Make SparcV9RegInfo::getRegClassIDOfRegType() return the right answer if you ask for the class corresponding to SpecialRegType. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13095 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-21Include cerrno (gcc-3.4 fix)Alkis Evlogimenos
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13091 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-21Fix typeoChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13089 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-20REALLY fix PR324: don't delete linkonce functions until after the SCC traversalChris Lattner
is done, which avoids invalidating iterators in the SCC traversal routines git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13088 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-20Pass the callgraph not the moduleChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13087 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-20Add the ability for SCC passes to initialize and finalize themselvesChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13084 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-20Fix PR325Chris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13081 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-20Fix PR324 and testcase: Inline/2004-04-20-InlineLinkOnce.llxChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13080 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-20Make it legal to ask for the type of a specialregBrian Gaeke
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13078 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-20Add support for the select instructionChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13076 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-19Make it legal to request a load or store of %fsr.Brian Gaeke
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13073 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-19Regularize include guards and remove some excess whitespace.Brian Gaeke
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13071 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-19Tighten up SparcV9FloatCCRegClass::getRegName()'s assertion - if you ask it forBrian Gaeke
the name of %fsr (as the comment in SparcV9RegClassInfo.h used to suggest) you would walk off the end of the FloatCCRegName array. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13070 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-19Regularize include guards, remove some excess whitespace and fix some comments.Brian Gaeke
Remove the extra %fsr register from SparcV9FloatCCRegClass. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13069 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-19Initial checkin of a simple loop unswitching pass. It still needs work,Chris Lattner
but it's a start, and seems to do it's basic job. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13068 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-19It's not just a printer, it's actually an analysis tooChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13064 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-19Remove code to update loop depthsChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13058 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-19Add #includeChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13057 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-18Move isLoopInvariant to the Loop classChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13051 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-18Add new methodChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13050 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-18Correct rewriting of exit blocks after my last patchChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13048 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-18Fix computation of exit blocksChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13047 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-18Loop exit sets are no longer explicitly held, they are dynamically computed ↵Chris Lattner
on demand. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13046 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-18Change the ExitBlocks list from being explicitly contained in the LoopChris Lattner
structure to being dynamically computed on demand. This makes updating loop information MUCH easier. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13045 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-18Reduce the unrolling limitChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13040 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-18If the preheader of the loop was the entry block of the function, make sureChris Lattner
that the exit block of the loop becomes the new entry block of the function. This was causing a verifier assertion on 252.eon. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13039 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-18Be much more careful about how we update instructions outside of the loopChris Lattner
using instructions inside of the loop. This should fix the MishaTest failure from last night. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13038 91177308-0d34-0410-b5e6-96231b3b80d8
2004-04-18Implement methodChris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13036 91177308-0d34-0410-b5e6-96231b3b80d8