Commit c9e4418
committed
[CGP] Fix matching of uadd overflow
This patch fixes the issue where uadd overflow
intrinsic is matched for:
`Add = add A,(uint64_t)-1; Cmp = icmp ne A, 0`
instead of:
`Add = add A,-1; Cmp = icmp ne A, 0`
where -1 is represented in 256 bits.
PR: #626
Signed-off-by: Vladimir Radosavljevic <[email protected]>1 parent 20de053 commit c9e4418
File tree
2 files changed
+12
-9
lines changed- llvm
- lib/CodeGen
- test/CodeGen/EraVM
2 files changed
+12
-9
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1584 | 1584 | | |
1585 | 1585 | | |
1586 | 1586 | | |
1587 | | - | |
| 1587 | + | |
| 1588 | + | |
| 1589 | + | |
1588 | 1590 | | |
1589 | 1591 | | |
1590 | 1592 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
13 | | - | |
14 | | - | |
| 13 | + | |
| 14 | + | |
15 | 15 | | |
16 | 16 | | |
17 | | - | |
18 | | - | |
19 | | - | |
20 | 17 | | |
21 | 18 | | |
22 | 19 | | |
| |||
32 | 29 | | |
33 | 30 | | |
34 | 31 | | |
35 | | - | |
36 | | - | |
37 | | - | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
38 | 39 | | |
39 | 40 | | |
40 | 41 | | |
| |||
0 commit comments