[llvm-commits] [llvm-gcc-4.2] r82667 - /llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp

Eric Christopher echristo at apple.com
Wed Sep 23 18:17:12 CDT 2009


Author: echristo
Date: Wed Sep 23 18:17:12 2009
New Revision: 82667

URL: http://llvm.org/viewvc/llvm-project?rev=82667&view=rev
Log:
Use the current InsertPt not the original instruction since we
may have incremented the insert point.

Modified:
    llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp

Modified: llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp?rev=82667&r1=82666&r2=82667&view=diff

==============================================================================
--- llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp (original)
+++ llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp Wed Sep 23 18:17:12 2009
@@ -2878,7 +2878,7 @@
     }
 
     // If the instruction is an invoke, the init is inserted on the normal edge.
-    if (InvokeInst *II = dyn_cast<InvokeInst>(I)) {
+    if (InvokeInst *II = dyn_cast<InvokeInst>(InsertPt)) {
       InsertPt = II->getNormalDest()->begin();
       while (isa<PHINode>(InsertPt))
         ++InsertPt;





More information about the llvm-commits mailing list