[llvm-commits] [llvm] r128160 - /llvm/trunk/lib/ExecutionEngine/MCJIT/MCJIT.cpp

Jim Grosbach grosbach at apple.com
Wed Mar 23 12:51:34 PDT 2011


Author: grosbach
Date: Wed Mar 23 14:51:34 2011
New Revision: 128160

URL: http://llvm.org/viewvc/llvm-project?rev=128160&view=rev
Log:
Make sure to report any errors from the runtime dyld.

Modified:
    llvm/trunk/lib/ExecutionEngine/MCJIT/MCJIT.cpp

Modified: llvm/trunk/lib/ExecutionEngine/MCJIT/MCJIT.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/ExecutionEngine/MCJIT/MCJIT.cpp?rev=128160&r1=128159&r2=128160&view=diff
==============================================================================
--- llvm/trunk/lib/ExecutionEngine/MCJIT/MCJIT.cpp (original)
+++ llvm/trunk/lib/ExecutionEngine/MCJIT/MCJIT.cpp Wed Mar 23 14:51:34 2011
@@ -90,7 +90,8 @@
   // FIXME: It would be nice to avoid making yet another copy.
   MemoryBuffer *MB = MemoryBuffer::getMemBufferCopy(StringRef(Buffer.data(),
                                                               Buffer.size()));
-  Dyld.loadObject(MB);
+  if (Dyld.loadObject(MB))
+    report_fatal_error(Dyld.getErrorString());
 }
 
 MCJIT::~MCJIT() {





More information about the llvm-commits mailing list