speed up -gvn 3.4% on the testcase in PR7023
authorChris Lattner <sabre@nondot.org>
Mon, 6 Sep 2010 01:26:29 +0000 (01:26 +0000)
committerChris Lattner <sabre@nondot.org>
Mon, 6 Sep 2010 01:26:29 +0000 (01:26 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@113135 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Analysis/MemoryDependenceAnalysis.cpp

index d18d5ce0ea4cbcedb1dcc855643170a269082bd9..e0e0cffb75b11e169ce4caa013204503cf5d676b 100644 (file)
@@ -176,7 +176,7 @@ getPointerDependencyFrom(Value *MemPtr, uint64_t MemSize, bool isLoad,
     
     if (IntrinsicInst *II = dyn_cast<IntrinsicInst>(Inst)) {
       // Debug intrinsics don't cause dependences.
-      if (isa<DbgInfoIntrinsic>(Inst)) continue;
+      if (isa<DbgInfoIntrinsic>(II)) continue;
       
       // If we pass an invariant-end marker, then we've just entered an
       // invariant region and can start ignoring dependencies.