[LLVMdev] [PATCH] Seh exceptions on Win64

Vadim Chugunov vadimcn at gmail.com
Tue Apr 15 14:44:56 PDT 2014


Hi,
I am curious - how does clang deal with epilogue-less functions that result
from _Raise_Exception being marked 'noreturn'?
I've also been playing with Kai's patch, and discovered that this tends to
greatly confuse Windows stack unwinder in cases when noreturn call is at
the end of a function, so execution appears to flow directly into the
prologue of the next function.
It looks like MSVC solves this problem by inserting 'int 3' after calls to
noreturns.  This is actually the prime motivation for me wanting to emit
code for 'unreachable'<http://lists.cs.uiuc.edu/pipermail/llvmdev/2014-April/072145.html>...

Vadim



On Tue, Apr 15, 2014 at 11:43 AM, Martell Malone <martellmalone at gmail.com>wrote:

> Hi,
>
> I'd like to submit a patch to match the clang patch on the front end.
>
> http://lists.cs.uiuc.edu/pipermail/cfe-commits/Week-of-Mon-20140414/103257.html
>
> The front end doesn't need this patch to work but it's still important.
> This is mostly based on work done by kai from redstar.de
>
> Could I get some feedback on this?
> I'm not sure if the emitting of the register names will effect msvc.
>
> Many Thanks
>
> Martell Malone
>
> _______________________________________________
> LLVM Developers mailing list
> LLVMdev at cs.uiuc.edu         http://llvm.cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20140415/a0e8b60b/attachment.html>


More information about the llvm-dev mailing list