-
Notifications
You must be signed in to change notification settings - Fork 15.4k
Open
Labels
generated by fuzzerllvm:instcombineCovers the InstCombine, InstSimplify and AggressiveInstCombine passesCovers the InstCombine, InstSimplify and AggressiveInstCombine passesmissed-optimization
Description
https://godbolt.org/z/4xa1fG3a9
define i1 @icmp_equality_test_commute_select1(i64 %X, i64 %Y, i64 %Z) {
entry:
%XeqZ = icmp eq i64 %X, %Z
%YeqZ = icmp eq i64 %Y, %Z
%XeqY = icmp eq i64 %X, %Y
%and = select i1 %YeqZ, i1 false, i1 %XeqY
%equal = select i1 %XeqZ, i1 %YeqZ, i1 %and
ret i1 %equal
}
define i1 @icmp_equality_test_commute_select2(i64 %X, i64 %Y, i64 %Z) {
entry:
%XeqZ = icmp eq i64 %X, %Z
%YeqZ = icmp ne i64 %Y, %Z
%XeqY = icmp eq i64 %X, %Y
%and = select i1 %YeqZ, i1 %XeqY, i1 false
%equal = select i1 %XeqZ, i1 %YeqZ, i1 %and
ret i1 %equal
}
define i1 @icmp_equality_test_commute_select1(i64 %X, i64 %Y, i64 %Z) {
%XeqY = icmp eq i64 %X, %Y
ret i1 %XeqY
}
define i1 @icmp_equality_test_commute_select2(i64 %X, i64 %Y, i64 %Z) {
%XeqZ = icmp eq i64 %X, %Z
%YeqZ = icmp ne i64 %Y, %Z
%XeqY = icmp eq i64 %X, %Y
%and = select i1 %YeqZ, i1 %XeqY, i1 false
%equal = select i1 %XeqZ, i1 %YeqZ, i1 %and
ret i1 %equal
}
Metadata
Metadata
Assignees
Labels
generated by fuzzerllvm:instcombineCovers the InstCombine, InstSimplify and AggressiveInstCombine passesCovers the InstCombine, InstSimplify and AggressiveInstCombine passesmissed-optimization