[LLVMdev] Possible bug with MCJIT EH on Windows x86 with MinGW

DeadMG wolfeinstein at gmail.com
Mon Sep 15 05:33:59 PDT 2014


Hello everyone,

I've got a test case in my frontend which produces an unexpected result
(libstdc++'s EH routines terminate the program after throwing). Reading the
IR, I've been unable to determine the source of the problem.

When executing on Linux, there's no problem. When using MCJIT on Windows
x86 linking in MinGW 4.6.3 libstdc++'s EH routines, the program terminates
when the exception is thrown. In both cases, __cxa_throw is invoked
straight to a landing pad that catches the exact same RTTI that was used to
throw it.

The reason I think this may be an LLVM bug is that I've reduced the test
case a bit and removing some dead code causes the IR to pass. I've diffed
the two IRs and the difference is about six lines that seem to be trivially
obviously correct.

Any insight into this matter would be appreciated.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20140915/8e4ccaf3/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: fail.llc
Type: application/octet-stream
Size: 4191 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20140915/8e4ccaf3/attachment.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: pass.llc
Type: application/octet-stream
Size: 3841 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20140915/8e4ccaf3/attachment-0001.obj>


More information about the llvm-dev mailing list