[PATCH] D36170: LSR: Fix PR33514

Evgeny Stupachenko via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Aug 2 15:11:21 PDT 2017


evstupac added a comment.

>> Other tests that have difference in binaries got the same performance.
> 
> Interesting, given we were generating invalid code, what changed there?

Something similar to what have happen to the LIT test here.
We are not generating wrong code.

1. We generate formulas that potentially generate buggy code. The formulas cold be unused, but context for the best solution differs (especially for complex cases), with and without this formulas.
2. Even if buggy formula is used it could happen, that expand is correct: "p1 + -1*p2" is valid when we have a mapped expand (existing instruction) for "p1 + -1*p2". However, if we generate a SCEV without existing map to instruction, we need to create a new instruction to expand the SCEV. -1*p2 + p1 could be an issue.


Repository:
  rL LLVM

https://reviews.llvm.org/D36170





More information about the llvm-commits mailing list