LLVM
8.0.1
|
This class is a batch walker of all MemoryUse's in the program, and points their defining access at the thing that actually clobbers them. More...
Public Member Functions | |
OptimizeUses (MemorySSA *MSSA, MemorySSAWalker *Walker, AliasAnalysis *AA, DominatorTree *DT) | |
void | optimizeUses () |
Optimize uses to point to their actual clobbering definitions. More... | |
This class is a batch walker of all MemoryUse's in the program, and points their defining access at the thing that actually clobbers them.
Because it is a batch walker that touches everything, it does not operate like the other walkers. This walker is basically performing a top-down SSA renaming pass, where the version stack is used as the cache. This enables it to be significantly more time and memory efficient than using the regular walker, which is walking bottom-up.
Definition at line 1194 of file MemorySSA.cpp.
|
inline |
Definition at line 1196 of file MemorySSA.cpp.
References assert(), llvm::SmallVectorTemplateCommon< T >::back(), llvm::dbgs(), llvm::dyn_cast(), llvm::SmallVectorBase::empty(), llvm::MemoryAccess::getBlock(), llvm::MemorySSA::getWalker(), instructionClobbersQuery(), isUseTriviallyOptimizableToLiveOnEntry(), lifetimeEndsAt(), LLVM_DEBUG, MaxCheckLimit(), llvm::MayAlias, llvm::MustAlias, llvm::None, llvm::SmallVectorTemplateBase< T >::pop_back(), llvm::SmallVectorTemplateBase< T >::push_back(), and llvm::SmallVectorBase::size().
void MemorySSA::OptimizeUses::optimizeUses | ( | ) |
Optimize uses to point to their actual clobbering definitions.
Definition at line 1400 of file MemorySSA.cpp.
References B, llvm::IDFCalculator< NodeTy, IsPostDom >::calculate(), llvm::SmallPtrSetImpl< PtrType >::count(), llvm::depth_first(), F, I, llvm::SmallPtrSetImpl< PtrType >::insert(), optimizeUses(), llvm::simple_ilist< T, Options >::push_back(), llvm::SmallVectorTemplateBase< T >::push_back(), llvm::iplist_impl< IntrusiveListT, TraitsT >::push_back(), llvm::MemorySSA::renamePass(), and llvm::IDFCalculator< NodeTy, IsPostDom >::setDefiningBlocks().
Referenced by optimizeUses().