Skip to content

Commit ad7e3ee

Browse files
committed
Use clang-format
1 parent 2edcaa6 commit ad7e3ee

File tree

8 files changed

+26
-21
lines changed

8 files changed

+26
-21
lines changed

mlir/include/mlir/Dialect/SPIRV/Transforms/SPIRVWebGPUTransforms.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
//
77
//===----------------------------------------------------------------------===//
88
//
9-
// Defines SPIR-V transforms used when targetting WebGPU.
9+
// Defines SPIR-V transforms used when targeting WebGPU.
1010
//
1111
//===----------------------------------------------------------------------===//
1212

mlir/include/mlir/Transforms/DialectConversion.h

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -218,12 +218,13 @@ class TypeConverter {
218218
///
219219
/// The conversion functions take a non-null Type or subclass of Type and a
220220
/// non-null Attribute (or subclass of Attribute), and returns a
221-
/// `AttributeConversionResult`. This result can either contain an `Attribute`,
222-
/// which may be `nullptr`, representing the conversion's success,
223-
/// `AttributeConversionResult::na()` (the default empty value), indicating
224-
/// that the conversion function did not apply and that further conversion
225-
/// functions should be checked, or `AttributeConversionResult::abort()`
226-
/// indicating that the conversion process should be aborted.
221+
/// `AttributeConversionResult`. This result can either contain an
222+
/// `Attribute`, which may be `nullptr`, representing the conversion's
223+
/// success, `AttributeConversionResult::na()` (the default empty value),
224+
/// indicating that the conversion function did not apply and that further
225+
/// conversion functions should be checked, or
226+
/// `AttributeConversionResult::abort()` indicating that the conversion
227+
/// process should be aborted.
227228
///
228229
/// Registered conversion functions are called in the reverse of the order in
229230
/// which they were registered.

mlir/lib/Dialect/SPIRV/Transforms/SPIRVWebGPUTransforms.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
//
77
//===----------------------------------------------------------------------===//
88
//
9-
// This file implements SPIR-V transforms used when targetting WebGPU.
9+
// This file implements SPIR-V transforms used when targeting WebGPU.
1010
//
1111
//===----------------------------------------------------------------------===//
1212

mlir/lib/Tools/PDLL/Parser/Parser.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -434,7 +434,7 @@ class Parser {
434434
const ods::Operation *odsOp,
435435
SmallVectorImpl<ast::Expr *> &results);
436436
void checkOperationResultTypeInference(SMRange loc, StringRef name,
437-
const ods::Operation *odsOp);
437+
const ods::Operation *odsOp);
438438
LogicalResult validateOperationOperandsOrResults(
439439
StringRef groupName, SMRange loc, std::optional<SMRange> odsOpLoc,
440440
std::optional<StringRef> name, SmallVectorImpl<ast::Expr *> &values,
@@ -2892,7 +2892,7 @@ Parser::validateOperationResults(SMRange loc, std::optional<StringRef> name,
28922892
}
28932893

28942894
void Parser::checkOperationResultTypeInference(SMRange loc, StringRef opName,
2895-
const ods::Operation *odsOp) {
2895+
const ods::Operation *odsOp) {
28962896
// If the operation might not have inference support, emit a warning to the
28972897
// user. We don't emit an error because the interface might be added to the
28982898
// operation at runtime. It's rare, but it could still happen. We emit a

mlir/tools/mlir-tblgen/RewriterGen.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -845,7 +845,7 @@ void PatternEmitter::emitVariadicOperandMatch(DagNode tree,
845845
emitMatchCheck(
846846
opName, /*matchStr=*/argName,
847847
formatv("\"There's no operation that defines variadic operand "
848-
"{0} (variadic sub-opearnd #{1}) of {2}\"",
848+
"{0} (variadic sub-operand #{1}) of {2}\"",
849849
operandIndex, i, opName));
850850
emitMatch(argTree, argName, depth + 1);
851851
os << formatv("tblgen_ops.push_back({0});\n", argName);

mlir/tools/mlir-vulkan-runner/mlir-vulkan-runner.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ struct VulkanRunnerOptions {
4848
llvm::cl::OptionCategory category{"mlir-vulkan-runner options"};
4949
llvm::cl::opt<bool> spirvWebGPUPrepare{
5050
"vulkan-runner-spirv-webgpu-prepare",
51-
llvm::cl::desc("Run MLIR transforms used when targetting WebGPU"),
51+
llvm::cl::desc("Run MLIR transforms used when targeting WebGPU"),
5252
llvm::cl::cat(category)};
5353
};
5454
} // namespace
@@ -97,7 +97,7 @@ int main(int argc, char **argv) {
9797
llvm::InitializeNativeTargetAsmPrinter();
9898

9999
// Initialize runner-specific CLI options. These will be parsed and
100-
// initialzied in `JitRunnerMain`.
100+
// initialized in `JitRunnerMain`.
101101
VulkanRunnerOptions options;
102102
auto runPassesWithOptions = [&options](Operation *op, JitRunnerOptions &) {
103103
return runMLIRPasses(op, options);

mlir/unittests/IR/AttrTypeReplacerTest.cpp

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,8 @@ class CyclicAttrTypeReplacerBranchingRecursionPruningTest
181181
int invokeCount = 0;
182182
};
183183

184-
TEST_F(CyclicAttrTypeReplacerBranchingRecursionPruningTest, testPruneAnywhere0) {
184+
TEST_F(CyclicAttrTypeReplacerBranchingRecursionPruningTest,
185+
testPruneAnywhere0) {
185186
setBaseCase(std::nullopt);
186187

187188
// No recursion case.
@@ -203,7 +204,8 @@ TEST_F(CyclicAttrTypeReplacerBranchingRecursionPruningTest, testPruneAnywhere0)
203204
EXPECT_EQ(invokeCount, 2);
204205
}
205206

206-
TEST_F(CyclicAttrTypeReplacerBranchingRecursionPruningTest, testPruneAnywhere1) {
207+
TEST_F(CyclicAttrTypeReplacerBranchingRecursionPruningTest,
208+
testPruneAnywhere1) {
207209
setBaseCase(std::nullopt);
208210

209211
// Starting at 1. Cycle length is 3.
@@ -212,7 +214,8 @@ TEST_F(CyclicAttrTypeReplacerBranchingRecursionPruningTest, testPruneAnywhere1)
212214
EXPECT_EQ(invokeCount, 3);
213215
}
214216

215-
TEST_F(CyclicAttrTypeReplacerBranchingRecursionPruningTest, testPruneSpecific0) {
217+
TEST_F(CyclicAttrTypeReplacerBranchingRecursionPruningTest,
218+
testPruneSpecific0) {
216219
setBaseCase(0);
217220

218221
// Starting at 0. Cycle length is 3.
@@ -221,7 +224,8 @@ TEST_F(CyclicAttrTypeReplacerBranchingRecursionPruningTest, testPruneSpecific0)
221224
EXPECT_EQ(invokeCount, 3);
222225
}
223226

224-
TEST_F(CyclicAttrTypeReplacerBranchingRecursionPruningTest, testPruneSpecific1) {
227+
TEST_F(CyclicAttrTypeReplacerBranchingRecursionPruningTest,
228+
testPruneSpecific1) {
225229
setBaseCase(0);
226230

227231
// Starting at 1. Cycle length is 5 (1 -> 2 -> 0 -> 1 -> 2 -> Prune).

mlir/utils/tree-sitter-mlir/dialect/arith.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -64,11 +64,11 @@ module.exports = {
6464
// operation ::= `arith.divf` $lhs `,` $rhs (`fastmath` ``
6565
// $fastmath^)?
6666
// attr-dict `:` type($result)
67-
// operation ::= `arith.maximumf` $lhs `,` $rhs (`fastmath` ``
68-
// $fastmath^)?
67+
// operation ::= `arith.maximumf` $lhs `,` $rhs (`fastmath`
68+
// `` $fastmath^)?
6969
// attr-dict `:` type($result)
70-
// operation ::= `arith.minimumf` $lhs `,` $rhs (`fastmath` ``
71-
// $fastmath^)?
70+
// operation ::= `arith.minimumf` $lhs `,` $rhs (`fastmath`
71+
// `` $fastmath^)?
7272
// attr-dict `:` type($result)
7373
// operation ::= `arith.mulf` $lhs `,` $rhs (`fastmath` ``
7474
// $fastmath^)?

0 commit comments

Comments
 (0)