summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Transforms
Commit message (Collapse)AuthorAgeFilesLines
* Don't load values out of global constants with weakDuncan Sands2009-03-203-6/+8
| | | | | | | | | linkage: the value may be replaced with something different at link time. (Frontends that want to allow values to be loaded out of weak constants can give their constants weak_odr linkage). llvm-svn: 67407
* Clear the cached cost when removing a function inDale Johannesen2009-03-192-10/+17
| | | | | | | | | the inliner; prevents nondeterministic behavior when the same address is reallocated. Don't build call graph nodes for debug intrinsic calls; they're useless, and there were typically a lot of them. llvm-svn: 67311
* Fix comment typo.Dale Johannesen2009-03-191-1/+1
| | | | llvm-svn: 67307
* This pass keeps a map of Instructions to Rank numbers,Dale Johannesen2009-03-191-8/+14
| | | | | | | | | and was deleting Instructions without clearing the corresponding map entry. This led to nondeterministic behavior if the same address got allocated to another Instruction within a short time. llvm-svn: 67306
* Remove strange extra semicolons.Nick Lewycky2009-03-192-2/+2
| | | | llvm-svn: 67287
* aha, DAE does have to think about PHI nodes. Many thanks to "Dr Evil" (aka ↵Chris Lattner2009-03-181-3/+3
| | | | | | | | Duncan) for pointing this out :) llvm-svn: 67212
* Fix PR3826 - InstComb assert with vector shift, by not calling ↵Chris Lattner2009-03-181-7/+8
| | | | | | ComputeNumSignBits on a vector. llvm-svn: 67211
* add an assertion to make it clear that PHI nodes are not allowed.Chris Lattner2009-03-181-1/+4
| | | | llvm-svn: 67210
* Explicitly check for StoreInst, do not lose the chance to delete Zhou Sheng2009-03-181-1/+1
| | | | | | unused loads or bitcasts. llvm-svn: 67202
* Revert my previous change on Local.cpp, instead, fix the bug on scalarrepl.Zhou Sheng2009-03-182-4/+1
| | | | | | | If the instruction has no users, it is also not only used by debug info and should not be deleted. llvm-svn: 67194
* Fix a bug.Zhou Sheng2009-03-181-0/+3
| | | | | | If I->use_empty(), this method should return false. llvm-svn: 67180
* Fix PR3807 by inserting 'insertelement' instructions in the normal dest of Chris Lattner2009-03-181-5/+10
| | | | | | an invoke instead of after the invoke (in its block), which is invalid. llvm-svn: 67139
* LSR shouldn't ever try to hack on integer IV's larger than 64-bits. Right nowChris Lattner2009-03-171-0/+6
| | | | | | | | | it is not APInt clean, but even when it is it needs to be evaluated carefully to determine whether it is actually profitable. This fixes a crash on PR3806 llvm-svn: 67134
* Remove a condition which is always true.Chris Lattner2009-03-171-3/+3
| | | | llvm-svn: 67089
* Fix a debug info dependency in jump threading.Dale Johannesen2009-03-171-2/+5
| | | | llvm-svn: 67064
* Fix -strip-debug-declare to work when there areDale Johannesen2009-03-131-19/+17
| | | | | | llvm.global.variable's but no llvm.declare's. llvm-svn: 66977
* Fix PR3784: If the source of a phi comes from a bb ended with an invoke, ↵Evan Cheng2009-03-131-0/+6
| | | | | | | | make sure the copy is inserted before the try range (unless it's used as an input to the invoke, then insert it after the last use), not at the end of the bb. Also re-apply r66140 which was disabled as a workaround. llvm-svn: 66976
* Revert r66920. It was causing failures in the self-hosting buildbot (in releaseBill Wendling2009-03-134-7/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | mode). Running /Volumes/Sandbox/Buildbot/llvm/full-llvm/build/llvmCore/test/BugPoint/dg.exp ... FAIL: /Volumes/Sandbox/Buildbot/llvm/full-llvm/build/llvmCore/test/BugPoint/crash-narrowfunctiontest.ll Failed with signal(SIGBUS) at line 1 while running: bugpoint /Volumes/Sandbox/Buildbot/llvm/full-llvm/build/llvmCore/test/BugPoint/crash-narrowfunctiontest.ll -bugpoint-crashcalls -silence-passes > /dev/null 0 bugpoint 0x0035dd25 llvm::sys::SetInterruptFunction(void (*)()) + 85 1 bugpoint 0x0035e382 llvm::sys::RemoveFileOnSignal(llvm::sys::Path const&, std::string*) + 706 2 libSystem.B.dylib 0x92f112bb _sigtramp + 43 3 libSystem.B.dylib 0xffffffff _sigtramp + 1829694831 4 bugpoint 0x00021d1c main + 92 5 bugpoint 0x00002106 start + 54 6 bugpoint 0x00000004 start + 18446744073709543220 Stack dump: 0. Program arguments: bugpoint /Volumes/Sandbox/Buildbot/llvm/full-llvm/build/llvmCore/test/BugPoint/crash-narrowfunctiontest.ll -bugpoint-crashcalls -silence-passes FAIL: /Volumes/Sandbox/Buildbot/llvm/full-llvm/build/llvmCore/test/BugPoint/misopt-basictest.ll Failed with signal(SIGBUS) at line 1 while running: bugpoint /Volumes/Sandbox/Buildbot/llvm/full-llvm/build/llvmCore/test/BugPoint/misopt-basictest.ll -dce -bugpoint-deletecalls -simplifycfg -silence-passes 0 bugpoint 0x0035dd25 llvm::sys::SetInterruptFunction(void (*)()) + 85 1 bugpoint 0x0035e382 llvm::sys::RemoveFileOnSignal(llvm::sys::Path const&, std::string*) + 706 2 libSystem.B.dylib 0x92f112bb _sigtramp + 43 3 libSystem.B.dylib 0xffffffff _sigtramp + 1829694831 4 bugpoint 0x00021d1c main + 92 5 bugpoint 0x00002106 start + 54 6 bugpoint 0x00000006 start + 18446744073709543222 Stack dump: 0. Program arguments: bugpoint /Volumes/Sandbox/Buildbot/llvm/full-llvm/build/llvmCore/test/BugPoint/misopt-basictest.ll -dce -bugpoint-deletecalls -simplifycfg -silence-passes FAIL: /Volumes/Sandbox/Buildbot/llvm/full-llvm/build/llvmCore/test/BugPoint/remove_arguments_test.ll Failed with signal(SIGBUS) at line 1 while running: bugpoint /Volumes/Sandbox/Buildbot/llvm/full-llvm/build/llvmCore/test/BugPoint/remove_arguments_test.ll -bugpoint-crashcalls -silence-passes 0 bugpoint 0x0035dd25 llvm::sys::SetInterruptFunction(void (*)()) + 85 1 bugpoint 0x0035e382 llvm::sys::RemoveFileOnSignal(llvm::sys::Path const&, std::string*) + 706 2 libSystem.B.dylib 0x92f112bb _sigtramp + 43 3 libSystem.B.dylib 0xffffffff _sigtramp + 1829694831 4 bugpoint 0x00021d1c main + 92 5 bugpoint 0x00002106 start + 54 Stack dump: 0. Program arguments: bugpoint /Volumes/Sandbox/Buildbot/llvm/full-llvm/build/llvmCore/test/BugPoint/remove_arguments_test.ll -bugpoint-crashcalls -silence-passes --- Reverse-merging (from foreign repository) r66920 into '.': U include/llvm/Support/CallSite.h U include/llvm/Instructions.h U lib/Analysis/IPA/GlobalsModRef.cpp U lib/Analysis/IPA/Andersens.cpp U lib/Bitcode/Writer/BitcodeWriter.cpp U lib/VMCore/Instructions.cpp U lib/VMCore/Verifier.cpp U lib/VMCore/AsmWriter.cpp U lib/Transforms/Utils/LowerInvoke.cpp U lib/Transforms/Scalar/SimplifyCFGPass.cpp U lib/Transforms/IPO/PruneEH.cpp U lib/Transforms/IPO/DeadArgumentElimination.cpp llvm-svn: 66953
* One more place where debug info affects codegen.Dale Johannesen2009-03-131-1/+2
| | | | llvm-svn: 66930
* Second installment of "BasicBlock operands to the back"Gabor Greif2009-03-134-7/+7
| | | | | | | | | | | | | | | | | | changes. For InvokeInst now all arguments begin at op_begin(). The Callee, Cont and Fail are now faster to get by access relative to op_end(). This patch introduces some temporary uglyness in CallSite. Next I'll bring CallInst up to a similar scheme and then the uglyness will magically vanish. This patch also exposes all the reliance of the libraries on InvokeInst's operand ordering. I am thinking of taking care of that too. llvm-svn: 66920
* Oops...I committed too much.Bill Wendling2009-03-132-34/+31
| | | | llvm-svn: 66867
* Temporarily XFAIL this test.Bill Wendling2009-03-132-31/+34
| | | | llvm-svn: 66866
* Fix one more place where debug info affectedDale Johannesen2009-03-131-2/+5
| | | | | | codegen (speculative execution). llvm-svn: 66859
* Previous debug info fix to this code wasn't quiteDale Johannesen2009-03-121-5/+4
| | | | | | | | right; did the wrong thing when there are exactly 11 non-debug instructions, followed by debug info. Remove a FIXME since it's apparently been fixed along the way. llvm-svn: 66840
* Revert commit 66140 since it caused several failuresDuncan Sands2009-03-121-6/+0
| | | | | | | | | | | in the Ada testcase. Reverting this only covers up the real problem, which is a nasty conceptual difficulty in the phi elimination pass: when eliminating phi nodes in landing pads, the register copies need to come before the invoke, not at the end of the basic block which is too late... See PR3784. llvm-svn: 66826
* There already was a class to force deterministicDale Johannesen2009-03-121-23/+14
| | | | | | sorting of ConstantInt's; unreinvent wheel. llvm-svn: 66824
* Another missing check for debug intrinsics.Dale Johannesen2009-03-121-1/+1
| | | | llvm-svn: 66800
* Allow for switch values bigger than 64 bits.Dale Johannesen2009-03-121-1/+1
| | | | llvm-svn: 66751
* Fix some nondeterministic behavior when forwardingDale Johannesen2009-03-121-3/+13
| | | | | | | | | from a switch table. Multiple table entries that branch to the same place were being sorted by the pointer value of the ConstantInt*; changed to sort by the actual value of the ConstantInt. llvm-svn: 66749
* Skip interleaved debug info when fast-forwarding throughDale Johannesen2009-03-111-2/+2
| | | | | | | | allocations. Apparently the assumption is there is an instruction (terminator?) following the allocation so I am allowing the same assumption. llvm-svn: 66716
* I should definitely read make docs someday :(Anton Korobeynikov2009-03-111-2/+3
| | | | llvm-svn: 66699
* Unbreak the build. Dunno, why it did not fail on mingw :(Anton Korobeynikov2009-03-111-1/+1
| | | | llvm-svn: 66692
* Disable plugins / shared stuff generation on windows targets.Anton Korobeynikov2009-03-111-0/+5
| | | | | | | This fixes fallout from recent PIC/delibtoolize changes and unbreaks build on cygming. llvm-svn: 66686
* Don't consider debug intrinsics when checkingDale Johannesen2009-03-101-2/+2
| | | | | | whether a callee to be inlined is a leaf. llvm-svn: 66588
* Removing a dead debug intrinsic shouldn't triggerDale Johannesen2009-03-101-3/+6
| | | | | | | another instcombine pass if we weren't going to make one without debug info. llvm-svn: 66576
* Ignore dbg info, while estimating size of jump through block.Devang Patel2009-03-101-1/+3
| | | | llvm-svn: 66554
* Do not attempt to do parial redundancy elimination on void values.John Criswell2009-03-101-3/+4
| | | | | | | Also fixed a punctuation error in the header comment. This fixes PR3775. llvm-svn: 66542
* If a function is marked alwaysinline, it must be inlined (possibly for ↵Evan Cheng2009-03-101-7/+7
| | | | | | correctness). Do so even if the callee has dynamic alloca and the caller doesn't. llvm-svn: 66539
* Ignore debug info while evaluating function.Devang Patel2009-03-091-1/+7
| | | | llvm-svn: 66490
* Don't record the increment instruction; just recompute it from the PhiDan Gohman2009-03-091-33/+15
| | | | | | | if needed. This simplifies the code a little, and is needed for an upcoming refactoring. llvm-svn: 66479
* Remove llvm.dbg.global_variables also.Devang Patel2009-03-091-0/+10
| | | | llvm-svn: 66471
* Fix a few more places where induction variable types were usedDan Gohman2009-03-091-2/+2
| | | | | | where memory access types are needed. llvm-svn: 66470
* Use ReplacedTy instead of recomputing the same value.Dan Gohman2009-03-091-1/+1
| | | | llvm-svn: 66469
* Use LoopInfo's getLoopLatch() instead of doing what it does manualy.Dan Gohman2009-03-091-12/+4
| | | | llvm-svn: 66467
* Don't use an induction variable type as a memory access type.Dan Gohman2009-03-091-3/+5
| | | | | | Use VoidTy instead, to be properly conservative. llvm-svn: 66463
* Factor out the code that determines the memory access typeDan Gohman2009-03-091-18/+29
| | | | | | of an instruction into a helper function. llvm-svn: 66460
* Add helper pass to remove llvm.dbg.declare intrinsics.Devang Patel2009-03-091-0/+62
| | | | llvm-svn: 66454
* Move the sorting of the StrideOrder array earlier so that it doesn'tDan Gohman2009-03-091-4/+3
| | | | | | have to be done twice. llvm-svn: 66449
* Delete the isOnlyStride argument, which is unused.Dan Gohman2009-03-091-9/+4
| | | | llvm-svn: 66446
* Tidy some LSR debug output: announce the loop it's about to processDan Gohman2009-03-091-6/+6
| | | | | | before it does any processing. llvm-svn: 66443
OpenPOWER on IntegriCloud