[Mlir-commits] [mlir] [mlir][Parser] Fix use-after-free when parsing invalid reference to nested definition (PR #127778)
Will Dietz
llvmlistbot at llvm.org
Wed Feb 19 11:19:50 PST 2025
https://github.com/dtzSiFive approved this pull request.
LGTM! Small suggestion while reviewing.
This looks to fix crash with input IR from #107121, which now produces:
```
issue-107121.mlir:1:1: error: operation's operand is unlinked
scf.if %true {
^
issue-107121.mlir:1:1: note: see current operation:
"scf.if"(<<UNKNOWN SSA VALUE>>) ({
%0 = "arith.constant"() <{value = true}> : () -> i1
"scf.yield"() : () -> ()
}, {
}) : (i1) -> ()
```
Although maybe this still not ideal, it at least no longer crashes.
(probably scf.if's parser should be altered similarly? I can take a look :+1:)
https://github.com/llvm/llvm-project/pull/127778
More information about the Mlir-commits
mailing list