Andrew Lenharth
08ff634c2b
prevent va_arg from being hoisted from a loop
...
llvm-svn: 22265
2005-06-20 13:36:33 +00:00
Andrew Lenharth
a9214fec08
core changes for varargs
...
llvm-svn: 22254
2005-06-18 18:34:52 +00:00
Misha Brukman
53e199440e
Remove trailing whitespace
...
llvm-svn: 21427
2005-04-21 23:48:37 +00:00
Chris Lattner
4f4fa287ee
Fix a bug where LICM was not updating AA information properly when sinking
...
a pointer value out of a loop causing it to be duplicated.
llvm-svn: 20828
2005-03-25 00:22:36 +00:00
Chris Lattner
1dbe1592ed
enable -debug-only=licm
...
llvm-svn: 20788
2005-03-23 21:00:12 +00:00
Chris Lattner
3a260f9757
Adjust to new interfaces
...
llvm-svn: 18958
2004-12-15 07:22:25 +00:00
Chris Lattner
ba782edfb7
Allow hoisting loads of globals and alloca's in conditionals.
...
llvm-svn: 18363
2004-11-29 21:26:12 +00:00
Chris Lattner
8715ef738f
Provide size information when checking to see if we can LICM a load, this
...
allows us to hoist more loads in some cases.
llvm-svn: 18265
2004-11-26 21:20:09 +00:00
Chris Lattner
5751f19d86
Fix a bug in the previous checkin that broke 255.vortex
...
llvm-svn: 16355
2004-09-15 02:34:40 +00:00
Chris Lattner
6833186048
Make sure to update alias analysis information as we transform the function.
...
This fixes PR420 and Regression/Transforms/LICM/2004-09-14-AliasAnalysisInvalidate.llx
llvm-svn: 16348
2004-09-15 01:04:07 +00:00
Reid Spencer
c4abcbefb1
Changes For Bug 352
...
Move include/Config and include/Support into include/llvm/Config,
include/llvm/ADT and include/llvm/Support. From here on out, all LLVM
public header files must be under include/llvm/.
llvm-svn: 16137
2004-09-01 22:55:40 +00:00
Chris Lattner
5cfb85064e
Fix hoisting of void typed values, e.g. calls
...
llvm-svn: 15263
2004-07-27 07:38:32 +00:00
Chris Lattner
39a31b56ac
Now that dominator tree children are built in determinstic order, this horrible code
...
can go away
llvm-svn: 14254
2004-06-19 20:23:35 +00:00
Chris Lattner
185f2b060b
Fix one source of nondeterminism in the -licm pass: the hoist pass
...
was processing blocks in whatever order they happened to end up in the
dominator tree data structure. Force an ordering.
llvm-svn: 14248
2004-06-19 08:56:43 +00:00
Brian Gaeke
a46100448f
Fix typo in DEBUG printout.
...
llvm-svn: 14196
2004-06-17 07:26:52 +00:00
Chris Lattner
cf81f974b8
Adjust to the changes in the AliasSetTracker interface
...
llvm-svn: 13690
2004-05-23 21:20:19 +00:00
Chris Lattner
ab6502f058
Move isLoopInvariant to the Loop class
...
llvm-svn: 13051
2004-04-18 22:46:08 +00:00
Chris Lattner
8e42c6f409
Loop exit sets are no longer explicitly held, they are dynamically computed on demand.
...
llvm-svn: 13046
2004-04-18 22:15:13 +00:00
Chris Lattner
8a82176edc
Implement LICM of calls in simple cases. This is sufficient to move around
...
sin/cos/strlen calls and stuff. This implements:
LICM/call_sink_pure_function.ll
LICM/call_sink_const_function.ll
llvm-svn: 12415
2004-03-15 04:11:30 +00:00
Chris Lattner
343ab20a2d
Update comment
...
llvm-svn: 11082
2004-02-02 20:09:22 +00:00
Chris Lattner
1736f44b1d
Improve encapsulation in the Loop and LoopInfo classes by eliminating the
...
getSubLoops/getTopLevelLoops methods, replacing them with iterator-based
accessors.
llvm-svn: 10714
2004-01-08 00:09:44 +00:00
Chris Lattner
399d5ad32e
Remove the wierd "Operands" loop, by traversing basicblocks in reverse order
...
llvm-svn: 10536
2003-12-19 08:18:16 +00:00
Chris Lattner
68db81e684
Implement LICM/sink_multiple.ll, by sinking all possible instructions in the
...
loop before hoisting any.
llvm-svn: 10534
2003-12-19 07:22:45 +00:00
Chris Lattner
17122cbe7b
When we delete instructions from the loop, make sure to remove them from the
...
AliasSetTracker as well.
llvm-svn: 10507
2003-12-18 08:12:32 +00:00
Chris Lattner
0d3a8b1cb4
Do not promote volatile alias sets into registers
...
llvm-svn: 10458
2003-12-14 04:52:31 +00:00
Chris Lattner
1f7737b44f
Fix LICM/2003-12-11-SinkingToPHI.ll, and quite possibly all of the other known problems in the universe.
...
llvm-svn: 10409
2003-12-11 22:23:32 +00:00
Chris Lattner
6eae2a120e
Fix bug: LICM/sink_multiple_exits.ll
...
Thanks for pointing this out John :)
llvm-svn: 10387
2003-12-10 22:35:56 +00:00
Chris Lattner
9b1a0ca03b
Don't allow dead instructions to stop sinking early.
...
llvm-svn: 10386
2003-12-10 20:43:29 +00:00
Chris Lattner
d6d41b5e23
Simplify code
...
llvm-svn: 10371
2003-12-10 16:58:24 +00:00
Chris Lattner
7eff699231
Avoid performing two identical lookups when one will suffice
...
llvm-svn: 10370
2003-12-10 16:57:24 +00:00
Chris Lattner
94944ee4aa
Make LICM itself a bit more efficient, and make the generated code more efficient too: don't insert a store in every exit block, because a particular block may be exited to more than once by a loop
...
llvm-svn: 10369
2003-12-10 15:56:24 +00:00
Chris Lattner
fe8fd04cce
Implement instruction sinking out of loops. This still can do a little bit
...
better job, but this is the majority of the work. This implements
LICM/sink*.ll
llvm-svn: 10358
2003-12-10 06:41:05 +00:00
Chris Lattner
f5f65c4000
Refactor code a little bit, eliminating the gratuitous InstVisitor, which
...
should make subsequent changes simpler. This also allows us to hoist vaarg
and vanext instructions
llvm-svn: 10342
2003-12-09 19:32:44 +00:00
Chris Lattner
2ffca818b6
Fine grainify namespacification
...
Code cleanups
Make LICM::SafeToHoist marginally more efficient
llvm-svn: 10341
2003-12-09 17:18:00 +00:00
Brian Gaeke
d25f86d683
Put all LLVM code into the llvm namespace, as per bug 109.
...
llvm-svn: 9903
2003-11-11 22:41:34 +00:00
Misha Brukman
acc53cc7c6
Declare FunctionPasses as such so that they can be used in FunctionPassManager.
...
llvm-svn: 9768
2003-11-07 17:20:18 +00:00
John Criswell
b402729b30
Added LLVM project notice to the top of every C++ source file.
...
Header files will be on the way.
llvm-svn: 9298
2003-10-20 19:43:21 +00:00
Chris Lattner
7a5241cc99
Wrap code at 80 columns
...
llvm-svn: 9073
2003-10-13 05:04:27 +00:00
Chris Lattner
f4ca01758d
Rename loop preheaders pass to loop simplify
...
llvm-svn: 9061
2003-10-12 21:52:28 +00:00
Misha Brukman
868eac95dd
Fix spelling.
...
llvm-svn: 9027
2003-10-10 17:57:28 +00:00
Chris Lattner
d1c3f771f8
Change the interface to PromoteMemToReg to also take a DominatorTree
...
llvm-svn: 8883
2003-10-05 21:20:13 +00:00
Chris Lattner
3d39abeeb7
Renamed DominatorTree::Node::getNode() -> getBlock()
...
llvm-svn: 8469
2003-09-11 16:26:13 +00:00
Misha Brukman
d8279c4406
Spell `definite' correctly.
...
llvm-svn: 8467
2003-09-11 15:32:37 +00:00
Chris Lattner
58d4183a25
Fix spell-o's
...
llvm-svn: 8431
2003-09-10 05:29:43 +00:00
Chris Lattner
03b8e81aef
Do not hoist volatile loads
...
llvm-svn: 8399
2003-09-08 18:17:14 +00:00
Tanya Lattner
6fbe85279f
Fixed minor bug in SafeToHoist and made some changes suggested by Chris.
...
llvm-svn: 7614
2003-08-05 20:39:02 +00:00
Tanya Lattner
48745a598c
Fixed LICM bug that hoists trapping instructions that are not guaranteed to execute.
...
llvm-svn: 7612
2003-08-05 18:45:46 +00:00
Chris Lattner
686e94e760
DEBUG got moved to Support/Debug.h
...
llvm-svn: 7492
2003-08-01 22:15:03 +00:00
Chris Lattner
db6b7ba364
Remove unnecesary &*'s
...
llvm-svn: 5872
2003-04-23 16:37:45 +00:00
Chris Lattner
4eaaa99b93
Convert LICM over to use AliasSetTracker. Besides being nicer, this automatically
...
allows LICM to use access sizes to help alias analysis be more precise.
llvm-svn: 5693
2003-03-03 23:32:45 +00:00