[PATCH] Minor tweak to MDA
Philip Reames
listmail at philipreames.com
Fri Feb 13 15:10:32 PST 2015
REPOSITORY
rL LLVM
http://reviews.llvm.org/D7624
Files:
llvm/trunk/lib/Analysis/MemoryDependenceAnalysis.cpp
Index: llvm/trunk/lib/Analysis/MemoryDependenceAnalysis.cpp
===================================================================
--- llvm/trunk/lib/Analysis/MemoryDependenceAnalysis.cpp
+++ llvm/trunk/lib/Analysis/MemoryDependenceAnalysis.cpp
@@ -423,7 +423,9 @@
}
// Walk backwards through the basic block, looking for dependencies.
- while (ScanIt != BB->begin()) {
+ // We can stop before processing PHIs or dbg intrinsics.
+ const BasicBlock::iterator Begin(BB->getFirstNonPHIOrDbg());
+ while (ScanIt != Begin) {
Instruction *Inst = --ScanIt;
if (IntrinsicInst *II = dyn_cast<IntrinsicInst>(Inst))
EMAIL PREFERENCES
http://reviews.llvm.org/settings/panel/emailpreferences/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D7624.19939.patch
Type: text/x-patch
Size: 626 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20150213/7dbf73d6/attachment.bin>
More information about the llvm-commits
mailing list