Commit 92b51bc
Guy David
[mlir][llvm] Implement ConstantLike for ZeroOp, UndefOp, PoisonOp
These act as constants and should be propagated whenever possible.
It is safe to do so for mlir.undef and mlir.poison because they remain
"dirty" through out their lifetime and can be duplicated, merged, etc.
per the LangRef.
Signed-off-by: Guy David <guy.david@nextsilicon.com>1 parent 516a9f5 commit 92b51bc
File tree
8 files changed
+206
-77
lines changed- mlir
- include/mlir/Dialect/LLVMIR
- lib/Dialect/LLVMIR/IR
- test/Dialect
- GPU
- LLVMIR
- SparseTensor
8 files changed
+206
-77
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1037 | 1037 | | |
1038 | 1038 | | |
1039 | 1039 | | |
| 1040 | + | |
| 1041 | + | |
| 1042 | + | |
| 1043 | + | |
| 1044 | + | |
| 1045 | + | |
| 1046 | + | |
| 1047 | + | |
| 1048 | + | |
| 1049 | + | |
| 1050 | + | |
| 1051 | + | |
| 1052 | + | |
| 1053 | + | |
| 1054 | + | |
| 1055 | + | |
| 1056 | + | |
| 1057 | + | |
| 1058 | + | |
| 1059 | + | |
| 1060 | + | |
| 1061 | + | |
| 1062 | + | |
| 1063 | + | |
1040 | 1064 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1522 | 1522 | | |
1523 | 1523 | | |
1524 | 1524 | | |
1525 | | - | |
| 1525 | + | |
1526 | 1526 | | |
1527 | 1527 | | |
1528 | 1528 | | |
| |||
1541 | 1541 | | |
1542 | 1542 | | |
1543 | 1543 | | |
| 1544 | + | |
1544 | 1545 | | |
1545 | 1546 | | |
1546 | | - | |
| 1547 | + | |
1547 | 1548 | | |
1548 | 1549 | | |
1549 | 1550 | | |
| |||
1563 | 1564 | | |
1564 | 1565 | | |
1565 | 1566 | | |
| 1567 | + | |
1566 | 1568 | | |
1567 | 1569 | | |
1568 | 1570 | | |
1569 | | - | |
| 1571 | + | |
1570 | 1572 | | |
1571 | 1573 | | |
1572 | 1574 | | |
| |||
1588 | 1590 | | |
1589 | 1591 | | |
1590 | 1592 | | |
| 1593 | + | |
1591 | 1594 | | |
1592 | 1595 | | |
1593 | 1596 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2555 | 2555 | | |
2556 | 2556 | | |
2557 | 2557 | | |
| 2558 | + | |
| 2559 | + | |
| 2560 | + | |
| 2561 | + | |
| 2562 | + | |
| 2563 | + | |
| 2564 | + | |
| 2565 | + | |
| 2566 | + | |
| 2567 | + | |
| 2568 | + | |
| 2569 | + | |
| 2570 | + | |
| 2571 | + | |
| 2572 | + | |
| 2573 | + | |
| 2574 | + | |
| 2575 | + | |
2558 | 2576 | | |
2559 | 2577 | | |
2560 | 2578 | | |
| |||
2568 | 2586 | | |
2569 | 2587 | | |
2570 | 2588 | | |
| 2589 | + | |
| 2590 | + | |
| 2591 | + | |
| 2592 | + | |
| 2593 | + | |
| 2594 | + | |
| 2595 | + | |
| 2596 | + | |
| 2597 | + | |
2571 | 2598 | | |
2572 | 2599 | | |
2573 | 2600 | | |
| |||
3271 | 3298 | | |
3272 | 3299 | | |
3273 | 3300 | | |
3274 | | - | |
3275 | | - | |
| 3301 | + | |
| 3302 | + | |
| 3303 | + | |
3276 | 3304 | | |
3277 | 3305 | | |
3278 | 3306 | | |
| 3307 | + | |
| 3308 | + | |
| 3309 | + | |
| 3310 | + | |
| 3311 | + | |
| 3312 | + | |
3279 | 3313 | | |
3280 | 3314 | | |
3281 | 3315 | | |
| |||
0 commit comments