[PATCH] D60897: [SLP] Look-ahead operand reordering heuristic.
Vasileios Porpodas via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri May 31 14:55:22 PDT 2019
vporpo updated this revision to Diff 202491.
vporpo added a comment.
I investigated the two AArch64 failing tests. These tests feature the exact problem that we are trying to solve with this look-ahead heuristic. A commutative instruction had operands of the same opcode that the current heuristic has no way of reordering in an informed way. The current reordering was just lucky to pick the proper one, while the look-ahead heuristic was reordering the operands according to the score. However, the problem was that the score calculation was not considering external uses and was therefore favoring a sub-optimal operand ordering.
I updated the patch to factor in the cost of external uses, and both failures are now gone. I also updated the lit-test with a test that shows the problem with the external-uses.
CHANGES SINCE LAST ACTION
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 36101 bytes
Desc: not available
More information about the llvm-commits