[PATCH] D15405: [EHPersonality] Add a new personality enum to represent langindPad of token type

Joseph Tremoulet via llvm-commits llvm-commits at lists.llvm.org
Mon Dec 14 14:19:14 PST 2015


JosephTremoulet added a comment.

In http://reviews.llvm.org/D15405#310301, @rnk wrote:

> In http://reviews.llvm.org/D15405#310289, @JosephTremoulet wrote:
>
> > It just seemed backwards to snoop the landingpad's type when we expect landingpad type to be dictated by the personality, nothing deeper than that.
>
>
> I think it's fine. landingpad personalities don't impose a lot of constraints on the compiler. It seems nicer to treat them as more of an open set of well-behaved things.


Alright.  Chen, sorry for the back-and-forth.

We do have this check in the verifier:

  if (!LandingPadResultTy)
    LandingPadResultTy = LPI.getType();
  else
    Assert(LandingPadResultTy == LPI.getType(),
           "The landingpad instruction should have a consistent result type "
           "inside a function.",
           &LPI);

we could either remove it or decide that landingpads can vary but must agree **within a function**.  I'm fine with either.


http://reviews.llvm.org/D15405





More information about the llvm-commits mailing list