diff options
author | Sanjay Patel <spatel@rotateright.com> | 2017-12-14 22:05:20 +0000 |
---|---|---|
committer | Sanjay Patel <spatel@rotateright.com> | 2017-12-14 22:05:20 +0000 |
commit | 0ab0c1a201ece292fdced1f913fa257bdcb5280f (patch) | |
tree | e896fb6f22c7ce9f2106707b0796e7cab2c2c59e /llvm/lib/Target/ARM/ARMTargetMachine.cpp | |
parent | 34ccadcea9eba33d2e410b2af843a3da602611bf (diff) | |
download | bcm5719-llvm-0ab0c1a201ece292fdced1f913fa257bdcb5280f.tar.gz bcm5719-llvm-0ab0c1a201ece292fdced1f913fa257bdcb5280f.zip |
[SimplifyCFG] don't sink common insts too soon (PR34603)
This should solve:
https://bugs.llvm.org/show_bug.cgi?id=34603
...by preventing SimplifyCFG from altering redundant instructions before early-cse has a chance to run.
It changes the default (canonical-forming) behavior of SimplifyCFG, so we're only doing the
sinking transform later in the optimization pipeline.
Differential Revision: https://reviews.llvm.org/D38566
llvm-svn: 320749
Diffstat (limited to 'llvm/lib/Target/ARM/ARMTargetMachine.cpp')
-rw-r--r-- | llvm/lib/Target/ARM/ARMTargetMachine.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/Target/ARM/ARMTargetMachine.cpp b/llvm/lib/Target/ARM/ARMTargetMachine.cpp index 007dc2be16e..51982b2dab1 100644 --- a/llvm/lib/Target/ARM/ARMTargetMachine.cpp +++ b/llvm/lib/Target/ARM/ARMTargetMachine.cpp @@ -385,7 +385,7 @@ void ARMPassConfig::addIRPasses() { // ldrex/strex loops to simplify this, but it needs tidying up. if (TM->getOptLevel() != CodeGenOpt::None && EnableAtomicTidy) addPass(createCFGSimplificationPass( - 1, false, false, true, [this](const Function &F) { + 1, false, false, true, true, [this](const Function &F) { const auto &ST = this->TM->getSubtarget<ARMSubtarget>(F); return ST.hasAnyDataBarrier() && !ST.isThumb1Only(); })); |