[PATCH] D135125: [JumpThreading] Reverse the order of basic block iteration.

Usman Nadeem via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Oct 25 15:45:30 PDT 2022


mnadeem abandoned this revision.
mnadeem added a comment.

In D135125#3854275 <https://reviews.llvm.org/D135125#3854275>, @efriedma wrote:

> Oh, I see, the block we choose to thread across continues to get bigger, but the cost model is fine with it because the PHI nodes are "free".
>
> I guess we could just tell the JumpThreading cost model to refuse to clone a block if there are, say, 20 or more PHI nodes in that block.  Not ideal, but reduces the chance of runaway growth.  (I mean, the growth is still sort of runaway; SSA construction is linear in the size of the function's CFG, so repeatedly doing it is fundamentally quadratic, but we can prevent it from getting worse than that.)

Abandoned in favor of D136716 <https://reviews.llvm.org/D136716> which puts a limit on the number of PHI nodes.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D135125/new/

https://reviews.llvm.org/D135125



More information about the llvm-commits mailing list