[llvm] r251113 - [CodeGen] Mark setjmp/catchret MBBs address-taken

Reid Kleckner via llvm-commits llvm-commits at lists.llvm.org
Thu Nov 12 10:44:05 PST 2015


On Thu, Nov 12, 2015 at 9:37 AM, Quentin Colombet <qcolombet at apple.com>
wrote:

> Hi Joseph,
>
> Thanks for the detail explanation.
>
> Based on the description, it seems to me the MachineFunction
> representation is, at least partly, not properly modeling the constraints
> of the EH code.
> Indeed, in the funclets, there is nothing that uses of modify CSRs
> registers, so it looks like we do not need any prologue and epilogue in
> that case. I thought that what we were missing is something that expand
> CATCHRET into "lea BLOCKADER, rax”, i.e., just a pseudo expansion, but not
> a full prologue and epilogue.
>
> But anyway, let me ask a couple more questions:
> - When you said the funclet needs their own prologue and epilogue my
> impression is that right now this prologue and epilogue are needlessly
> identical to the function prologue and epilogue. Is this true or they
> actually different and this is just an artefact or the test case?
>

Ideally, funclets would have their own CSR sets. That was difficult to
implement in the current framework, so I made them all use the same CSR
sets.


> - Is it worth adding the support for funclet in shrink-wrapping? My
> impression was that the constraints on EH prologue and epilogue are too
> tight to have it kicking in.


I think it's definitely not worth trying to shrink-wrap funclets. It might
be worth shrink-wrapping the parent function that happens to use funclets.
However, we would have to overcome the Win64 epilogue constraints, and
we've decided not to do that now.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20151112/6fdd17fc/attachment.html>


More information about the llvm-commits mailing list