[LLVMdev] ShadowStackGC.cpp - More Dead Code?

Duncan Sands baldrick at free.fr
Sun Aug 21 04:26:03 PDT 2011


Hi Bill,

> I've been looking at all of the uses of the 'unwind' instruction, and ShadowStackGC.cpp is the last pass which actually creates 'unwind' instructions. The thing is, this pass seems to be dead. It hasn't been updated in any meaningful way since ~79000.
>
> Should this pass go the way of the dodo?

no idea, but it would be nice if there was a simple way to run some cleanup
code then keep unwinding when an exception is unwind.  I guess the
problem is what personality function to use?  It could scan the function,
and if it sees an existing landing pad, just reuse that personality function,
and otherwise just use the C personality function in the cleanup landing pad
it needs to create.  It would be neat if a landing pad instruction didn't need
a personality function if it only wants to run a cleanup, and have everything
be taken care of automagically, but I guess that can be done in some happy
future time when the exception handling world has calmed down again :)

Ciao, Duncan.



More information about the llvm-dev mailing list