Skip to content

[mlir][Transforms][NFC] Dialect conversion: Remove redundant ReplaceBlockArgRewrite #105963

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conversation

matthias-springer
Copy link
Member

There was a redundant appendRewrite<ReplaceBlockArgRewrite>(block, origArg); in ConversionPatternRewriterImpl::applySignatureConversion that had no effect.

…ArgRewrite`

There was a redundant `appendRewrite<ReplaceBlockArgRewrite>(block, origArg);` in `ConversionPatternRewriterImpl::applySignatureConversion` that had no effect.
@matthias-springer matthias-springer changed the title [mlir][Transforms] Dialect conversion: Remove redundant ReplaceBlockArgRewrite [mlir][Transforms][NFC] Dialect conversion: Remove redundant ReplaceBlockArgRewrite Aug 24, 2024
@llvmbot llvmbot added mlir:core MLIR Core Infrastructure mlir labels Aug 24, 2024
@@ -1296,7 +1296,6 @@ Block *ConversionPatternRewriterImpl::applySignatureConversion(
OpBuilder::InsertPoint(newBlock, newBlock->begin()), origArg.getLoc(),
/*inputs=*/replArgs, origArgType, converter);
mapping.map(origArg, argMat);
appendRewrite<ReplaceBlockArgRewrite>(block, origArg);
Copy link
Member Author

@matthias-springer matthias-springer Aug 24, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Note: Identical ReplaceBlockArgRewrite at line 1320.

@llvmbot
Copy link
Member

llvmbot commented Aug 24, 2024

@llvm/pr-subscribers-mlir-core

@llvm/pr-subscribers-mlir

Author: Matthias Springer (matthias-springer)

Changes

There was a redundant appendRewrite&lt;ReplaceBlockArgRewrite&gt;(block, origArg); in ConversionPatternRewriterImpl::applySignatureConversion that had no effect.


Full diff: https://github.com/llvm/llvm-project/pull/105963.diff

1 Files Affected:

  • (modified) mlir/lib/Transforms/Utils/DialectConversion.cpp (-1)
diff --git a/mlir/lib/Transforms/Utils/DialectConversion.cpp b/mlir/lib/Transforms/Utils/DialectConversion.cpp
index 4058ed39621198..cc9c9495e5155c 100644
--- a/mlir/lib/Transforms/Utils/DialectConversion.cpp
+++ b/mlir/lib/Transforms/Utils/DialectConversion.cpp
@@ -1296,7 +1296,6 @@ Block *ConversionPatternRewriterImpl::applySignatureConversion(
         OpBuilder::InsertPoint(newBlock, newBlock->begin()), origArg.getLoc(),
         /*inputs=*/replArgs, origArgType, converter);
     mapping.map(origArg, argMat);
-    appendRewrite<ReplaceBlockArgRewrite>(block, origArg);
 
     Type legalOutputType;
     if (converter) {

@matthias-springer matthias-springer merged commit e886374 into main Aug 27, 2024
11 checks passed
@matthias-springer matthias-springer deleted the users/matthias-springer/redundant_replace_block_arg_rew branch August 27, 2024 14:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
mlir:core MLIR Core Infrastructure mlir
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants