summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Transforms/Scalar/LoopInstSimplify.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Make MemoryBuiltins aware of TargetLibraryInfo.Benjamin Kramer2012-08-291-1/+1
| | | | | | | | | | | | | | | | This disables malloc-specific optimization when -fno-builtin (or -ffreestanding) is specified. This has been a problem for a long time but became more severe with the recent memory builtin improvements. Since the memory builtin functions are used everywhere, this required passing TLI in many places. This means that functions that now have an optional TLI argument, like RecursivelyDeleteTriviallyDeadFunctions, won't remove dead mallocs anymore if the TLI argument is missing. I've updated most passes to do the right thing. Fixes PR13694 and probably others. llvm-svn: 162841
* Clean whitespaces.Nadav Rotem2012-07-241-1/+1
| | | | llvm-svn: 160668
* Propagate TargetLibraryInfo throughout ConstantFolding.cpp and Chad Rosier2011-12-011-1/+5
| | | | | | | InstructionSimplify.cpp. Other fixups as needed. Part of rdar://10500969 llvm-svn: 145559
* LoopInstSimplify preserves ScalarEvolution.Cameron Zwarich2011-02-111-0/+1
| | | | llvm-svn: 125368
* LoopInstSimplify preserves LoopSimplify.Cameron Zwarich2011-01-091-0/+1
| | | | llvm-svn: 123117
* Fix coding style issues.Cameron Zwarich2011-01-081-2/+2
| | | | llvm-svn: 123065
* Contract subloop bodies. However, it is still important to visit the phis at theCameron Zwarich2011-01-081-7/+41
| | | | | | top of subloop headers, as the phi uses logically occur outside of the subloop. llvm-svn: 123062
* Use pop_back_val instead of back followed by pop_back.Cameron Zwarich2011-01-051-2/+1
| | | | llvm-svn: 122876
* Use a worklist for later iterations just like ordinary instsimplify. The nextCameron Zwarich2011-01-051-0/+19
| | | | | | | step is to only process instructions in subloops if they have been modified by an earlier simplification. llvm-svn: 122869
* Change LoopInstSimplify back to a LoopPass. It revisits subloops rather thanCameron Zwarich2011-01-051-10/+36
| | | | | | | | | | skipping them, but it should probably use a worklist and only revisit those instructions in subloops that have actually changed. It should probably also use a worklist after the first iteration like instsimplify now does. Regardless, it's only 0.3% of opt -O2 time on 403.gcc if it replaces the instcombine placed in the middle of the loop passes. llvm-svn: 122868
* Switch to the new style of asterisk placement.Cameron Zwarich2011-01-041-8/+8
| | | | llvm-svn: 122815
* Address most of Duncan's review comments. Also, make LoopInstSimplify a simpleCameron Zwarich2011-01-041-37/+15
| | | | | | | | | | | | FunctionPass. It probably doesn't have a reason to be a LoopPass, as it will probably drop the simple fixed point and either use RPO iteration or Duncan's approach in instsimplify of only revisiting instructions that have changed. The next step is to preserve LoopSimplify. This looks like it won't be too hard, although the pass manager doesn't actually seem to respect when non-loop passes claim to preserve LCSSA or LoopSimplify. This will have to be fixed. llvm-svn: 122791
* Add a new loop-instsimplify pass, with the intention of replacing the instanceCameron Zwarich2011-01-031-0/+112
of instcombine that is currently in the middle of the loop pass pipeline. This commit only checks in the pass; it will hopefully be enabled by default later. llvm-svn: 122719
OpenPOWER on IntegriCloud