[llvm-dev] setjmp/longjmp and volatile stores, but non-volatile loads
Reid Kleckner via llvm-dev
llvm-dev at lists.llvm.org
Wed Dec 21 10:54:43 PST 2016
On Sun, Dec 18, 2016 at 11:58 PM, Jonas Maebe <jonas-devlists at watlock.be>
wrote:
>
> Actually, there's another —even more fundamental— problem: the longjmp
> will always restore the non-volatile registers to the contents they had
> at the start of the try-block, which is not what LLVM expects when
> entering an SEH-based landing pad.
>
The SjLjEHPrepare pass tries to deal with this by demoting all values live
across EH edges to the stack. This should also eliminate those phis from
landingpad blocks. Check
out TargetPassConfig::addPassesToHandleExceptions() and make sure you run
that pass.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20161221/ed5759b0/attachment.html>
More information about the llvm-dev
mailing list