summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Transforms
diff options
context:
space:
mode:
authorAdam Nemet <anemet@apple.com>2016-11-29 18:31:53 +0000
committerAdam Nemet <anemet@apple.com>2016-11-29 18:31:53 +0000
commita4d3d44ec2eb7354c86edbc9b18bb4207650bc84 (patch)
tree2643291ea9b6570c9e5e431dc1a21d56b7b12a8d /llvm/lib/Transforms
parent7c078fc035098853a7622f902d9ff80b1281d213 (diff)
downloadbcm5719-llvm-a4d3d44ec2eb7354c86edbc9b18bb4207650bc84.tar.gz
bcm5719-llvm-a4d3d44ec2eb7354c86edbc9b18bb4207650bc84.zip
Revert "[GVN, OptDiag] Print the interesting instructions involved in missed load-elimination"
This reverts commit r288090. Trying to see if the revert fixes a compiler crash during a stage2 LTO build with a GVN backtrace. llvm-svn: 288177
Diffstat (limited to 'llvm/lib/Transforms')
-rw-r--r--llvm/lib/Transforms/Scalar/GVN.cpp36
1 files changed, 0 insertions, 36 deletions
diff --git a/llvm/lib/Transforms/Scalar/GVN.cpp b/llvm/lib/Transforms/Scalar/GVN.cpp
index 5c607abfd6f..4f66c5d1314 100644
--- a/llvm/lib/Transforms/Scalar/GVN.cpp
+++ b/llvm/lib/Transforms/Scalar/GVN.cpp
@@ -1208,38 +1208,6 @@ static bool isLifetimeStart(const Instruction *Inst) {
return false;
}
-/// \brief Try to locate the three instruction involved in a missed
-/// load-elimination case that is due to an intervening store.
-static void reportMayClobberedLoad(LoadInst *LI, MemDepResult DepInfo,
- DominatorTree *DT,
- OptimizationRemarkEmitter *ORE) {
- using namespace ore;
- User *OtherAccess = nullptr;
-
- OptimizationRemarkMissed R(DEBUG_TYPE, "LoadClobbered", LI);
- R << "load of type " << NV("Type", LI->getType()) << " not eliminated"
- << setExtraArgs();
-
- for (auto *U : LI->getPointerOperand()->users())
- if (U != LI && (isa<LoadInst>(U) || isa<StoreInst>(U)) &&
- DT->dominates(cast<Instruction>(U), LI)) {
- // FIXME: for now give up if there are multiple memory accesses that
- // dominate the load. We need further analysis to decide which one is
- // that we're forwarding from.
- if (OtherAccess)
- OtherAccess = nullptr;
- else
- OtherAccess = U;
- }
-
- if (OtherAccess)
- R << " in favor of " << NV("OtherAccess", OtherAccess);
-
- R << " because it is clobbered by " << NV("ClobberedBy", DepInfo.getInst());
-
- ORE->emit(R);
-}
-
bool GVN::AnalyzeLoadAvailability(LoadInst *LI, MemDepResult DepInfo,
Value *Address, AvailableValue &Res) {
@@ -1304,10 +1272,6 @@ bool GVN::AnalyzeLoadAvailability(LoadInst *LI, MemDepResult DepInfo,
Instruction *I = DepInfo.getInst();
dbgs() << " is clobbered by " << *I << '\n';
);
-
- if (ORE->allowExtraAnalysis())
- reportMayClobberedLoad(LI, DepInfo, DT, ORE);
-
return false;
}
assert(DepInfo.isDef() && "follows from above");
OpenPOWER on IntegriCloud