[llvm-branch-commits] [mlir] f88fab5 - [mlir] NFC: fix trivial typos

Kazuaki Ishizaki via llvm-branch-commits llvm-branch-commits at lists.llvm.org
Thu Jan 7 09:15:12 PST 2021


Author: Kazuaki Ishizaki
Date: 2021-01-08T02:10:12+09:00
New Revision: f88fab500689852d06dd6e30ea1a8425ed7fd0e4

URL: https://github.com/llvm/llvm-project/commit/f88fab500689852d06dd6e30ea1a8425ed7fd0e4
DIFF: https://github.com/llvm/llvm-project/commit/f88fab500689852d06dd6e30ea1a8425ed7fd0e4.diff

LOG: [mlir] NFC: fix trivial typos

fix typo under include and lib directories

Reviewed By: antiagainst

Differential Revision: https://reviews.llvm.org/D94220

Added: 
    

Modified: 
    mlir/include/mlir-c/Support.h
    mlir/include/mlir/Conversion/SPIRVToLLVM/SPIRVToLLVMPass.h
    mlir/include/mlir/Dialect/ArmSVE/ArmSVE.td
    mlir/include/mlir/Dialect/Async/IR/AsyncOps.td
    mlir/include/mlir/Dialect/SCF/SCFOps.td
    mlir/include/mlir/Dialect/SPIRV/IR/SPIRVGLSLOps.td
    mlir/include/mlir/Dialect/StandardOps/IR/Ops.td
    mlir/include/mlir/Dialect/StandardOps/Transforms/Passes.td
    mlir/include/mlir/Dialect/Tosa/Utils/QuantUtils.h
    mlir/include/mlir/Dialect/Vector/VectorOps.td
    mlir/include/mlir/IR/ImplicitLocOpBuilder.h
    mlir/include/mlir/IR/OpDefinition.h
    mlir/include/mlir/Pass/PassRegistry.h
    mlir/include/mlir/Support/IndentedOstream.h
    mlir/include/mlir/Target/LLVMIR/ModuleTranslation.h
    mlir/include/mlir/Target/LLVMIR/TypeTranslation.h
    mlir/include/mlir/Transforms/Bufferize.h
    mlir/lib/Analysis/AffineStructures.cpp
    mlir/lib/Bindings/Python/IRModules.cpp
    mlir/lib/CAPI/Transforms/Passes.cpp
    mlir/lib/Conversion/GPUCommon/ConvertKernelFuncToBlob.cpp
    mlir/lib/Conversion/PDLToPDLInterp/Predicate.h
    mlir/lib/Conversion/SPIRVToLLVM/ConvertLaunchFuncToLLVMCalls.cpp
    mlir/lib/Dialect/Async/Transforms/AsyncParallelFor.cpp
    mlir/lib/Dialect/LLVMIR/IR/TypeDetail.h
    mlir/lib/Dialect/Linalg/Transforms/Fusion.cpp
    mlir/lib/Dialect/Linalg/Transforms/Sparsification.cpp
    mlir/lib/Dialect/PDL/IR/PDL.cpp
    mlir/lib/Dialect/SPIRV/IR/SPIRVTypes.cpp
    mlir/lib/Dialect/SPIRV/Linking/ModuleCombiner/ModuleCombiner.cpp
    mlir/lib/Dialect/StandardOps/IR/Ops.cpp
    mlir/lib/Dialect/StandardOps/Transforms/ExpandOps.cpp
    mlir/lib/Dialect/Tosa/Transforms/TosaMakeBroadcastable.cpp
    mlir/lib/Dialect/Vector/VectorOps.cpp
    mlir/lib/IR/AsmPrinter.cpp
    mlir/lib/Rewrite/ByteCode.h
    mlir/lib/Target/SPIRV/Serialization.cpp
    mlir/lib/Transforms/BufferUtils.cpp
    mlir/lib/Transforms/Utils/FoldUtils.cpp
    mlir/lib/Transforms/Utils/LoopUtils.cpp
    mlir/lib/Transforms/Utils/RegionUtils.cpp

Removed: 
    


################################################################################
diff  --git a/mlir/include/mlir-c/Support.h b/mlir/include/mlir-c/Support.h
index 072b96051e01..6b5927afc431 100644
--- a/mlir/include/mlir-c/Support.h
+++ b/mlir/include/mlir-c/Support.h
@@ -76,7 +76,7 @@ mlirStringRefCreateFromCString(const char *str);
  *
  * This function is called back by the functions that need to return a reference
  * to the portion of the string with the following arguments:
- *   - an MlirStringRef represening the current portion of the string
+ *   - an MlirStringRef representing the current portion of the string
  *   - a pointer to user data forwarded from the printing call.
  */
 typedef void (*MlirStringCallback)(MlirStringRef, void *);

diff  --git a/mlir/include/mlir/Conversion/SPIRVToLLVM/SPIRVToLLVMPass.h b/mlir/include/mlir/Conversion/SPIRVToLLVM/SPIRVToLLVMPass.h
index bc70736c7d3b..859eadadd7a8 100644
--- a/mlir/include/mlir/Conversion/SPIRVToLLVM/SPIRVToLLVMPass.h
+++ b/mlir/include/mlir/Conversion/SPIRVToLLVM/SPIRVToLLVMPass.h
@@ -24,7 +24,7 @@ class OperationPass;
 /// the host module code to LLVM.
 ///
 /// This transformation creates a sequence of global variables that are later
-/// linked to the varables in the kernel module, and a series of copies to/from
+/// linked to the variables in the kernel module, and a series of copies to/from
 /// them to emulate the memory transfer from the host or to the device sides. It
 /// also converts the remaining Standard dialect into LLVM dialect, emitting C
 /// wrappers.

diff  --git a/mlir/include/mlir/Dialect/ArmSVE/ArmSVE.td b/mlir/include/mlir/Dialect/ArmSVE/ArmSVE.td
index 6353a0001d4c..b1a42e99126c 100644
--- a/mlir/include/mlir/Dialect/ArmSVE/ArmSVE.td
+++ b/mlir/include/mlir/Dialect/ArmSVE/ArmSVE.td
@@ -165,7 +165,7 @@ def SmmlaOp : ArmSVE_Op<"smmla",
                 AllTypesMatch<["src1", "src2"]>,
                 AllTypesMatch<["acc", "dst"]>,
               ]> {
-  let summary = "Matrix-matrix mutiply and accumulate op";
+  let summary = "Matrix-matrix multiply and accumulate op";
   let description = [{
     SMMLA: Signed integer matrix multiply-accumulate.
 
@@ -228,7 +228,7 @@ def UmmlaOp : ArmSVE_Op<"ummla",
                 AllTypesMatch<["src1", "src2"]>,
                 AllTypesMatch<["acc", "dst"]>,
               ]> {
-  let summary = "Matrix-matrix mutiply and accumulate op";
+  let summary = "Matrix-matrix multiply and accumulate op";
   let description = [{
     UMMLA: Unsigned integer matrix multiply-accumulate.
 

diff  --git a/mlir/include/mlir/Dialect/Async/IR/AsyncOps.td b/mlir/include/mlir/Dialect/Async/IR/AsyncOps.td
index 80aeabf5f904..f2c5e295cec0 100644
--- a/mlir/include/mlir/Dialect/Async/IR/AsyncOps.td
+++ b/mlir/include/mlir/Dialect/Async/IR/AsyncOps.td
@@ -241,7 +241,7 @@ def Async_AwaitAllOp : Async_Op<"await_all", []> {
 //   1. Operation returns async result (e.g. the result of an `async.execute`).
 //   2. Async value passed in as a block argument.
 //
-// It is the responsiblity of the async value user to extend the lifetime by
+// It is the responsibility of the async value user to extend the lifetime by
 // adding a +1 reference, if the reference counted value captured by the
 // asynchronously executed region (`async.execute` operation), and drop it after
 // the last nested use.

diff  --git a/mlir/include/mlir/Dialect/SCF/SCFOps.td b/mlir/include/mlir/Dialect/SCF/SCFOps.td
index f30e8f20c4b7..236586a39040 100644
--- a/mlir/include/mlir/Dialect/SCF/SCFOps.td
+++ b/mlir/include/mlir/Dialect/SCF/SCFOps.td
@@ -496,7 +496,7 @@ def WhileOp : SCF_Op<"while",
        * In a "do-while" loop, this region contains the loop body. */
       %next = call @payload(%arg1) : (f32) -> f32
 
-      /* And also evalutes the condition. */
+      /* And also evaluates the condition. */
       %condition = call @evaluate_condition(%arg1) : (f32) -> i1
 
       /* Loop through the "after" region. */
@@ -525,7 +525,7 @@ def WhileOp : SCF_Op<"while",
        * "after" region. */
       %shared = call @shared_compute(%arg1) : (f32) -> i64
 
-      /* Evalute the condition. */
+      /* Evaluate the condition. */
       %condition = call @evaluate_condition(%arg1, %shared) : (f32, i64) -> i1
 
       /* Forward the result of the shared computation to the "after" region.

diff  --git a/mlir/include/mlir/Dialect/SPIRV/IR/SPIRVGLSLOps.td b/mlir/include/mlir/Dialect/SPIRV/IR/SPIRVGLSLOps.td
index ea3e98e963a4..a566b7503a15 100644
--- a/mlir/include/mlir/Dialect/SPIRV/IR/SPIRVGLSLOps.td
+++ b/mlir/include/mlir/Dialect/SPIRV/IR/SPIRVGLSLOps.td
@@ -932,7 +932,7 @@ def SPV_GLSLUClampOp : SPV_GLSLTernaryArithmeticOp<"UClamp", 44, SPV_SignlessOrU
     <!-- End of AutoGen section -->
     ```
     uclamp-op ::= ssa-id `=` `spv.GLSL.UClamp` ssa-use, ssa-use, ssa-use `:`
-               unsgined-signless-scalar-vector-type
+               unsigned-signless-scalar-vector-type
     ```
     #### Example:
 

diff  --git a/mlir/include/mlir/Dialect/StandardOps/IR/Ops.td b/mlir/include/mlir/Dialect/StandardOps/IR/Ops.td
index 1f7b888167cd..3ae7ad54b80f 100644
--- a/mlir/include/mlir/Dialect/StandardOps/IR/Ops.td
+++ b/mlir/include/mlir/Dialect/StandardOps/IR/Ops.td
@@ -1832,7 +1832,7 @@ def GlobalMemrefOp : Std_Op<"global_memref", [Symbol]> {
     // Uninitialized externally visible variable.
     global_memref @z : memref<3xf16> = uninitialized
 
-    // Externally visibile constant variable.
+    // Externally visible constant variable.
     global_memref constant @c : memref<2xi32> = dense<1, 4>
     ```
   }];

diff  --git a/mlir/include/mlir/Dialect/StandardOps/Transforms/Passes.td b/mlir/include/mlir/Dialect/StandardOps/Transforms/Passes.td
index 9623dd14a296..9b27f2f03677 100644
--- a/mlir/include/mlir/Dialect/StandardOps/Transforms/Passes.td
+++ b/mlir/include/mlir/Dialect/StandardOps/Transforms/Passes.td
@@ -42,7 +42,7 @@ def FuncBufferize : Pass<"func-bufferize", "ModuleOp"> {
     As this pass rewrites function operations, it also rewrites the
     corresponding return operations. Other return-like operations that
     implement the `ReturnLike` trait are not rewritten in general, as they
-    require that the correspondign parent operation is also rewritten.
+    require that the corresponding parent operation is also rewritten.
     Finally, this pass fails for unknown terminators, as we cannot decide
     whether they need rewriting. 
   }];

diff  --git a/mlir/include/mlir/Dialect/Tosa/Utils/QuantUtils.h b/mlir/include/mlir/Dialect/Tosa/Utils/QuantUtils.h
index 0ebec4edc315..f01946b40cf6 100644
--- a/mlir/include/mlir/Dialect/Tosa/Utils/QuantUtils.h
+++ b/mlir/include/mlir/Dialect/Tosa/Utils/QuantUtils.h
@@ -23,7 +23,7 @@ namespace mlir {
 namespace tosa {
 
 //===----------------------------------------------------------------------===//
-// Utililty functions to support quantization handling in Tosa.
+// Utility functions to support quantization handling in Tosa.
 //===----------------------------------------------------------------------===//
 
 /// From a scale value, computes multiplier and shift values

diff  --git a/mlir/include/mlir/Dialect/Vector/VectorOps.td b/mlir/include/mlir/Dialect/Vector/VectorOps.td
index e031f87cfb8e..0a98b9ffe996 100644
--- a/mlir/include/mlir/Dialect/Vector/VectorOps.td
+++ b/mlir/include/mlir/Dialect/Vector/VectorOps.td
@@ -466,7 +466,7 @@ def Vector_ExtractMapOp :
     along each dimension.
 
     The dimension associated to each element of `ids` used to extract are
-    implicitly deduced from the the destination type. For each dimension the
+    implicitly deduced from the destination type. For each dimension the
     multiplicity is the destination dimension size divided by the source
     dimension size, each dimension with a multiplicity greater than 1 is
     associated to the next id, following ids order.

diff  --git a/mlir/include/mlir/IR/ImplicitLocOpBuilder.h b/mlir/include/mlir/IR/ImplicitLocOpBuilder.h
index 2dc7c34f4e85..ff85f2b5a382 100644
--- a/mlir/include/mlir/IR/ImplicitLocOpBuilder.h
+++ b/mlir/include/mlir/IR/ImplicitLocOpBuilder.h
@@ -17,7 +17,7 @@
 
 namespace mlir {
 
-/// ImplictLocOpBuilder maintains a 'current location', allowing use of the
+/// ImplicitLocOpBuilder maintains a 'current location', allowing use of the
 /// create<> method without specifying the location.  It is otherwise the same
 /// as OpBuilder.
 class ImplicitLocOpBuilder : public mlir::OpBuilder {
@@ -120,4 +120,4 @@ class ImplicitLocOpBuilder : public mlir::OpBuilder {
 
 } // namespace mlir
 
-#endif // MLIR_IR_IMPLICITLOCOPBUILDER_H
\ No newline at end of file
+#endif // MLIR_IR_IMPLICITLOCOPBUILDER_H

diff  --git a/mlir/include/mlir/IR/OpDefinition.h b/mlir/include/mlir/IR/OpDefinition.h
index e698ced314a1..622952c76289 100644
--- a/mlir/include/mlir/IR/OpDefinition.h
+++ b/mlir/include/mlir/IR/OpDefinition.h
@@ -897,7 +897,7 @@ struct SingleBlockImplicitTerminator {
 
     /// Ensure that the given region has the terminator required by this trait.
     /// If OpBuilder is provided, use it to build the terminator and notify the
-    /// OpBuilder litsteners accordingly. If only a Builder is provided, locally
+    /// OpBuilder listeners accordingly. If only a Builder is provided, locally
     /// construct an OpBuilder with no listeners; this should only be used if no
     /// OpBuilder is available at the call site, e.g., in the parser.
     static void ensureTerminator(Region &region, Builder &builder,

diff  --git a/mlir/include/mlir/Pass/PassRegistry.h b/mlir/include/mlir/Pass/PassRegistry.h
index 9937102f316d..8def0f31ad15 100644
--- a/mlir/include/mlir/Pass/PassRegistry.h
+++ b/mlir/include/mlir/Pass/PassRegistry.h
@@ -246,9 +246,9 @@ class PassPipelineCLParser {
   std::unique_ptr<detail::PassPipelineCLParserImpl> impl;
 };
 
-/// This class implements a command-line parser spefically for MLIR pass names.
-/// It registers a cl option with a given argument and description that accepts
-/// a comma delimited list of pass names.
+/// This class implements a command-line parser specifically for MLIR pass
+/// names. It registers a cl option with a given argument and description that
+/// accepts a comma delimited list of pass names.
 class PassNameCLParser {
 public:
   /// Construct a parser with the given command line description.

diff  --git a/mlir/include/mlir/Support/IndentedOstream.h b/mlir/include/mlir/Support/IndentedOstream.h
index c901bb6ae2dd..6d0701607f46 100644
--- a/mlir/include/mlir/Support/IndentedOstream.h
+++ b/mlir/include/mlir/Support/IndentedOstream.h
@@ -67,7 +67,7 @@ class raw_indented_ostream : public raw_ostream {
     return *this;
   }
 
-  /// Emits whitespace and sets the indendation for the stream.
+  /// Emits whitespace and sets the indentation for the stream.
   raw_indented_ostream &indent(int with) {
     os.indent(with);
     atStartOfLine = false;

diff  --git a/mlir/include/mlir/Target/LLVMIR/ModuleTranslation.h b/mlir/include/mlir/Target/LLVMIR/ModuleTranslation.h
index 4a1871cac4dc..d1f42e06ae5d 100644
--- a/mlir/include/mlir/Target/LLVMIR/ModuleTranslation.h
+++ b/mlir/include/mlir/Target/LLVMIR/ModuleTranslation.h
@@ -154,7 +154,7 @@ class ModuleTranslation {
   DenseMap<Block *, llvm::BasicBlock *> blockMapping;
 
   /// A mapping between MLIR LLVM dialect terminators and LLVM IR terminators
-  /// they are converted to. This allows for conneting PHI nodes to the source
+  /// they are converted to. This allows for connecting PHI nodes to the source
   /// values after all operations are converted.
   DenseMap<Operation *, llvm::Instruction *> branchMapping;
 };

diff  --git a/mlir/include/mlir/Target/LLVMIR/TypeTranslation.h b/mlir/include/mlir/Target/LLVMIR/TypeTranslation.h
index 6b8e29ad7d9c..c030d51305e4 100644
--- a/mlir/include/mlir/Target/LLVMIR/TypeTranslation.h
+++ b/mlir/include/mlir/Target/LLVMIR/TypeTranslation.h
@@ -42,7 +42,7 @@ class TypeToLLVMIRTranslator {
   TypeToLLVMIRTranslator(llvm::LLVMContext &context);
   ~TypeToLLVMIRTranslator();
 
-  /// Returns the perferred alignment for the type given the data layout. Note
+  /// Returns the preferred alignment for the type given the data layout. Note
   /// that this will perform type conversion and store its results for future
   /// uses.
   // TODO: this should be removed when MLIR has proper data layout.

diff  --git a/mlir/include/mlir/Transforms/Bufferize.h b/mlir/include/mlir/Transforms/Bufferize.h
index 7fd19a9eeaf1..8e1f9c0fe1f7 100644
--- a/mlir/include/mlir/Transforms/Bufferize.h
+++ b/mlir/include/mlir/Transforms/Bufferize.h
@@ -45,7 +45,7 @@ class BufferizeTypeConverter : public TypeConverter {
 /// "legal" in the given ConversionTarget.
 ///
 /// This function should be called by all bufferization passes using
-/// BufferizeTypeConverter so that materializations work proprely. One exception
+/// BufferizeTypeConverter so that materializations work properly. One exception
 /// is bufferization passes doing "full" conversions, where it can be desirable
 /// for even the materializations to remain illegal so that they are eliminated,
 /// such as via the patterns in

diff  --git a/mlir/lib/Analysis/AffineStructures.cpp b/mlir/lib/Analysis/AffineStructures.cpp
index 341dde523e8b..51141e6f6184 100644
--- a/mlir/lib/Analysis/AffineStructures.cpp
+++ b/mlir/lib/Analysis/AffineStructures.cpp
@@ -1061,7 +1061,7 @@ FlatAffineConstraints::findIntegerSample() const {
 /// constant term.
 static int64_t valueAt(ArrayRef<int64_t> expr, ArrayRef<int64_t> point) {
   assert(expr.size() == 1 + point.size() &&
-         "Dimensionalities of point and expresion don't match!");
+         "Dimensionalities of point and expression don't match!");
   int64_t value = expr.back();
   for (unsigned i = 0; i < point.size(); ++i)
     value += expr[i] * point[i];

diff  --git a/mlir/lib/Bindings/Python/IRModules.cpp b/mlir/lib/Bindings/Python/IRModules.cpp
index f7a8e8ec3bcb..2dcee494715d 100644
--- a/mlir/lib/Bindings/Python/IRModules.cpp
+++ b/mlir/lib/Bindings/Python/IRModules.cpp
@@ -207,7 +207,7 @@ class PyRegionList {
   }
 
   static void bind(py::module &m) {
-    py::class_<PyRegionList>(m, "ReqionSequence")
+    py::class_<PyRegionList>(m, "RegionSequence")
         .def("__len__", &PyRegionList::dunderLen)
         .def("__getitem__", &PyRegionList::dunderGetItem);
   }

diff  --git a/mlir/lib/CAPI/Transforms/Passes.cpp b/mlir/lib/CAPI/Transforms/Passes.cpp
index 7452bd996308..af4f2011fa77 100644
--- a/mlir/lib/CAPI/Transforms/Passes.cpp
+++ b/mlir/lib/CAPI/Transforms/Passes.cpp
@@ -1,4 +1,4 @@
-//===- CAPIPasses.cpp - C API for Tranformations Passes -------------------===//
+//===- CAPIPasses.cpp - C API for Transformations Passes ------------------===//
 //
 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
 // See https://llvm.org/LICENSE.txt for license information.

diff  --git a/mlir/lib/Conversion/GPUCommon/ConvertKernelFuncToBlob.cpp b/mlir/lib/Conversion/GPUCommon/ConvertKernelFuncToBlob.cpp
index f21ee1f23547..447b00567776 100644
--- a/mlir/lib/Conversion/GPUCommon/ConvertKernelFuncToBlob.cpp
+++ b/mlir/lib/Conversion/GPUCommon/ConvertKernelFuncToBlob.cpp
@@ -131,7 +131,7 @@ OwnedBlob GpuKernelToBlobPass::convertModuleToBlob(llvm::Module &llvmModule,
     targetMachine.reset(target->createTargetMachine(triple.str(), targetChip,
                                                     features, {}, {}));
     if (targetMachine == nullptr) {
-      emitError(loc, "connot initialize target machine");
+      emitError(loc, "cannot initialize target machine");
       return {};
     }
   }

diff  --git a/mlir/lib/Conversion/PDLToPDLInterp/Predicate.h b/mlir/lib/Conversion/PDLToPDLInterp/Predicate.h
index 2597f84f1d46..b3919609a640 100644
--- a/mlir/lib/Conversion/PDLToPDLInterp/Predicate.h
+++ b/mlir/lib/Conversion/PDLToPDLInterp/Predicate.h
@@ -419,7 +419,7 @@ class PredicateUniquer : public StorageUniquer {
 // PredicateBuilder
 //===----------------------------------------------------------------------===//
 
-/// This class provides utilties for constructing predicates.
+/// This class provides utilities for constructing predicates.
 class PredicateBuilder {
 public:
   PredicateBuilder(PredicateUniquer &uniquer, MLIRContext *ctx)

diff  --git a/mlir/lib/Conversion/SPIRVToLLVM/ConvertLaunchFuncToLLVMCalls.cpp b/mlir/lib/Conversion/SPIRVToLLVM/ConvertLaunchFuncToLLVMCalls.cpp
index 8c42c2a7dc92..b94f92f37ee6 100644
--- a/mlir/lib/Conversion/SPIRVToLLVM/ConvertLaunchFuncToLLVMCalls.cpp
+++ b/mlir/lib/Conversion/SPIRVToLLVM/ConvertLaunchFuncToLLVMCalls.cpp
@@ -200,7 +200,7 @@ class GPULaunchLowering : public ConvertOpToLLVMPattern<gpu::LaunchFuncOp> {
     auto numKernelOperands = launchOp.getNumKernelOperands();
     auto kernelOperands = operands.take_back(numKernelOperands);
     for (auto operand : llvm::enumerate(kernelOperands)) {
-      // Check if the kernel's opernad is a ranked memref.
+      // Check if the kernel's operand is a ranked memref.
       auto memRefType = launchOp.getKernelOperand(operand.index())
                             .getType()
                             .dyn_cast<MemRefType>();

diff  --git a/mlir/lib/Dialect/Async/Transforms/AsyncParallelFor.cpp b/mlir/lib/Dialect/Async/Transforms/AsyncParallelFor.cpp
index d6553974bc38..f4f6e0bdf956 100644
--- a/mlir/lib/Dialect/Async/Transforms/AsyncParallelFor.cpp
+++ b/mlir/lib/Dialect/Async/Transforms/AsyncParallelFor.cpp
@@ -185,7 +185,7 @@ AsyncParallelForRewrite::matchAndRewrite(scf::ParallelOp op,
     return [&, loopIdx](OpBuilder &b, Location loc, Value iv, ValueRange args) {
       blockInductionVars[loopIdx] = iv;
 
-      // Continute building async loop nest.
+      // Continue building async loop nest.
       if (loopIdx < op.getNumLoops() - 1) {
         b.create<scf::ForOp>(
             loc, blockLowerBounds[loopIdx + 1], blockUpperBounds[loopIdx + 1],

diff  --git a/mlir/lib/Dialect/LLVMIR/IR/TypeDetail.h b/mlir/lib/Dialect/LLVMIR/IR/TypeDetail.h
index a02a77d5a4c0..30386da0c10e 100644
--- a/mlir/lib/Dialect/LLVMIR/IR/TypeDetail.h
+++ b/mlir/lib/Dialect/LLVMIR/IR/TypeDetail.h
@@ -91,7 +91,7 @@ struct LLVMStructTypeStorage : public TypeStorage {
     /// Returns the identifier of a key for identified structs.
     StringRef getIdentifier() const {
       assert(isIdentified() &&
-             "non-identified struct key canont have an identifier");
+             "non-identified struct key cannot have an identifier");
       return name;
     }
 
@@ -219,7 +219,7 @@ struct LLVMStructTypeStorage : public TypeStorage {
                                            key.isOpaque());
   }
 
-  /// Hook into the type unquing infrastructure.
+  /// Hook into the type uniquing infrastructure.
   bool operator==(const KeyTy &other) const { return getKey() == other; };
   static llvm::hash_code hashKey(const KeyTy &key) { return key.hashValue(); }
   static LLVMStructTypeStorage *construct(TypeStorageAllocator &allocator,

diff  --git a/mlir/lib/Dialect/Linalg/Transforms/Fusion.cpp b/mlir/lib/Dialect/Linalg/Transforms/Fusion.cpp
index b525108d22ab..f9908af29313 100644
--- a/mlir/lib/Dialect/Linalg/Transforms/Fusion.cpp
+++ b/mlir/lib/Dialect/Linalg/Transforms/Fusion.cpp
@@ -698,7 +698,7 @@ collectFusableLoops(ArrayRef<LinalgOp> ops,
       // the operation, if the accesses in the producer/consumer are transposes
       // of each other, the loop bounds for the tiled producer can be
       // manipulated accordingly. This requires some additional bookkeeping in
-      // the implementation of tile+fuse that is defered to later.
+      // the implementation of tile+fuse that is deferred to later.
       if (doesTransposeAccess(*consumerLoopToProducerLoop, fusableLoops)) {
         op.emitRemark("unhandled fusion when fusion requires permutation");
         return {};
@@ -769,8 +769,7 @@ FusableOpDependencesTy mlir::linalg::findAllFusableDependences(
       if (!consumerMap.isProjectedPermutation()) {
         op.emitRemark(
             "unhandled case where indexing map for fused view in the consumer "
-            "is "
-            "not a projected permuration while fusing at index ")
+            "is not a projected permutation while fusing at index ")
             << operandIndex;
         return FusableOpDependencesTy{};
       }

diff  --git a/mlir/lib/Dialect/Linalg/Transforms/Sparsification.cpp b/mlir/lib/Dialect/Linalg/Transforms/Sparsification.cpp
index ed81d5e24805..dbf8d5ffcb8c 100644
--- a/mlir/lib/Dialect/Linalg/Transforms/Sparsification.cpp
+++ b/mlir/lib/Dialect/Linalg/Transforms/Sparsification.cpp
@@ -132,7 +132,7 @@ class Merger {
   }
 
   /// Computes a single conjunction of two lattice points by taking the "union"
-  /// of loop indices (effectively constucting a larger "intersection" of those
+  /// of loop indices (effectively constructing a larger "intersection" of those
   /// indices) with a newly constructed tensor (sub)expression of given kind.
   /// Returns the index of the new lattice point.
   unsigned conjLatPoint(Kind kind, unsigned p0, unsigned p1) {

diff  --git a/mlir/lib/Dialect/PDL/IR/PDL.cpp b/mlir/lib/Dialect/PDL/IR/PDL.cpp
index 49f7f273af19..7791632216c8 100644
--- a/mlir/lib/Dialect/PDL/IR/PDL.cpp
+++ b/mlir/lib/Dialect/PDL/IR/PDL.cpp
@@ -296,7 +296,7 @@ static LogicalResult verify(OperationOp op) {
                             << resultTypes.size() << " constraints";
   }
 
-  // If the operation is within a rewrite body and doesn't have type inferrence,
+  // If the operation is within a rewrite body and doesn't have type inference,
   // ensure that the result types can be resolved.
   if (isWithinRewrite && !op.hasTypeInference()) {
     if (failed(verifyResultTypesAreInferrable(op, opResults, resultTypes)))

diff  --git a/mlir/lib/Dialect/SPIRV/IR/SPIRVTypes.cpp b/mlir/lib/Dialect/SPIRV/IR/SPIRVTypes.cpp
index fa8576a6753a..8bd54197c7ea 100644
--- a/mlir/lib/Dialect/SPIRV/IR/SPIRVTypes.cpp
+++ b/mlir/lib/Dialect/SPIRV/IR/SPIRVTypes.cpp
@@ -752,7 +752,7 @@ struct spirv::detail::StructTypeStorage : public TypeStorage {
   /// An identified struct type is uniqued only by the first part (field 0)
   /// of the key.
   ///
-  /// A literal struct type is unqiued only by the second part (fields 1, 2, and
+  /// A literal struct type is uniqued only by the second part (fields 1, 2, and
   /// 3) of the key. The identifier field (field 0) must be empty.
   using KeyTy =
       std::tuple<StringRef, ArrayRef<Type>, ArrayRef<StructType::OffsetInfo>,

diff  --git a/mlir/lib/Dialect/SPIRV/Linking/ModuleCombiner/ModuleCombiner.cpp b/mlir/lib/Dialect/SPIRV/Linking/ModuleCombiner/ModuleCombiner.cpp
index 1f4bfd37bddc..b91d7438e7c0 100644
--- a/mlir/lib/Dialect/SPIRV/Linking/ModuleCombiner/ModuleCombiner.cpp
+++ b/mlir/lib/Dialect/SPIRV/Linking/ModuleCombiner/ModuleCombiner.cpp
@@ -6,7 +6,7 @@
 //
 //===----------------------------------------------------------------------===//
 //
-// This file implements the the SPIR-V module combiner library.
+// This file implements the SPIR-V module combiner library.
 //
 //===----------------------------------------------------------------------===//
 
@@ -81,7 +81,7 @@ emplaceOrGetReplacementSymbol(KeyTy key, SymbolOpTy symbolOp,
 /// Note: We use the operation's name (not the symbol name) as part of the hash
 /// computation. This prevents, for example, mistakenly considering a global
 /// variable and a spec constant as duplicates because their descriptor set +
-/// binding and spec_id, repectively, happen to hash to the same value.
+/// binding and spec_id, respectively, happen to hash to the same value.
 static llvm::hash_code computeHash(SymbolOpInterface symbolOp) {
   llvm::hash_code hashCode(0);
   hashCode = llvm::hash_combine(symbolOp->getName());
@@ -140,7 +140,7 @@ combine(llvm::MutableArrayRef<spirv::ModuleOp> modules,
   // renamed in order to maintain the conflicting symbol in the input module
   // being merged. For example, if the conflict is between a global variable in
   // the current combined module and a function in the input module, the global
-  // varaible is renamed. In order to notify listeners of the symbol updates in
+  // variable is renamed. In order to notify listeners of the symbol updates in
   // such cases, we need to keep track of the module from which the renamed
   // symbol in the combined module originated. This map keeps such information.
   DenseMap<StringRef, spirv::ModuleOp> symNameToModuleMap;
@@ -156,7 +156,7 @@ combine(llvm::MutableArrayRef<spirv::ModuleOp> modules,
     spirv::ModuleOp moduleClone = module.clone();
 
     // In the combined module, rename all symbols that conflict with symbols
-    // from the current input module. This renmaing applies to all ops except
+    // from the current input module. This renaming applies to all ops except
     // for spv.funcs. This way, if the conflicting op in the input module is
     // non-spv.func, we rename that symbol instead and maintain the spv.func in
     // the combined module name as it is.
@@ -184,7 +184,7 @@ combine(llvm::MutableArrayRef<spirv::ModuleOp> modules,
           symRenameListener(originalModule, oldSymName, newSymName);
 
           // Since the symbol name is updated, there is no need to maintain the
-          // entry that assocaites the old symbol name with the original module.
+          // entry that associates the old symbol name with the original module.
           symNameToModuleMap.erase(oldSymName);
           // Instead, add a new entry to map the new symbol name to the original
           // module in case it gets renamed again later.

diff  --git a/mlir/lib/Dialect/StandardOps/IR/Ops.cpp b/mlir/lib/Dialect/StandardOps/IR/Ops.cpp
index c73a9a41719c..c4a8a0155f50 100644
--- a/mlir/lib/Dialect/StandardOps/IR/Ops.cpp
+++ b/mlir/lib/Dialect/StandardOps/IR/Ops.cpp
@@ -1461,8 +1461,7 @@ struct DimOfMemRefReshape : public OpRewritePattern<DimOp> {
   }
 };
 
-/// Fold dim of a dim of a cast into the the dim of the source of the tensor
-/// cast.
+/// Fold dim of a dim of a cast into the dim of the source of the tensor cast.
 template <typename CastOpTy>
 struct DimOfCastOp : public OpRewritePattern<DimOp> {
   using OpRewritePattern<DimOp>::OpRewritePattern;

diff  --git a/mlir/lib/Dialect/StandardOps/Transforms/ExpandOps.cpp b/mlir/lib/Dialect/StandardOps/Transforms/ExpandOps.cpp
index b3052cd53333..27e61dc7a3ac 100644
--- a/mlir/lib/Dialect/StandardOps/Transforms/ExpandOps.cpp
+++ b/mlir/lib/Dialect/StandardOps/Transforms/ExpandOps.cpp
@@ -1,4 +1,4 @@
-//===- StdExpandDivs.cpp - Code to prepare Std for lowring Divs 0to LLVM  -===//
+//===- StdExpandDivs.cpp - Code to prepare Std for lowering Divs to LLVM  -===//
 //
 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
 // See https://llvm.org/LICENSE.txt for license information.
@@ -7,7 +7,7 @@
 //===----------------------------------------------------------------------===//
 //
 // This file Std transformations to expand Divs operation to help for the
-// lowering to LLVM. Currently implemented tranformations are Ceil and Floor
+// lowering to LLVM. Currently implemented transformations are Ceil and Floor
 // for Signed Integers.
 //
 //===----------------------------------------------------------------------===//

diff  --git a/mlir/lib/Dialect/Tosa/Transforms/TosaMakeBroadcastable.cpp b/mlir/lib/Dialect/Tosa/Transforms/TosaMakeBroadcastable.cpp
index 1b12384ac2c7..d9b0b3bd832d 100644
--- a/mlir/lib/Dialect/Tosa/Transforms/TosaMakeBroadcastable.cpp
+++ b/mlir/lib/Dialect/Tosa/Transforms/TosaMakeBroadcastable.cpp
@@ -46,7 +46,7 @@ using namespace mlir::tosa;
 static void computeReshapeOutput(ArrayRef<int64_t> higherRankShape,
                                  ArrayRef<int64_t> lowerRankShape,
                                  SmallVectorImpl<int64_t> &reshapeOutputShape) {
-  // Intialize new shapes with [1] * higherRank.
+  // Initialize new shapes with [1] * higherRank.
   int64_t higherRank = higherRankShape.size();
   int64_t lowerRank = lowerRankShape.size();
 

diff  --git a/mlir/lib/Dialect/Vector/VectorOps.cpp b/mlir/lib/Dialect/Vector/VectorOps.cpp
index 5acc5f5a7ce2..5d9c2e63b094 100644
--- a/mlir/lib/Dialect/Vector/VectorOps.cpp
+++ b/mlir/lib/Dialect/Vector/VectorOps.cpp
@@ -1908,7 +1908,7 @@ class StridedSliceBroadcast final
     auto dstVecType = op.getType().cast<VectorType>();
     unsigned dstRank = dstVecType.getRank();
     unsigned rankDiff = dstRank - srcRrank;
-    // Check if the most inner dimensions of the source of the broacast are the
+    // Check if the most inner dimensions of the source of the broadcast are the
     // same as the destination of the extract. If this is the case we can just
     // use a broadcast as the original dimensions are untouched.
     bool lowerDimMatch = true;

diff  --git a/mlir/lib/IR/AsmPrinter.cpp b/mlir/lib/IR/AsmPrinter.cpp
index 1679fa41c8b9..c67b7712e977 100644
--- a/mlir/lib/IR/AsmPrinter.cpp
+++ b/mlir/lib/IR/AsmPrinter.cpp
@@ -378,7 +378,7 @@ class DummyAliasOperationPrinter : private OpAsmPrinter {
 private:
   /// Print the given operation in the generic form.
   void printGenericOp(Operation *op) override {
-    // Consider nested opertions for aliases.
+    // Consider nested operations for aliases.
     if (op->getNumRegions() != 0) {
       for (Region &region : op->getRegions())
         printRegion(region, /*printEntryBlockArgs=*/true,
@@ -611,7 +611,7 @@ void AliasInitializer::visit(Type type) {
   if (succeeded(generateAlias(type, aliasToType)))
     return;
 
-  // Visit several subtypes that contain types or atttributes.
+  // Visit several subtypes that contain types or attributes.
   if (auto funcType = type.dyn_cast<FunctionType>()) {
     // Visit input and result types for functions.
     for (auto input : funcType.getInputs())

diff  --git a/mlir/lib/Rewrite/ByteCode.h b/mlir/lib/Rewrite/ByteCode.h
index 7126037f864a..38dbbcd855ce 100644
--- a/mlir/lib/Rewrite/ByteCode.h
+++ b/mlir/lib/Rewrite/ByteCode.h
@@ -143,7 +143,7 @@ class PDLByteCode {
                        PDLByteCodeMutableState &state,
                        SmallVectorImpl<MatchResult> *matches) const;
 
-  /// A vector containing pointers to unqiued data. The storage is intentionally
+  /// A vector containing pointers to uniqued data. The storage is intentionally
   /// opaque such that we can store a wide range of data types. The types of
   /// data stored here include:
   ///  * Attribute, Identifier, OperationName, Type

diff  --git a/mlir/lib/Target/SPIRV/Serialization.cpp b/mlir/lib/Target/SPIRV/Serialization.cpp
index c530cccd4232..227008151f87 100644
--- a/mlir/lib/Target/SPIRV/Serialization.cpp
+++ b/mlir/lib/Target/SPIRV/Serialization.cpp
@@ -1044,7 +1044,7 @@ bool Serializer::isInterfaceStructPtrType(Type type) const {
 LogicalResult Serializer::processType(Location loc, Type type,
                                       uint32_t &typeID) {
   // Maintains a set of names for nested identified struct types. This is used
-  // to properly serialize resursive references.
+  // to properly serialize recursive references.
   llvm::SetVector<StringRef> serializationCtx;
   return processTypeImpl(loc, type, typeID, serializationCtx);
 }

diff  --git a/mlir/lib/Transforms/BufferUtils.cpp b/mlir/lib/Transforms/BufferUtils.cpp
index 4a64570fdfa4..ab39f57b3fcc 100644
--- a/mlir/lib/Transforms/BufferUtils.cpp
+++ b/mlir/lib/Transforms/BufferUtils.cpp
@@ -6,7 +6,7 @@
 //
 //===----------------------------------------------------------------------===//
 //
-// This file implements utilties for buffer optimization passes.
+// This file implements utilities for buffer optimization passes.
 //
 //===----------------------------------------------------------------------===//
 

diff  --git a/mlir/lib/Transforms/Utils/FoldUtils.cpp b/mlir/lib/Transforms/Utils/FoldUtils.cpp
index 0c186baacb84..59af919b9335 100644
--- a/mlir/lib/Transforms/Utils/FoldUtils.cpp
+++ b/mlir/lib/Transforms/Utils/FoldUtils.cpp
@@ -61,9 +61,9 @@ static Operation *materializeConstant(Dialect *dialect, OpBuilder &builder,
     return constOp;
   }
 
-  // TODO: To faciliate splitting the std dialect (PR48490), have a special case
-  // for falling back to std.constant. Eventually, we will have separate ops
-  // tensor.constant, int.constant, float.constant, etc. that live in their
+  // TODO: To facilitate splitting the std dialect (PR48490), have a special
+  // case for falling back to std.constant. Eventually, we will have separate
+  // ops tensor.constant, int.constant, float.constant, etc. that live in their
   // respective dialects, which will allow each dialect to implement the
   // materializeConstant hook above.
   //

diff  --git a/mlir/lib/Transforms/Utils/LoopUtils.cpp b/mlir/lib/Transforms/Utils/LoopUtils.cpp
index 1f549ca9efda..cb7a64048f08 100644
--- a/mlir/lib/Transforms/Utils/LoopUtils.cpp
+++ b/mlir/lib/Transforms/Utils/LoopUtils.cpp
@@ -507,7 +507,8 @@ checkTilingLegality(MutableArrayRef<mlir::AffineForOp> origLoops) {
   return success(checkTilingLegalityImpl(origLoops));
 }
 
-/// Check if the input data is valid and wheter tiled code will be legal or not.
+/// Check if the input data is valid and whether tiled code will be legal or
+/// not.
 template <typename t>
 void performPreTilingChecks(MutableArrayRef<AffineForOp> input,
                             ArrayRef<t> tileSizes) {

diff  --git a/mlir/lib/Transforms/Utils/RegionUtils.cpp b/mlir/lib/Transforms/Utils/RegionUtils.cpp
index f543d191be7d..dd2de96e0118 100644
--- a/mlir/lib/Transforms/Utils/RegionUtils.cpp
+++ b/mlir/lib/Transforms/Utils/RegionUtils.cpp
@@ -516,7 +516,7 @@ LogicalResult BlockMergeCluster::addToCluster(BlockEquivalenceData &blockData) {
 
     // If the lhs or rhs has external uses, the blocks cannot be merged as the
     // merged version of this operation will not be either the lhs or rhs
-    // alone (thus semantically incorrect), but some mix dependening on which
+    // alone (thus semantically incorrect), but some mix dependending on which
     // block preceeded this.
     // TODO allow merging of operations when one block does not dominate the
     // other


        


More information about the llvm-branch-commits mailing list