[Mlir-commits] [mlir] [mlir][Transforms] Dialect conversion: Fix bug in `UnresolvedMaterializationRewrite` rollback (PR #105949)

Matthias Springer llvmlistbot at llvm.org
Wed Nov 27 22:15:13 PST 2024


matthias-springer wrote:

@zero9178 I never merged this PR, but now this issue was now triggered by a Google-internal test case when I asked @jpienaar to test #116470 internally before merging it. (I originally put these changes into #116470, but I think it's better to merge two smaller PRs with a day in-between.)

My original fix may have been incorrect. This is now rolling back the mapping exactly to the previous state, addressing your comment [here](https://github.com/llvm/llvm-project/pull/105949#pullrequestreview-2273801366). I'm still not able to write a test case for this. (Because `ReplaceOperationRewrite::rollback()` and `ReplaceOperationRewrite::rollback()` also roll back the mapping. The dangling mapping is for target materialization that converts the result of an argument materialization.) I think this can only be triggered by accidental pointer reuse.

Can you take an other brief look at this before I merge it?


https://github.com/llvm/llvm-project/pull/105949


More information about the Mlir-commits mailing list