[Mlir-commits] [flang] [mlir] [mlir][Transforms] Add support for `ConversionPatternRewriter::replaceAllUsesWith` (PR #155244)

Matthias Springer llvmlistbot at llvm.org
Tue Sep 9 12:33:29 PDT 2025


matthias-springer wrote:

replaceAllUsesWith + eraseOp is indeed not supported at the moment. That's because both function update the conversion mapping and the second one would overwrite the first one. I have a PR in preparation that will allow it, but it will still take a while.

The only API that is fully supported today is replaceOp. You can write replaceOp(op, {val, Value()}) to replace only the first op result and drop the second one. 

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


More information about the Mlir-commits mailing list