summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Transforms/Scalar/TailDuplication.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Get rid of static constructors for pass registration. Instead, every pass ↵Owen Anderson2010-10-191-1/+3
| | | | | | | | | | | | | | | | | exposes an initializeMyPassFunction(), which must be called in the pass's constructor. This function uses static dependency declarations to recursively initialize the pass's dependencies. Clients that only create passes through the createFooPass() APIs will require no changes. Clients that want to use the CommandLine options for passes will need to manually call the appropriate initialization functions in PassInitialization.h before parsing commandline arguments. I have tested this with all standard configurations of clang and llvm-gcc on Darwin. It is possible that there are problems with the static dependencies that will only be visible with non-standard options. If you encounter any crash in pass registration/creation, please send the testcase to me directly. llvm-svn: 116820
* Now with fewer extraneous semicolons!Owen Anderson2010-10-071-1/+1
| | | | llvm-svn: 115996
* Reapply r110396, with fixes to appease the Linux buildbot gods.Owen Anderson2010-08-061-1/+1
| | | | llvm-svn: 110460
* Revert r110396 to fix buildbots.Owen Anderson2010-08-061-1/+1
| | | | llvm-svn: 110410
* Don't use PassInfo* as a type identifier for passes. Instead, use the ↵Owen Anderson2010-08-051-1/+1
| | | | | | | | address of the static ID member as the sole unique type identifier. Clean up APIs related to this change. llvm-svn: 110396
* Fix batch of converting RegisterPass<> to INTIALIZE_PASS().Owen Anderson2010-07-211-1/+1
| | | | llvm-svn: 109045
* recommit r108131 (hich has been backed out in r108135) with a fixGabor Greif2010-07-121-2/+3
| | | | llvm-svn: 108137
* back out r108131 (of TailDuplication.cpp) for now, it causes a buildbot failureGabor Greif2010-07-121-5/+4
| | | | llvm-svn: 108135
* cache dereferenced iteratorsGabor Greif2010-07-121-4/+5
| | | | llvm-svn: 108131
* Change errs() to dbgs().David Greene2010-01-051-3/+3
| | | | llvm-svn: 92620
* remove a bunch of extraneous LLVMContext argumentsChris Lattner2009-11-061-2/+1
| | | | | | from various APIs, addressing PR5325. llvm-svn: 86231
* Remove AllocationInst. Since MallocInst went away, AllocaInst is the only ↵Victor Hernandez2009-10-231-1/+1
| | | | | | subclass of AllocationInst, so it no longer is necessary. llvm-svn: 84969
* calls are rejected above, no need to special case malloc here.Chris Lattner2009-09-271-3/+2
| | | | llvm-svn: 82929
* Instruction::clone does not need to take an LLVMContext&. Remove that andNick Lewycky2009-09-271-1/+1
| | | | | | update all the callers. llvm-svn: 82889
* Enhance transform passes so that they apply the same tranforms to malloc ↵Victor Hernandez2009-09-181-1/+2
| | | | | | | | calls as to MallocInst. Reviewed by Dan Gohman. llvm-svn: 82300
* eliminate VISIBILITY_HIDDEN from Transforms/Scalar. PR4861Chris Lattner2009-09-021-2/+1
| | | | llvm-svn: 80766
* eliminate the "Value" printing methods that print to a std::ostream.Chris Lattner2009-08-231-1/+1
| | | | | | This required converting a bunch of stuff off DOUT and other cleanups. llvm-svn: 79819
* PR4662: Fix a crash introduced by the recent LLVMContext changes.Eli Friedman2009-07-311-1/+2
| | | | llvm-svn: 77716
* More migration to raw_ostream, the water has dried up around the iostream hole.Daniel Dunbar2009-07-251-3/+4
| | | | | | | | | | - Some clients which used DOUT have moved to DEBUG. We are deprecating the "magic" DOUT behavior which avoided calling printing functions when the statement was disabled. In addition to being unnecessary magic, it had the downside of leaving code in -Asserts builds, and of hiding potentially unnecessary computations. llvm-svn: 77019
* Get rid of the Pass+Context magic.Owen Anderson2009-07-221-2/+2
| | | | llvm-svn: 76702
* Replace isTrapping with a new, similar method called Eli Friedman2009-07-171-1/+2
| | | | | | | | | | isSafeToSpeculativelyExecute. The new method is a bit closer to what the callers actually care about in that it rejects more things callers don't want. It also adds more precise handling for integer division, and unifies code for analyzing the legality of a speculative load. llvm-svn: 76150
* Revert yesterday's change by removing the LLVMContext parameter to ↵Owen Anderson2009-07-151-1/+1
| | | | | | AllocaInst and MallocInst. llvm-svn: 75863
* Move EVER MORE stuff over to LLVMContext.Owen Anderson2009-07-141-1/+1
| | | | llvm-svn: 75703
* This started as a small change, I swear. Unfortunately, lots of things call ↵Owen Anderson2009-07-091-1/+1
| | | | | | the [I|F]CmpInst constructors. Who knew!? llvm-svn: 75200
* Thread LLVMContext through the constant folding APIs, which touches a lot of ↵Owen Anderson2009-07-061-1/+1
| | | | | | files. llvm-svn: 74844
* Fix a bunch of other places that used operator[] to test whetherDan Gohman2009-07-021-5/+9
| | | | | | a key is present in a std::map or DenseMap to use find instead. llvm-svn: 74676
* Allow readonly functions to unwind exceptions. TeachDuncan Sands2009-05-061-1/+1
| | | | | | | | the optimizers about this. For example, a readonly function with no uses cannot be removed unless it is also marked nounwind. llvm-svn: 71071
* simplify code.Chris Lattner2008-11-271-4/+12
| | | | llvm-svn: 60190
* Tidy up several unbeseeming casts from pointer to intptr_t.Dan Gohman2008-09-041-1/+1
| | | | llvm-svn: 55779
* Revert 52223.Evan Cheng2008-06-121-18/+0
| | | | llvm-svn: 52243
* Avoid duplicating loop header which leads to unnatural loops (and just seem ↵Evan Cheng2008-06-111-0/+18
| | | | | | | | like general badness to me, likely to cause code explosion). Patch by Florian Brandner. llvm-svn: 52223
* Tidy up BasicBlock::getFirstNonPHI, and change a bunch of places toDan Gohman2008-05-231-4/+2
| | | | | | use it instead of duplicating its functionality. llvm-svn: 51499
* Do not dup malloc, vector instructions, etc. Throttle the default theshold ↵Evan Cheng2008-05-161-5/+15
| | | | | | way down. llvm-svn: 51183
* Remove useless check.Devang Patel2008-05-151-6/+2
| | | | | | Patch by Matthijs Kooijman. llvm-svn: 51154
* Fix for PR 2323, infinite loop in tail dup.Dale Johannesen2008-05-131-4/+15
| | | | llvm-svn: 51063
* Clean up the use of static and anonymous namespaces. This turned upDan Gohman2008-05-131-5/+7
| | | | | | | several things that were neither in an anonymous namespace nor static but not intended to be global. llvm-svn: 51017
* replace a slow and verbose version of Instruction::isUsedOutsideOfBlock withChris Lattner2008-04-201-34/+4
| | | | | | a call to Instruction::isUsedOutsideOfBlock. llvm-svn: 50005
* Revert r49614. As Dan pointed out, some of these aren't correct.Owen Anderson2008-04-141-1/+1
| | | | llvm-svn: 49657
* Replace calls of the form V1->setName(V2->getName()) with V1->takeName(V2), Owen Anderson2008-04-131-1/+1
| | | | | | which is significantly more efficient. llvm-svn: 49614
* Don't include <map> in Pass.h, which doesn't need it. This requiresDan Gohman2008-03-211-0/+1
| | | | | | adding <map> to many files that actually do need it. llvm-svn: 48667
* Remove attribution from file headers, per discussion on llvmdev.Chris Lattner2007-12-291-2/+2
| | | | llvm-svn: 45418
* Disable tail duplication of call instructions. The costChris Lattner2007-11-041-0/+5
| | | | | | | | metric is way off for these in general, and this works around buggy code like that in PR1764. we'll see if there is a big performance impact of this. If so, I'll revert it tomorrow. llvm-svn: 43668
* Fix typo in comment.Nick Lewycky2007-05-061-1/+1
| | | | llvm-svn: 36873
* Drop 'const'Devang Patel2007-05-031-2/+2
| | | | llvm-svn: 36662
* Use 'static const char' instead of 'static const int'.Devang Patel2007-05-021-2/+2
| | | | | | | Due to darwin gcc bug, one version of darwin linker coalesces static const int, which defauts PassID based pass identification. llvm-svn: 36652
* Do not use typeinfo to identify pass in pass manager.Devang Patel2007-05-011-0/+5
| | | | llvm-svn: 36632
* Apply the VISIBILITY_HIDDEN field to the remaining anonymous classes inReid Spencer2007-02-051-1/+2
| | | | | | | the Transforms library. This reduces debug library size by 132 KB, debug binary size by 376 KB, and reduces link time for llvm tools slightly. llvm-svn: 33939
* Switch over Transforms/Scalar to use the STATISTIC macro. For each statisticChris Lattner2006-12-191-4/+2
| | | | | | | converted, we lose a static initializer. This also allows GCC to emit warnings about unused statistics. llvm-svn: 32690
* Detemplatize the Statistic class. The only type it is instantiated withChris Lattner2006-12-061-2/+2
| | | | | | is 'unsigned'. llvm-svn: 32279
* Removed #include <iostream> and replaced with llvm_* streams.Bill Wendling2006-11-261-6/+4
| | | | llvm-svn: 31923
OpenPOWER on IntegriCloud