[PATCH] Fix inlining to not produce duplicate landingpad clauses

Mark Seaborn mseaborn at chromium.org
Tue Dec 3 14:27:32 PST 2013


On 24 November 2013 12:35, Mark Seaborn <mseaborn at chromium.org> wrote:

> Fix inlining to not produce duplicate landingpad clauses
>
> Before this change, inlining one "invoke" into outer "invoke" call
> site can lead to the outer landingpad's catch/filter clauses being
> copied multiple times into the resulting landingpad.  This happens:
>
>  * when the inlined function contains multiple "resume" instructions,
>    because forwardResume() copies the clauses but is called multiple
>    times;
>
>  * when the inlined function contains a "resume" and a "call", because
>    HandleCallsInBlockInlinedThroughInvoke() copies the clauses but is
>    redundant with forwardResume().
>
> Fix this by deduplicating the code.
>
> This problem doesn't lead to any incorrect execution; it's only
> untidy.
>
> This change will make fixing PR17872 a little easier.
>

Ping.  Can someone review this change, please?  I am not really sure if
this change is small enough to be committed without a pre-commit review
(following http://llvm.org/docs/DeveloperPolicy.html#code-reviews), but I'd
certainly prefer to have someone review it before committing.

Cheers,
Mark
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20131203/17af8685/attachment.html>


More information about the llvm-commits mailing list