mirror of
https://github.com/RPCSX/llvm.git
synced 2024-11-27 13:40:30 +00:00
[PM/MergedLoadStoreMotion] Preserve analyses more aggressively.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272611 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
cd472d1a69
commit
a1a1144732
@ -520,7 +520,12 @@ MergedLoadStoreMotionPass::run(Function &F, AnalysisManager<Function> &AM) {
|
||||
auto *MD = AM.getCachedResult<MemoryDependenceAnalysis>(F);
|
||||
if (!runMergedLoadStoreMotion(F, &AA, MD))
|
||||
return PreservedAnalyses::all();
|
||||
return PreservedAnalyses::none();
|
||||
// FIXME: This pass should also 'preserve the CFG'.
|
||||
// The new pass manager has currently no way to do it.
|
||||
PreservedAnalyses PA;
|
||||
PA.preserve<GlobalsAA>();
|
||||
PA.preserve<MemoryDependenceAnalysis>();
|
||||
return PA;
|
||||
}
|
||||
|
||||
namespace {
|
||||
|
Loading…
Reference in New Issue
Block a user