New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Regressions from bc886e9b587b9d009f49b12eaaa9ebc1c71905a1 #58717
Labels
Comments
This was apparently reverted in e1de7ac. https://reviews.llvm.org/rGbc886e9b587b9d009f49b12eaaa9ebc1c71905a1 |
Thanks for the report and analysis! Sorry about the bug. Yes, the "add" that was copied from the earlier code was supposed to be a "sub", and I missed it. On the plus side, I wasn't sure if this pattern existed in real code, but the fallout from screwing up the patch says it occurs quite a bit. :) |
rotateright
referenced
this issue
Nov 1, 2022
This is a sibling to: 6064e92 ...but we canonicalize the shl+add to shl+xor, so the pattern is different than I expected: https://alive2.llvm.org/ce/z/8CX16e I have not found any patterns that are safe to propagate no-wrap, so that is not included here.
rotateright
added a commit
that referenced
this issue
Nov 2, 2022
This is a corrected version of: bc886e9 I made a copy-paste error that created an "add" instead of the intended "sub" on that attempt. The regression tests showed the bug, but I overlooked that. As I said in a comment on issue #58717, the bug reports resulting from the botched patch confirm that the pattern does occur in many real-world applications, so hopefully eliminating the multiply results in better code. I added one more regression test in this version of the patch, and here's an Alive2 proof to show that exact example: https://alive2.llvm.org/ce/z/dge7VC Original commit message: This is a sibling to: 6064e92 ...but we canonicalize the shl+add to shl+xor, so the pattern is different than I expected: https://alive2.llvm.org/ce/z/8CX16e I have not found any patterns that are safe to propagate no-wrap, so that is not included here. Differential Revision: https://reviews.llvm.org/D137157
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Both the failures above have been bisected to bc886e9.
Cc: @rotateright
The text was updated successfully, but these errors were encountered: