[Mlir-commits] [mlir] [mlir][Transforms][NFC] Turn op/block arg replacements into `IRRewrite`s (PR #81757)
Jacques Pienaar
llvmlistbot at llvm.org
Thu Feb 22 13:44:59 PST 2024
================
@@ -2513,21 +2535,20 @@ OperationConverter::finalize(ConversionPatternRewriter &rewriter) {
failed(legalizeConvertedArgumentTypes(rewriter, rewriterImpl)))
return failure();
- if (rewriterImpl.operationsWithChangedResults.empty())
- return success();
-
// Process requested operation replacements.
- for (unsigned i = 0, e = rewriterImpl.operationsWithChangedResults.size();
- i != e; ++i) {
- unsigned replIdx = rewriterImpl.operationsWithChangedResults[i];
- auto &repl = *(rewriterImpl.replacements.begin() + replIdx);
- for (OpResult result : repl.first->getResults()) {
+ for (unsigned i = 0; i < rewriterImpl.rewrites.size(); ++i) {
----------------
jpienaar wrote:
Range based?
https://github.com/llvm/llvm-project/pull/81757
More information about the Mlir-commits
mailing list