Commit 0dc71be
committed
[MLIR][Affine] Fixed crash with invalid reduction op (Issue llvm#64073)
Updated AffineParallelLowering to check if reduction op value being returned is valid else return failure in matchAndRewrite
Updated ArithOps.cpp getIdentityValue method to return nullptr if op is not a valid reduction op
Code cleanup in ArithOps.cpp getReductionOp method; removed cases maxnumf and minnumf as not valid reduction ops
Reporting Issue is llvm#640731 parent a8913f8 commit 0dc71be
File tree
2 files changed
+9
-11
lines changed- mlir/lib
- Conversion/AffineToStandard
- Dialect/Arith/IR
2 files changed
+9
-11
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
225 | 225 | | |
226 | 226 | | |
227 | 227 | | |
228 | | - | |
229 | | - | |
230 | | - | |
231 | | - | |
232 | | - | |
233 | | - | |
234 | | - | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
235 | 235 | | |
236 | 236 | | |
237 | 237 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2505 | 2505 | | |
2506 | 2506 | | |
2507 | 2507 | | |
| 2508 | + | |
| 2509 | + | |
2508 | 2510 | | |
2509 | 2511 | | |
2510 | 2512 | | |
| |||
2525 | 2527 | | |
2526 | 2528 | | |
2527 | 2529 | | |
2528 | | - | |
2529 | | - | |
2530 | | - | |
2531 | | - | |
2532 | 2530 | | |
2533 | 2531 | | |
2534 | 2532 | | |
| |||
0 commit comments