Skip to content

Commit 8eba28b

Browse files
authored
[mlir][NFC] Correct pattern names to match the behaviors. (#158177)
It is a follow-up for #131982 (comment) and #126898 (comment). The names do not match the behaviors, and the revision updates the names. Signed-off-by: hanhanW <[email protected]>
1 parent 330068a commit 8eba28b

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

mlir/lib/Dialect/Tensor/Transforms/ReshapePatterns.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -319,7 +319,7 @@ struct BubbleUpExpandThroughParallelCollapse
319319
/// Note - this pattern could be extended to be a swap pattern between
320320
/// `tensor.expand_shape` and `tensor.extract_slice`, but is currently
321321
/// implemented only as a bubble up pattern for `tensor.extract_slice`.
322-
struct BubbleUpExpandShapeThroughExtractSlice
322+
struct BubbleUpExtractSliceThroughExpandShape
323323
: public OpRewritePattern<tensor::ExtractSliceOp> {
324324
using OpRewritePattern<tensor::ExtractSliceOp>::OpRewritePattern;
325325

@@ -427,7 +427,7 @@ struct BubbleUpExpandShapeThroughExtractSlice
427427
/// to tensor<15xf32>
428428
/// ```
429429
/// But this is not the intended purpose of the transformation.
430-
struct BubbleUpCollapseShapeThroughExtractSlice
430+
struct BubbleUpExtractSliceThroughCollapseShape
431431
: public OpRewritePattern<tensor::ExtractSliceOp> {
432432
using OpRewritePattern<tensor::ExtractSliceOp>::OpRewritePattern;
433433

@@ -735,6 +735,6 @@ void mlir::tensor::populateBubbleUpExpandShapePatterns(
735735

736736
void mlir::tensor::populateBubbleUpExtractSliceOpPatterns(
737737
RewritePatternSet &patterns) {
738-
patterns.add<BubbleUpExpandShapeThroughExtractSlice,
739-
BubbleUpCollapseShapeThroughExtractSlice>(patterns.getContext());
738+
patterns.add<BubbleUpExtractSliceThroughExpandShape,
739+
BubbleUpExtractSliceThroughCollapseShape>(patterns.getContext());
740740
}

0 commit comments

Comments
 (0)