longjmp and JIT compiled code on Windows

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

longjmp and JIT compiled code on Windows

Dibyendu Majumdar
Hi

In my project I am still getting crashes on Windows - these seem to
occur intermittently when there is a longjmp that crosses the boundary
from C code over JITed code. I posted regarding this issue previously:

http://lists.cs.uiuc.edu/pipermail/llvmdev/2015-April/084919.html

I was wondering if the support for stack unwinding on Win64 is now
improved in LLVM - and if there are any particular guidelines I need
to follow.

Thanks and Regards
Dibyendu
_______________________________________________
LLVM Developers mailing list
[hidden email]         http://llvm.cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev
Reply | Threaded
Open this post in threaded view
|

Re: longjmp and JIT compiled code on Windows

Reid Kleckner-2
There's two parts to make this work, and we only have one.

The first part is being able to emit the Win64 call-frame information (CFI) at all. Normally this is described by .pdata and .xdata sections in your object file. Today, this all works for ahead-of-time compilations, but not JIT compilations.

The second part is, in a JIT context, registering that unwind information with the operating system (Windows). This would mean calling RtlInstallFunctionTableCallback, but MCJIT doesn't have any references to that symbol today.

So we are stuck in the same place. I filed a PR for this, feel free to add yourself to it:

On Wed, Jul 22, 2015 at 5:53 PM, Dibyendu Majumdar <[hidden email]> wrote:
Hi

In my project I am still getting crashes on Windows - these seem to
occur intermittently when there is a longjmp that crosses the boundary
from C code over JITed code. I posted regarding this issue previously:

http://lists.cs.uiuc.edu/pipermail/llvmdev/2015-April/084919.html

I was wondering if the support for stack unwinding on Win64 is now
improved in LLVM - and if there are any particular guidelines I need
to follow.

Thanks and Regards
Dibyendu
_______________________________________________
LLVM Developers mailing list
[hidden email]         http://llvm.cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev


_______________________________________________
LLVM Developers mailing list
[hidden email]         http://llvm.cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev