https://bugs.llvm.org/show_bug.cgi?id=51565
Bug ID: 51565
Summary: Missing transformation rotate(X,Z) == rotate(Y,Z) --->
X == Y
Product: libraries
Version: trunk
Hardware: PC
OS: Linux
Status: NEW
Severity: enhancement
Priority: P
Component: Scalar Optimizations
Assignee: unassignedb...@nondot.org
Reporter: david.bolvan...@gmail.com
CC: llvm-bugs@lists.llvm.org
// Rotate(X,Z) == Rotate(Y,Z) ---> X == Y
// Rotate(X,Z) != Rotate(Y,Z) ---> X != Y
bool test(unsigned long long x, unsigned long long y) {
unsigned long long rx = (x << 32) | (x >> 32);
unsigned long long ry = (y << 32) | (y >> 32);
return rx != ry;
}
Trunk -O2:
test(unsigned long long, unsigned long long): #
@test(unsigned long long, unsigned long long)
rol rdi, 32
rol rsi, 32
cmp rdi, rsi
setne al
ret
https://godbolt.org/z/Kb6zr8Wa3
Alive:
https://alive2.llvm.org/ce/z/HuEvjC
--
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs