[cfe-commits] r146926 - /cfe/trunk/lib/CodeGen/CGObjCMac.cpp

Bill Wendling isanbard at gmail.com
Mon Dec 19 15:53:28 PST 2011


Author: void
Date: Mon Dec 19 17:53:28 2011
New Revision: 146926

URL: http://llvm.org/viewvc/llvm-project?rev=146926&view=rev
Log:
Mark the calls to the _setjmp function as returns twice. <rdar://problem/10492556>

Modified:
    cfe/trunk/lib/CodeGen/CGObjCMac.cpp

Modified: cfe/trunk/lib/CodeGen/CGObjCMac.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/CodeGen/CGObjCMac.cpp?rev=146926&r1=146925&r2=146926&view=diff
==============================================================================
--- cfe/trunk/lib/CodeGen/CGObjCMac.cpp (original)
+++ cfe/trunk/lib/CodeGen/CGObjCMac.cpp Mon Dec 19 17:53:28 2011
@@ -3045,6 +3045,7 @@
   llvm::CallInst *SetJmpResult =
     CGF.Builder.CreateCall(ObjCTypes.getSetJmpFn(), SetJmpBuffer, "setjmp_result");
   SetJmpResult->setDoesNotThrow();
+  SetJmpResult->setCanReturnTwice();
 
   // If setjmp returned 0, enter the protected block; otherwise,
   // branch to the handler.
@@ -3110,6 +3111,7 @@
         CGF.Builder.CreateCall(ObjCTypes.getSetJmpFn(), SetJmpBuffer,
                                "setjmp.result");
       SetJmpResult->setDoesNotThrow();
+      SetJmpResult->setCanReturnTwice();
 
       llvm::Value *Threw =
         CGF.Builder.CreateIsNotNull(SetJmpResult, "did_catch_exception");





More information about the cfe-commits mailing list