[PATCH] D64394: [MachineCSE][MachinePRE] Do not hoist common computations into hot BBs

Kai Luo via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jul 18 18:31:18 PDT 2019


lkail added a comment.

In D64394#1592621 <https://reviews.llvm.org/D64394#1592621>, @anton-afanasyev wrote:

> Btw, this change breaks multiple (more than two) hoisting to common dominator. I've tested this patch for the original test case taken from here: https://bugs.llvm.org/show_bug.cgi?id=38917. There are several comparisons giving `96 > 40 + 10, 96 > 29 + 10, 96 > 18 + 10` (so no hoisting at all), meanwhile `96 < 97 = 40 + 29 + 18 + 10`.
>  However I do not see easy solution for this issue.


Good point! I think it would be an opportunity for our benchmark. I think I can enhance it in following patches. Maybe we also have to take register pressure into consideration.


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

https://reviews.llvm.org/D64394





More information about the llvm-commits mailing list