Commit 991d5aa
committed
[mlir][IR] Improve error message when return type could not be inferred
Print an error such as the following one before terminating program execution.
```
mlir/test/Dialect/SparseTensor/convert_dense2sparse.mlir:26:8: remark: location of new op
%0 = sparse_tensor.convert %arg0 : tensor<?xi32> to tensor<?xi32, #SparseVector>
^
LLVM ERROR: Failed to infer result type(s):
"sparse_tensor.positions"(...) {} : (index) -> ( ??? )
(stack trace follows)
```1 parent 11903e8 commit 991d5aa
File tree
3 files changed
+20
-1
lines changed- mlir
- include/mlir/Interfaces
- lib/Interfaces
- tools/mlir-tblgen
3 files changed
+20
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
244 | 244 | | |
245 | 245 | | |
246 | 246 | | |
| 247 | + | |
| 248 | + | |
| 249 | + | |
| 250 | + | |
247 | 251 | | |
248 | 252 | | |
249 | 253 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
247 | 247 | | |
248 | 248 | | |
249 | 249 | | |
| 250 | + | |
| 251 | + | |
| 252 | + | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
| 262 | + | |
| 263 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2503 | 2503 | | |
2504 | 2504 | | |
2505 | 2505 | | |
2506 | | - | |
| 2506 | + | |
| 2507 | + | |
2507 | 2508 | | |
2508 | 2509 | | |
2509 | 2510 | | |
| |||
0 commit comments