[PATCH] D47816: [InstCombine] Stop sinking instructions across function call.

Roman Lebedev via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jun 19 05:03:25 PDT 2018


lebedev.ri added a comment.

In https://reviews.llvm.org/D47816#1136426, @renlin wrote:

> In https://reviews.llvm.org/D47816#1136346, @lebedev.ri wrote:
>
> > I'm seeing `what`, but not `why`.
> >  What is the motivation behind this change?
> >  What problem is it trying to solve?
>
>
> In one of the test case I have, the sinking of a load instruction (together with the operands used) across a inlined function increases the number of instructions generated.


Instructions as in IR instructions? Or the instructions in the final assembly?

> The inline pass run after instCombine pass. If I reorder the passes to have inline pass before instCombine, this will make the CFG complex. And instCombine will give up the sinking.




https://reviews.llvm.org/D47816





More information about the llvm-commits mailing list