[llvm-commits] [llvm] r98584 - /llvm/trunk/lib/Transforms/Scalar/IndVarSimplify.cpp

Devang Patel dpatel at apple.com
Mon Mar 15 15:23:03 PDT 2010


Author: dpatel
Date: Mon Mar 15 17:23:03 2010
New Revision: 98584

URL: http://llvm.org/viewvc/llvm-project?rev=98584&view=rev
Log:
Skip debug info intrinsics.

Modified:
    llvm/trunk/lib/Transforms/Scalar/IndVarSimplify.cpp

Modified: llvm/trunk/lib/Transforms/Scalar/IndVarSimplify.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/Scalar/IndVarSimplify.cpp?rev=98584&r1=98583&r2=98584&view=diff
==============================================================================
--- llvm/trunk/lib/Transforms/Scalar/IndVarSimplify.cpp (original)
+++ llvm/trunk/lib/Transforms/Scalar/IndVarSimplify.cpp Mon Mar 15 17:23:03 2010
@@ -43,6 +43,7 @@
 #include "llvm/BasicBlock.h"
 #include "llvm/Constants.h"
 #include "llvm/Instructions.h"
+#include "llvm/IntrinsicInst.h"
 #include "llvm/LLVMContext.h"
 #include "llvm/Type.h"
 #include "llvm/Analysis/Dominators.h"
@@ -556,6 +557,9 @@
     // dominates the exit block.
     if (I->mayHaveSideEffects() || I->mayReadFromMemory())
       continue;
+    // Skip debug info intrinsics.
+    if (isa<DbgInfoIntrinsic>(I))
+      continue;
     // Don't sink static AllocaInsts out of the entry block, which would
     // turn them into dynamic allocas!
     if (AllocaInst *AI = dyn_cast<AllocaInst>(I))





More information about the llvm-commits mailing list