summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Transforms/Utils/PromoteMemoryToRegister.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Switch mem2reg to use the new hashing infrastructure.Chandler Carruth2012-03-051-1/+3
| | | | llvm-svn: 152026
* Fix 80-column violation.Chad Rosier2012-02-201-1/+2
| | | | llvm-svn: 150998
* Propagate TargetLibraryInfo throughout ConstantFolding.cpp and Chad Rosier2011-12-011-1/+1
| | | | | | | InstructionSimplify.cpp. Other fixups as needed. Part of rdar://10500969 llvm-svn: 145559
* Add comments and test for atomic load/store and mem2reg.Eli Friedman2011-08-151-0/+4
| | | | llvm-svn: 137690
* Move onlyUsedByLifetimeMarkers to ValueTracking so that it can be used by otherNick Lewycky2011-06-271-16/+1
| | | | | | passes as well. llvm-svn: 133904
* When promoting an alloca to registers discard any lifetime intrinsics.Nick Lewycky2011-06-171-0/+59
| | | | llvm-svn: 133251
* Make LoadAndStorePromoter preserve debug info and create llvm.dbg.values whenCameron Zwarich2011-05-241-12/+0
| | | | | | promoting allocas to SSA variables. Fixes <rdar://problem/9479036>. llvm-svn: 131953
* Remove unused STL header includes.Jay Foad2011-04-231-1/+0
| | | | llvm-svn: 130068
* PR9214: Convert Metadata API to use ArrayRef.Jay Foad2011-04-211-1/+1
| | | | llvm-svn: 129932
* Remove PHINode::reserveOperandSpace(). Instead, add a parameter toJay Foad2011-03-301-2/+1
| | | | | | PHINode::Create() giving the (known or expected) number of operands. llvm-svn: 128537
* Refactor into a separate utility function.Devang Patel2011-03-171-29/+14
| | | | llvm-svn: 127832
* Do not use DIFactory. Use DIBuilder.Devang Patel2011-02-241-6/+7
| | | | llvm-svn: 126398
* Convert two std::vectors to SmallVectors for a 3.4% speedup running -scalarreplCameron Zwarich2011-01-231-2/+2
| | | | | | on test-suite + SPEC2000 & SPEC2006. llvm-svn: 124068
* Convert a std::map to a DenseMap for another 1.7% speedup on -scalarrepl.Cameron Zwarich2011-01-181-3/+3
| | | | llvm-svn: 123732
* Make a std::vector a SmallVector<*, 32> like the other vectors in the sameCameron Zwarich2011-01-181-1/+1
| | | | | | | function. This seems to be about a 1.5% speedup of -scalarrepl on test-suite with SPEC2000 and SPEC2006. llvm-svn: 123731
* Remove outdated references to dominance frontiers.Cameron Zwarich2011-01-181-7/+7
| | | | llvm-svn: 123724
* Roll r123609 back in with two changes that fix test failures with expensiveCameron Zwarich2011-01-171-50/+119
| | | | | | | | | | | | | | checks enabled: 1) Use '<' to compare integers in a comparison function rather than '<='. 2) Use the uniqued set DefBlocks rather than Info.DefiningBlocks to initialize the priority queue. The speedup of scalarrepl on test-suite + SPEC2000 + SPEC2006 is a bit less, at just under 16% rather than 17%. llvm-svn: 123662
* Roll out r123609 due to failures on the llvm-x86_64-linux-checks bot.Cameron Zwarich2011-01-171-118/+49
| | | | llvm-svn: 123618
* Eliminate the use of dominance frontiers in PromoteMemToReg. In addition toCameron Zwarich2011-01-171-49/+118
| | | | | | | | | | | | | eliminating a potentially quadratic data structure, this also gives a 17% speedup when running -scalarrepl on test-suite + SPEC2000 + SPEC2006. My initial experiment gave a greater speedup around 25%, but I moved the dominator tree level computation from dominator tree construction to PromoteMemToReg. Since this approach to computing IDFs has a much lower overhead than the old code using precomputed DFs, it is worth looking at using this new code for the second scalarrepl pass as well. llvm-svn: 123609
* split dom frontier handling stuff out to its own DominanceFrontier header,Chris Lattner2011-01-021-1/+1
| | | | | | so that Dominators.h is *just* domtree. Also prune #includes a bit. llvm-svn: 122714
* Don't keep track of inserted phis in PromoteMemoryToRegister: the informationDuncan Sands2010-11-221-8/+3
| | | | | | is never used. Patch by Cameron Zwarich. llvm-svn: 119963
* Have a few places that want to simplify phi nodes use SimplifyInstructionDuncan Sands2010-11-161-3/+4
| | | | | | rather than calling hasConstantValue. No intended functionality change. llvm-svn: 119352
* remove some dead code.Chris Lattner2010-08-181-8/+0
| | | | llvm-svn: 111344
* Don't look up the "dbg" metadata kind by name.Dan Gohman2010-07-201-4/+5
| | | | llvm-svn: 108961
* cache result of operator*Gabor Greif2010-07-091-3/+5
| | | | llvm-svn: 107966
* Use A.append(...) instead of A.insert(A.end(), ...) when A is aDan Gohman2010-06-211-3/+2
| | | | | | SmallVector, and other SmallVector simplifications. llvm-svn: 106452
* Copy location info for current function argument from dbg.declare if ↵Devang Patel2010-06-041-4/+2
| | | | | | respective store instruction does not have any location info. llvm-svn: 105490
* Fix typo.Devang Patel2010-05-281-1/+1
| | | | llvm-svn: 104914
* Fix typo.Devang Patel2010-05-281-1/+1
| | | | llvm-svn: 104913
* Do not drop location info for inlined function args.Devang Patel2010-05-271-0/+5
| | | | llvm-svn: 104884
* Fixes for Microsoft Visual Studio 2010, from Steven Watanabe!Douglas Gregor2010-05-111-1/+1
| | | | llvm-svn: 103457
* Wrap const MDNode * inside DIDescriptor.Devang Patel2010-05-071-1/+1
| | | | llvm-svn: 103295
* Use overloaded operators instead of DIDescriptor::getNode()Devang Patel2010-05-071-1/+1
| | | | llvm-svn: 103276
* rename use_const_iterator to const_use_iterator for consistency's sakeGabor Greif2010-03-251-1/+1
| | | | llvm-svn: 99564
* There are two ways of checking for a given type, for example isa<PointerType>(T)Duncan Sands2010-02-161-6/+6
| | | | | | | and T->isPointerTy(). Convert most instances of the first form to the second form. Requested by Chris. llvm-svn: 96344
* mem2reg erases the dbg.declare intrinsics that it converts to dbg.val intrinsicsVictor Hernandez2010-01-291-3/+13
| | | | llvm-svn: 94763
* some cleanups.Chris Lattner2010-01-271-14/+15
| | | | llvm-svn: 94649
* no need to check for nullChris Lattner2010-01-271-1/+1
| | | | llvm-svn: 94648
* When converting dbg.declare to dbg.value, attach promoted store's debug ↵Victor Hernandez2010-01-271-1/+4
| | | | | | metadata to dbg.value llvm-svn: 94634
* Switch AllocaDbgDeclares to SmallVector and don't leak DIFactoryVictor Hernandez2010-01-261-1/+4
| | | | llvm-svn: 94567
* In mem2reg, for all alloca/stores that get promoted where the alloca has an ↵Victor Hernandez2010-01-261-1/+52
| | | | | | associated llvm.dbg.declare instrinsic, insert an llvm.dbg.var intrinsic before each store. llvm-svn: 94493
* Revert r94260 until findDbgDeclare() is made more efficientVictor Hernandez2010-01-251-38/+3
| | | | llvm-svn: 94432
* In mem2reg, for all alloca/stores that get promoted where the alloca has an ↵Victor Hernandez2010-01-231-3/+38
| | | | | | associated llvm.dbg.declare instrinsic, insert an llvm.dbg.var intrinsic before each store llvm-svn: 94260
* Keep ignoring pointer-to-pointer bitcastsVictor Hernandez2010-01-221-3/+0
| | | | llvm-svn: 94194
* DbgInfoIntrinsic no longer appear in an instruction's use listVictor Hernandez2010-01-211-19/+4
| | | | llvm-svn: 94113
* Use do+while instead of while for loops which obviously have aDan Gohman2010-01-051-2/+2
| | | | | | non-zero trip count. Use SmallVector's pop_back_val(). llvm-svn: 92734
* Remove isPod() from DenseMapInfo, splitting it out to its ownChris Lattner2009-12-151-1/+0
| | | | | | | | isPodLike type trait. This is a generally useful type trait for more than just DenseMap, and we really care about whether something acts like a pod, not whether it really is a pod. llvm-svn: 91421
* Don't leave pointers uninitialized in the default constructor. GCC complainsChandler Carruth2009-12-131-1/+1
| | | | | | about the potential use of these uninitialized members under certain conditions. llvm-svn: 91239
* Pull LLVMContext out of PromoteMemToReg.Nick Lewycky2009-11-231-8/+4
| | | | llvm-svn: 89645
* fix a bug exposed by moving SRoA earlier which caused a crash building kc++Chris Lattner2009-11-021-1/+6
| | | | llvm-svn: 85786
OpenPOWER on IntegriCloud