Skip to content

Commit 7c4c274

Browse files
authored
[MLIR][NFC] Fix some comments in padding transform. (#81741)
1 parent 0f6f5bf commit 7c4c274

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

mlir/lib/Dialect/Linalg/Transforms/Padding.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ using namespace mlir::linalg;
2323
#define DBGSNL() (llvm::dbgs() << "\n")
2424

2525
/// Compute the padded shape of the given operand. The operand is padded to a
26-
/// static bounding box according to the specified options.
26+
/// static bounding box according to the specified padding options.
2727
static LogicalResult computePaddedShape(linalg::LinalgOp opToPad,
2828
OpOperand *opOperand,
2929
const LinalgPaddingOptions &options,
@@ -75,7 +75,7 @@ static LogicalResult computePaddedShape(linalg::LinalgOp opToPad,
7575
presburger::BoundType::UB, opOperand->get(),
7676
/*dim=*/i, /*stopCondition=*/nullptr, /*closedUB=*/true);
7777
if (failed(upperBound)) {
78-
LLVM_DEBUG(DBGS() << "----count not compute a bounding box for padding");
78+
LLVM_DEBUG(DBGS() << "----could not compute a bounding box for padding");
7979
return failure();
8080
}
8181
paddedShape[i] = ceil(*upperBound, shapeDimToMultiple[i]);
@@ -89,7 +89,7 @@ static LogicalResult computePaddedShape(linalg::LinalgOp opToPad,
8989
/// the nofold flag found in "paddingValues" and "packPaddings", respectively.
9090
///
9191
/// Exit early and return the `opOperand` value if it already has the requested
92-
/// shape. I.e.:
92+
/// shape. i.e.:
9393
/// - static shape
9494
/// - nofold is not set
9595
/// - dim sizes are multiples of "padToMultipleOf"
@@ -232,7 +232,7 @@ linalg::rewriteAsPaddedOp(RewriterBase &rewriter, LinalgOp opToPad,
232232

233233
// Copy back unpadded results to the original destination (i.e., inits of the
234234
// linalg op), so that the destination buffer of the computation does not
235-
// change. If the padding folds away, this will materizalize as a memcpy
235+
// change. If the padding folds away, this will materialize as a memcpy
236236
// between two identical buffers, which will then also fold away.
237237
assert(static_cast<int64_t>(paddedSubtensorResults.size()) ==
238238
opToPad.getNumDpsInits() &&

0 commit comments

Comments
 (0)