| Issue |
114191
|
| Summary |
[InstCombine] miscompilation of `or` of vector
|
| Labels |
new issue
|
| Assignees |
|
| Reporter |
bongjunj
|
Alive2 report: https://alive2.llvm.org/ce/z/xEbYKg
```llvm
----------------------------------------
define <2 x i32> @or_sext_to_sel_constant_vec.2(<2 x i1> %y) {
#0:
%sext = sext <2 x i1> %y to <2 x i32>
%#1 = or <2 x i32> %sext, { 0, 1 }
%#2 = sdiv <2 x i32> { 42, 4294967289 }, %#1
%#3 = udiv exact <2 x i32> %#2, %#2
%#4 = or <2 x i32> %#2, %#2
ret <2 x i32> %#4
}
=>
define <2 x i32> @or_sext_to_sel_constant_vec.2(<2 x i1> %y) {
#0:
ret <2 x i32> { 4294967254, 7 }
}
Transformation doesn't verify!
ERROR: Value mismatch
Example:
<2 x i1> %y = < #x1 (1), #x0 (0) >
Source:
<2 x i32> %sext = < #xffffffff (4294967295, -1), #x00000000 (0) >
<2 x i32> %#1 = < #xffffffff (4294967295, -1), #x00000001 (1) >
<2 x i32> %#2 = < #xffffffd6 (4294967254, -42), #xfffffff9 (4294967289, -7) >
<2 x i32> %#3 = < #x00000001 (1), #x00000001 (1) >
<2 x i32> %#4 = < #xffffffd6 (4294967254, -42), #xfffffff9 (4294967289, -7) >
Target:
Source value: < #xffffffd6 (4294967254, -42), #xfffffff9 (4294967289, -7) >
Target value: < #xffffffd6 (4294967254, -42), #x00000007 (7) >
Summary:
0 correct transformations
1 incorrect transformations
0 failed-to-prove transformations
0 Alive2 errors
```
_______________________________________________
llvm-bugs mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs