[Mlir-commits] [mlir] 5aacce3 - [mlir] NFC: Fix trivial typo
Kazuaki Ishizaki
llvmlistbot at llvm.org
Sat Apr 4 19:30:45 PDT 2020
Author: Kazuaki Ishizaki
Date: 2020-04-05T11:30:30+09:00
New Revision: 5aacce3db2e3929287be97de2ca22243531cc87f
URL: https://github.com/llvm/llvm-project/commit/5aacce3db2e3929287be97de2ca22243531cc87f
DIFF: https://github.com/llvm/llvm-project/commit/5aacce3db2e3929287be97de2ca22243531cc87f.diff
LOG: [mlir] NFC: Fix trivial typo
Differential Revision: https://reviews.llvm.org/D77473
Added:
Modified:
mlir/docs/Dialects/LLVM.md
mlir/docs/Dialects/Standard.md
mlir/docs/LangRef.md
mlir/docs/RationaleLinalgDialect.md
mlir/docs/doxygen.cfg.in
mlir/examples/toy/Ch7/mlir/Dialect.cpp
mlir/include/mlir/Analysis/SliceAnalysis.h
mlir/include/mlir/Conversion/StandardToLLVM/ConvertStandardToLLVM.h
mlir/include/mlir/Conversion/StandardToLLVM/ConvertStandardToLLVMPass.h
mlir/include/mlir/Dialect/Linalg/IR/LinalgStructuredOps.td
mlir/include/mlir/Dialect/StandardOps/IR/Ops.td
mlir/include/mlir/IR/Attributes.h
mlir/include/mlir/IR/StandardTypes.h
mlir/include/mlir/Pass/AnalysisManager.h
mlir/include/mlir/TableGen/Pattern.h
mlir/lib/Conversion/GPUToSPIRV/ConvertGPUToSPIRV.cpp
mlir/lib/Conversion/LoopsToGPU/LoopsToGPU.cpp
mlir/lib/Conversion/StandardToLLVM/StandardToLLVM.cpp
mlir/lib/Conversion/StandardToSPIRV/ConvertStandardToSPIRV.cpp
mlir/lib/Dialect/GPU/IR/GPUDialect.cpp
mlir/lib/Dialect/GPU/Transforms/AllReduceLowering.cpp
mlir/lib/Dialect/GPU/Transforms/KernelOutlining.cpp
mlir/lib/Dialect/LoopOps/Transforms/ParallelLoopSpecialization.cpp
mlir/lib/Dialect/SPIRV/SPIRVOps.cpp
mlir/lib/Dialect/Vector/VectorOps.cpp
mlir/lib/IR/AttributeDetail.h
mlir/lib/IR/Operation.cpp
mlir/lib/IR/SymbolTable.cpp
mlir/lib/Pass/PassTiming.cpp
mlir/lib/Transforms/Utils/LoopUtils.cpp
mlir/test/Conversion/AffineToStandard/lower-affine.mlir
mlir/test/Dialect/SPIRV/types.mlir
mlir/test/lib/Dialect/Test/TestPatterns.cpp
mlir/test/mlir-tblgen/op-format-spec.td
mlir/tools/mlir-tblgen/OpFormatGen.cpp
mlir/tools/mlir-tblgen/RewriterGen.cpp
mlir/tools/mlir-vulkan-runner/VulkanRuntime.cpp
mlir/tools/mlir-vulkan-runner/VulkanRuntime.h
mlir/utils/spirv/gen_spirv_dialect.py
Removed:
################################################################################
diff --git a/mlir/docs/Dialects/LLVM.md b/mlir/docs/Dialects/LLVM.md
index e512675565fd..5264f986b0ef 100644
--- a/mlir/docs/Dialects/LLVM.md
+++ b/mlir/docs/Dialects/LLVM.md
@@ -96,7 +96,7 @@ Example:
llvm.func @func() attributes {
passthrough = ["noinline", // value-less attribute
["alignstack", "4"], // integer attribute with value
- ["other", "attr"]] // attrbute unknown to LLVM
+ ["other", "attr"]] // attribute unknown to LLVM
} {
llvm.return
}
diff --git a/mlir/docs/Dialects/Standard.md b/mlir/docs/Dialects/Standard.md
index a0f1f0ffe134..c33713624446 100644
--- a/mlir/docs/Dialects/Standard.md
+++ b/mlir/docs/Dialects/Standard.md
@@ -30,7 +30,7 @@ indices, and optionally two additional arguments corresponding to the stride (in
terms of number of elements) and the number of elements to transfer per stride.
The tag location is used by a dma_wait operation to check for completion. The
indices of the source memref, destination memref, and the tag memref have the
-same restrictions as any load/store operation in a affine context (whenever DMA
+same restrictions as any load/store operation in an affine context (whenever DMA
operations appear in an affine context). See
[restrictions on dimensions and symbols](Affine.md#restrictions-on-dimensions-and-symbols)
in affine contexts. This allows powerful static analysis and transformations in
diff --git a/mlir/docs/LangRef.md b/mlir/docs/LangRef.md
index f180075c0d73..ad507dc15971 100644
--- a/mlir/docs/LangRef.md
+++ b/mlir/docs/LangRef.md
@@ -1275,7 +1275,7 @@ Syntax:
affine-map-attribute ::= `affine_map` `<` affine-map `>`
```
-An affine-map attribute is an attribute that represents a affine-map object.
+An affine-map attribute is an attribute that represents an affine-map object.
#### Array Attribute
diff --git a/mlir/docs/RationaleLinalgDialect.md b/mlir/docs/RationaleLinalgDialect.md
index 01e205741fd4..6c39d91c32ab 100644
--- a/mlir/docs/RationaleLinalgDialect.md
+++ b/mlir/docs/RationaleLinalgDialect.md
@@ -532,7 +532,7 @@ with [Tensor Comprehensions](#lessonstc).
Of course, we are not advocating for using ML everywhere in the stack
immediately: low-level compilation and machine models are still quite performant
in LLVM. However, for the high-level and mid-level optimization problems,
-models need to be conditioned (probalistically) on the low-level
+models need to be conditioned (probabilistically) on the low-level
compiler which acts as a blackbox. For these reasons we prioritize the
design of IR and transformations with search-friendly properties over
building cost models.
diff --git a/mlir/docs/doxygen.cfg.in b/mlir/docs/doxygen.cfg.in
index 4bad63f23812..7db0309ddb50 100644
--- a/mlir/docs/doxygen.cfg.in
+++ b/mlir/docs/doxygen.cfg.in
@@ -1390,7 +1390,7 @@ EXT_LINKS_IN_WINDOW = NO
FORMULA_FONTSIZE = 10
-# Use the FORMULA_TRANPARENT tag to determine whether or not the images
+# Use the FORMULA_TRANSPARENT tag to determine whether or not the images
# generated for formulas are transparent PNGs. Transparent PNGs are not
# supported properly for IE 6.0, but are supported on all modern browsers.
#
diff --git a/mlir/examples/toy/Ch7/mlir/Dialect.cpp b/mlir/examples/toy/Ch7/mlir/Dialect.cpp
index dc66cebd0e5e..7d4ba0b0f6d4 100644
--- a/mlir/examples/toy/Ch7/mlir/Dialect.cpp
+++ b/mlir/examples/toy/Ch7/mlir/Dialect.cpp
@@ -192,7 +192,7 @@ static mlir::LogicalResult verifyConstantForType(mlir::Type type,
mlir::Attribute opaqueValue,
mlir::Operation *op) {
if (type.isa<mlir::TensorType>()) {
- // Check that the value is a elements attribute.
+ // Check that the value is an elements attribute.
auto attrValue = opaqueValue.dyn_cast<mlir::DenseFPElementsAttr>();
if (!attrValue)
return op->emitError("constant of TensorType must be initialized by "
diff --git a/mlir/include/mlir/Analysis/SliceAnalysis.h b/mlir/include/mlir/Analysis/SliceAnalysis.h
index af411465be6f..8d1bff5f7db7 100644
--- a/mlir/include/mlir/Analysis/SliceAnalysis.h
+++ b/mlir/include/mlir/Analysis/SliceAnalysis.h
@@ -30,12 +30,12 @@ using TransitiveFilter = std::function<bool(Operation *)>;
/// the transitive uses of op), **without** including that operation.
///
/// This additionally takes a TransitiveFilter which acts as a frontier:
-/// when looking at uses transitively, a operation that does not pass the
+/// when looking at uses transitively, an operation that does not pass the
/// filter is never propagated through. This allows in particular to carve out
/// the scope within a ForInst or the scope within an IfInst.
///
/// The implementation traverses the use chains in postorder traversal for
-/// efficiency reasons: if a operation is already in `forwardSlice`, no
+/// efficiency reasons: if an operation is already in `forwardSlice`, no
/// need to traverse its uses again. Since use-def chains form a DAG, this
/// terminates.
///
@@ -76,12 +76,12 @@ void getForwardSlice(
/// all the transitive defs of op), **without** including that operation.
///
/// This additionally takes a TransitiveFilter which acts as a frontier:
-/// when looking at defs transitively, a operation that does not pass the
+/// when looking at defs transitively, an operation that does not pass the
/// filter is never propagated through. This allows in particular to carve out
/// the scope within a ForInst or the scope within an IfInst.
///
/// The implementation traverses the def chains in postorder traversal for
-/// efficiency reasons: if a operation is already in `backwardSlice`, no
+/// efficiency reasons: if an operation is already in `backwardSlice`, no
/// need to traverse its definitions again. Since useuse-def chains form a DAG,
/// this terminates.
///
diff --git a/mlir/include/mlir/Conversion/StandardToLLVM/ConvertStandardToLLVM.h b/mlir/include/mlir/Conversion/StandardToLLVM/ConvertStandardToLLVM.h
index e1add00c5d99..fffdf3947a2e 100644
--- a/mlir/include/mlir/Conversion/StandardToLLVM/ConvertStandardToLLVM.h
+++ b/mlir/include/mlir/Conversion/StandardToLLVM/ConvertStandardToLLVM.h
@@ -127,7 +127,7 @@ class LLVMTypeConverter : public TypeConverter {
Location loc) override;
/// Gets the LLVM representation of the index type. The returned type is an
- /// integer type with the size confgured for this type converter.
+ /// integer type with the size configured for this type converter.
LLVM::LLVMType getIndexType();
/// Gets the bitwidth of the index type when converted to LLVM.
@@ -417,7 +417,7 @@ class ConvertOpToLLVMPattern : public ConvertToLLVMPattern {
namespace LLVM {
namespace detail {
-/// Replaces the given operaiton "op" with a new operation of type "targetOp"
+/// Replaces the given operation "op" with a new operation of type "targetOp"
/// and given operands.
LogicalResult oneToOneRewrite(Operation *op, StringRef targetOp,
ValueRange operands,
@@ -435,7 +435,7 @@ LogicalResult vectorOneToOneRewrite(Operation *op, StringRef targetOp,
/// "TargetOp" where the latter belongs to the LLVM dialect or an equivalent.
/// Upholds a convention that multi-result operations get converted into an
/// operation returning the LLVM IR structure type, in which case individual
-/// values must be extacted from using LLVM::ExtractValueOp before being used.
+/// values must be extracted from using LLVM::ExtractValueOp before being used.
template <typename SourceOp, typename TargetOp>
class OneToOneConvertToLLVMPattern : public ConvertOpToLLVMPattern<SourceOp> {
public:
diff --git a/mlir/include/mlir/Conversion/StandardToLLVM/ConvertStandardToLLVMPass.h b/mlir/include/mlir/Conversion/StandardToLLVM/ConvertStandardToLLVMPass.h
index c3c104bf9d21..d8c9d36c2e7b 100644
--- a/mlir/include/mlir/Conversion/StandardToLLVM/ConvertStandardToLLVMPass.h
+++ b/mlir/include/mlir/Conversion/StandardToLLVM/ConvertStandardToLLVMPass.h
@@ -54,7 +54,7 @@ void populateStdToLLVMBarePtrConversionPatterns(
bool useAlloca = false);
/// Value to pass as bitwidth for the index type when the converter is expected
-/// to derive the bitwith from the LLVM data layout.
+/// to derive the bitwidth from the LLVM data layout.
static constexpr unsigned kDeriveIndexBitwidthFromDataLayout = 0;
/// Creates a pass to convert the Standard dialect into the LLVMIR dialect.
diff --git a/mlir/include/mlir/Dialect/Linalg/IR/LinalgStructuredOps.td b/mlir/include/mlir/Dialect/Linalg/IR/LinalgStructuredOps.td
index 31b89bc1b2bf..fd3770af3592 100644
--- a/mlir/include/mlir/Dialect/Linalg/IR/LinalgStructuredOps.td
+++ b/mlir/include/mlir/Dialect/Linalg/IR/LinalgStructuredOps.td
@@ -256,7 +256,7 @@ def MatmulOp : LinalgStructured_Op<"matmul", [NInputs<2>, NOutputs<1>]> {
/// OptionalAttr<I64ArrayAttr>:$strides
/// OptionalAttr<I64ArrayAttr>:$dilations
/// OptionalAttr<I64ElementsAttr>:$padding
-/// `stirdes` denotes the step of each window along the dimension.
+/// `strides` denotes the step of each window along the dimension.
class PoolingBase_Op<string mnemonic, list<OpTrait> props>
: LinalgStructured_Op<mnemonic, props> {
let description = [{
diff --git a/mlir/include/mlir/Dialect/StandardOps/IR/Ops.td b/mlir/include/mlir/Dialect/StandardOps/IR/Ops.td
index d61e74fcfea6..533dde1981e8 100644
--- a/mlir/include/mlir/Dialect/StandardOps/IR/Ops.td
+++ b/mlir/include/mlir/Dialect/StandardOps/IR/Ops.td
@@ -349,7 +349,7 @@ def AssumeAlignmentOp : Std_Op<"assume_alignment"> {
let summary =
"assertion that gives alignment information to the input memref";
let description = [{
- The `assume_alignment` operation takes a memref and a integer of alignment
+ The `assume_alignment` operation takes a memref and an integer of alignment
value, and internally annotates the buffer with the given alignment. If
the buffer isn't aligned to the given alignment, the behavior is undefined.
diff --git a/mlir/include/mlir/IR/Attributes.h b/mlir/include/mlir/IR/Attributes.h
index 6aac47dd53bf..e71359e0dacb 100644
--- a/mlir/include/mlir/IR/Attributes.h
+++ b/mlir/include/mlir/IR/Attributes.h
@@ -601,13 +601,13 @@ class ElementsAttr : public Attribute {
int64_t getNumElements() const;
/// Generates a new ElementsAttr by mapping each int value to a new
- /// underlying APInt. The new values can represent either a integer or float.
+ /// underlying APInt. The new values can represent either an integer or float.
/// This ElementsAttr should contain integers.
ElementsAttr mapValues(Type newElementType,
function_ref<APInt(const APInt &)> mapping) const;
/// Generates a new ElementsAttr by mapping each float value to a new
- /// underlying APInt. The new values can represent either a integer or float.
+ /// underlying APInt. The new values can represent either an integer or float.
/// This ElementsAttr should contain floats.
ElementsAttr mapValues(Type newElementType,
function_ref<APInt(const APFloat &)> mapping) const;
@@ -950,13 +950,13 @@ class DenseElementsAttr
DenseElementsAttr reshape(ShapedType newType);
/// Generates a new DenseElementsAttr by mapping each int value to a new
- /// underlying APInt. The new values can represent either a integer or float.
+ /// underlying APInt. The new values can represent either an integer or float.
/// This underlying type must be an DenseIntElementsAttr.
DenseElementsAttr mapValues(Type newElementType,
function_ref<APInt(const APInt &)> mapping) const;
/// Generates a new DenseElementsAttr by mapping each float value to a new
- /// underlying APInt. the new values can represent either a integer or float.
+ /// underlying APInt. the new values can represent either an integer or float.
/// This underlying type must be an DenseFPElementsAttr.
DenseElementsAttr
mapValues(Type newElementType,
diff --git a/mlir/include/mlir/IR/StandardTypes.h b/mlir/include/mlir/IR/StandardTypes.h
index b9774eb22de1..b36b348b89fe 100644
--- a/mlir/include/mlir/IR/StandardTypes.h
+++ b/mlir/include/mlir/IR/StandardTypes.h
@@ -128,7 +128,7 @@ class IntegerType
/// Return the signedness semantics of this integer type.
SignednessSemantics getSignedness() const;
- /// Return true if this is a singless integer type.
+ /// Return true if this is a signless integer type.
bool isSignless() const { return getSignedness() == Signless; }
/// Return true if this is a signed integer type.
bool isSigned() const { return getSignedness() == Signed; }
diff --git a/mlir/include/mlir/Pass/AnalysisManager.h b/mlir/include/mlir/Pass/AnalysisManager.h
index e9b8fc85a947..a50bee000b25 100644
--- a/mlir/include/mlir/Pass/AnalysisManager.h
+++ b/mlir/include/mlir/Pass/AnalysisManager.h
@@ -246,7 +246,7 @@ class AnalysisManager {
return impl->analyses.getCachedAnalysis<AnalysisT>();
}
- /// Query for a analysis of a child operation, constructing it if necessary.
+ /// Query for an analysis of a child operation, constructing it if necessary.
template <typename AnalysisT> AnalysisT &getChildAnalysis(Operation *op) {
return slice(op).template getAnalysis<AnalysisT>();
}
diff --git a/mlir/include/mlir/TableGen/Pattern.h b/mlir/include/mlir/TableGen/Pattern.h
index 79ca634a9215..0ed413368fa0 100644
--- a/mlir/include/mlir/TableGen/Pattern.h
+++ b/mlir/include/mlir/TableGen/Pattern.h
@@ -308,7 +308,7 @@ class SymbolInfoMap {
const_iterator find(StringRef key) const;
// Returns the number of static values of the given `symbol` corresponds to.
- // A static value is a operand/result declared in ODS. Normally a symbol only
+ // A static value is an operand/result declared in ODS. Normally a symbol only
// represents one static value, but symbols bound to op results can represent
// more than one if the op is a multi-result op.
int getStaticValueCount(StringRef symbol) const;
diff --git a/mlir/lib/Conversion/GPUToSPIRV/ConvertGPUToSPIRV.cpp b/mlir/lib/Conversion/GPUToSPIRV/ConvertGPUToSPIRV.cpp
index 5d380a2f3aa2..7636f207ab64 100644
--- a/mlir/lib/Conversion/GPUToSPIRV/ConvertGPUToSPIRV.cpp
+++ b/mlir/lib/Conversion/GPUToSPIRV/ConvertGPUToSPIRV.cpp
@@ -56,7 +56,7 @@ class TerminatorOpConversion final : public SPIRVOpLowering<loop::YieldOp> {
};
/// Pattern lowering GPU block/thread size/id to loading SPIR-V invocation
-/// builin variables.
+/// builtin variables.
template <typename SourceOp, spirv::BuiltIn builtin>
class LaunchConfigConversion : public SPIRVOpLowering<SourceOp> {
public:
diff --git a/mlir/lib/Conversion/LoopsToGPU/LoopsToGPU.cpp b/mlir/lib/Conversion/LoopsToGPU/LoopsToGPU.cpp
index 4b94833c0fea..b08cfb696953 100644
--- a/mlir/lib/Conversion/LoopsToGPU/LoopsToGPU.cpp
+++ b/mlir/lib/Conversion/LoopsToGPU/LoopsToGPU.cpp
@@ -742,7 +742,7 @@ static LogicalResult processParallelLoop(
/// the hardware id might iterate over additional indices. The transformation
/// caters for this by predicating the created sequence of instructions on
/// the actual loop bound. This only works if an static upper bound for the
-/// dynamic loop bound can be defived, currently via analyzing `affine.min`
+/// dynamic loop bound can be derived, currently via analyzing `affine.min`
/// operations.
LogicalResult
ParallelToGpuLaunchLowering::matchAndRewrite(ParallelOp parallelOp,
diff --git a/mlir/lib/Conversion/StandardToLLVM/StandardToLLVM.cpp b/mlir/lib/Conversion/StandardToLLVM/StandardToLLVM.cpp
index 12fc8b177c17..5e1e90a22c4f 100644
--- a/mlir/lib/Conversion/StandardToLLVM/StandardToLLVM.cpp
+++ b/mlir/lib/Conversion/StandardToLLVM/StandardToLLVM.cpp
@@ -1090,7 +1090,7 @@ void nDVectorIterate(const NDVectorTypeInfo &info, OpBuilder &builder,
}
////////////// End Support for Lowering operations on n-D vectors //////////////
-/// Replaces the given operaiton "op" with a new operation of type "targetOp"
+/// Replaces the given operation "op" with a new operation of type "targetOp"
/// and given operands.
LogicalResult LLVM::detail::oneToOneRewrite(
Operation *op, StringRef targetOp, ValueRange operands,
@@ -1698,7 +1698,7 @@ struct MemRefCastOpLowering : public ConvertOpToLLVMPattern<MemRefCastOp> {
auto loadOp = rewriter.create<LLVM::LoadOp>(loc, castPtr);
rewriter.replaceOp(op, loadOp.getResult());
} else {
- llvm_unreachable("Unsuppored unranked memref to unranked memref cast");
+ llvm_unreachable("Unsupported unranked memref to unranked memref cast");
}
}
};
@@ -2285,7 +2285,7 @@ struct SubViewOpLowering : public ConvertOpToLLVMPattern<SubViewOp> {
}
};
-/// Conversion pattern that transforms a op into:
+/// Conversion pattern that transforms an op into:
/// 1. An `llvm.mlir.undef` operation to create a memref descriptor
/// 2. Updates to the descriptor to introduce the data ptr, offset, size
/// and stride.
diff --git a/mlir/lib/Conversion/StandardToSPIRV/ConvertStandardToSPIRV.cpp b/mlir/lib/Conversion/StandardToSPIRV/ConvertStandardToSPIRV.cpp
index ea8812cebdc4..b53128a33018 100644
--- a/mlir/lib/Conversion/StandardToSPIRV/ConvertStandardToSPIRV.cpp
+++ b/mlir/lib/Conversion/StandardToSPIRV/ConvertStandardToSPIRV.cpp
@@ -37,8 +37,8 @@ static bool isBoolScalarOrVector(Type type) {
return false;
}
-/// Converts the given `srcAttr` into a boolean attribute if it holds a integral
-/// value. Returns null attribute if conversion fails.
+/// Converts the given `srcAttr` into a boolean attribute if it holds an
+/// integral value. Returns null attribute if conversion fails.
static BoolAttr convertBoolAttr(Attribute srcAttr, Builder builder) {
if (auto boolAttr = srcAttr.dyn_cast<BoolAttr>())
return boolAttr;
diff --git a/mlir/lib/Dialect/GPU/IR/GPUDialect.cpp b/mlir/lib/Dialect/GPU/IR/GPUDialect.cpp
index e484e25b348d..e2434e380a9c 100644
--- a/mlir/lib/Dialect/GPU/IR/GPUDialect.cpp
+++ b/mlir/lib/Dialect/GPU/IR/GPUDialect.cpp
@@ -90,7 +90,7 @@ LogicalResult GPUDialect::verifyOperationAttribute(Operation *op,
// TODO(ntv,zinenko,herhut): if the kernel function has been converted to
// the LLVM dialect but the caller hasn't (which happens during the
- // separate compilation), do not check type correspondance as it would
+ // separate compilation), do not check type correspondence as it would
// require the verifier to be aware of the LLVM type conversion.
if (kernelLLVMFunction)
return success();
diff --git a/mlir/lib/Dialect/GPU/Transforms/AllReduceLowering.cpp b/mlir/lib/Dialect/GPU/Transforms/AllReduceLowering.cpp
index d12611f33b9c..57c497f613cb 100644
--- a/mlir/lib/Dialect/GPU/Transforms/AllReduceLowering.cpp
+++ b/mlir/lib/Dialect/GPU/Transforms/AllReduceLowering.cpp
@@ -241,7 +241,7 @@ struct GpuAllReduceRewriter {
};
}
- /// Returns an accumulator for comparaison such as min, max. T is the type
+ /// Returns an accumulator for comparison such as min, max. T is the type
/// of the compare op.
template <typename T, typename PredicateEnum, PredicateEnum predicate>
AccumulatorFactory getCmpFactory() const {
diff --git a/mlir/lib/Dialect/GPU/Transforms/KernelOutlining.cpp b/mlir/lib/Dialect/GPU/Transforms/KernelOutlining.cpp
index d20f23de78ec..2eadf87f038a 100644
--- a/mlir/lib/Dialect/GPU/Transforms/KernelOutlining.cpp
+++ b/mlir/lib/Dialect/GPU/Transforms/KernelOutlining.cpp
@@ -162,8 +162,8 @@ static gpu::GPUFuncOp outlineKernelFuncImpl(gpu::LaunchOp launchOp,
// cleaner.
launchOpBody.cloneInto(&outlinedFuncBody, map);
- // Branch from enty of the gpu.func operation to the block that is cloned from
- // the entry block of the gpu.launch operation.
+ // Branch from entry of the gpu.func operation to the block that is cloned
+ // from the entry block of the gpu.launch operation.
Block &launchOpEntry = launchOpBody.front();
Block *clonedLaunchOpEntry = map.lookup(&launchOpEntry);
builder.setInsertionPointToEnd(&entryBlock);
diff --git a/mlir/lib/Dialect/LoopOps/Transforms/ParallelLoopSpecialization.cpp b/mlir/lib/Dialect/LoopOps/Transforms/ParallelLoopSpecialization.cpp
index 471d5e53e7d0..63afa5059509 100644
--- a/mlir/lib/Dialect/LoopOps/Transforms/ParallelLoopSpecialization.cpp
+++ b/mlir/lib/Dialect/LoopOps/Transforms/ParallelLoopSpecialization.cpp
@@ -1,4 +1,4 @@
-//===- ParallelLoopSpecialization.cpp - loop.parallel specializeation -----===//
+//===- ParallelLoopSpecialization.cpp - loop.parallel specialization ------===//
//
// 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/Dialect/SPIRV/SPIRVOps.cpp b/mlir/lib/Dialect/SPIRV/SPIRVOps.cpp
index 841b5e0ace64..f0a7c2af6d2d 100644
--- a/mlir/lib/Dialect/SPIRV/SPIRVOps.cpp
+++ b/mlir/lib/Dialect/SPIRV/SPIRVOps.cpp
@@ -2533,7 +2533,7 @@ static LogicalResult verify(spirv::UnreachableOp unreachableOp) {
if (block->hasNoPredecessors())
return success();
- // TODO(antiagainst): further verification needs to analyze reachablility from
+ // TODO(antiagainst): further verification needs to analyze reachability from
// the entry block.
return success();
diff --git a/mlir/lib/Dialect/Vector/VectorOps.cpp b/mlir/lib/Dialect/Vector/VectorOps.cpp
index 19aa52f8a461..53eee4a6bc62 100644
--- a/mlir/lib/Dialect/Vector/VectorOps.cpp
+++ b/mlir/lib/Dialect/Vector/VectorOps.cpp
@@ -1013,7 +1013,7 @@ static LogicalResult verify(ReshapeOp op) {
return op.emitError("invalid output shape for vector type ")
<< outputVectorType;
- // Verify that the 'fixedVectorSizes' match a input/output vector shape
+ // Verify that the 'fixedVectorSizes' match an input/output vector shape
// suffix.
unsigned inputVectorRank = inputVectorType.getRank();
for (unsigned i = 0; i < numFixedVectorSizes; ++i) {
diff --git a/mlir/lib/IR/AttributeDetail.h b/mlir/lib/IR/AttributeDetail.h
index d8da9ddc88dc..8908416b3efa 100644
--- a/mlir/lib/IR/AttributeDetail.h
+++ b/mlir/lib/IR/AttributeDetail.h
@@ -196,7 +196,7 @@ struct FloatAttributeStorage final
size_t numObjects;
};
-/// An attribute representing a integral value.
+/// An attribute representing an integral value.
struct IntegerAttributeStorage final
: public AttributeStorage,
public llvm::TrailingObjects<IntegerAttributeStorage, uint64_t> {
diff --git a/mlir/lib/IR/Operation.cpp b/mlir/lib/IR/Operation.cpp
index b94ee96f8ffa..c6f25b2ff4a0 100644
--- a/mlir/lib/IR/Operation.cpp
+++ b/mlir/lib/IR/Operation.cpp
@@ -407,24 +407,24 @@ Block *llvm::ilist_traits<::mlir::Operation>::getContainingBlock() {
return reinterpret_cast<Block *>(reinterpret_cast<char *>(Anchor) - Offset);
}
-/// This is a trait method invoked when a operation is added to a block. We
+/// This is a trait method invoked when an operation is added to a block. We
/// keep the block pointer up to date.
void llvm::ilist_traits<::mlir::Operation>::addNodeToList(Operation *op) {
- assert(!op->getBlock() && "already in a operation block!");
+ assert(!op->getBlock() && "already in an operation block!");
op->block = getContainingBlock();
// Invalidate the order on the operation.
op->orderIndex = Operation::kInvalidOrderIdx;
}
-/// This is a trait method invoked when a operation is removed from a block.
+/// This is a trait method invoked when an operation is removed from a block.
/// We keep the block pointer up to date.
void llvm::ilist_traits<::mlir::Operation>::removeNodeFromList(Operation *op) {
- assert(op->block && "not already in a operation block!");
+ assert(op->block && "not already in an operation block!");
op->block = nullptr;
}
-/// This is a trait method invoked when a operation is moved from one block
+/// This is a trait method invoked when an operation is moved from one block
/// to another. We keep the block pointer up to date.
void llvm::ilist_traits<::mlir::Operation>::transferNodesFromList(
ilist_traits<Operation> &otherList, op_iterator first, op_iterator last) {
diff --git a/mlir/lib/IR/SymbolTable.cpp b/mlir/lib/IR/SymbolTable.cpp
index db205f8a1e67..ba1c8c375920 100644
--- a/mlir/lib/IR/SymbolTable.cpp
+++ b/mlir/lib/IR/SymbolTable.cpp
@@ -441,7 +441,7 @@ static Optional<WalkResult> walkSymbolUses(
return WalkResult::advance();
}
/// Walk all of the uses, for any symbol, that are nested within the given
-/// operaion 'from', invoking the provided callback for each. This does not
+/// operation 'from', invoking the provided callback for each. This does not
/// traverse into any nested symbol tables.
static Optional<WalkResult> walkSymbolUses(
Operation *from,
diff --git a/mlir/lib/Pass/PassTiming.cpp b/mlir/lib/Pass/PassTiming.cpp
index f86a4a51b4cb..768c68620ab9 100644
--- a/mlir/lib/Pass/PassTiming.cpp
+++ b/mlir/lib/Pass/PassTiming.cpp
@@ -243,7 +243,7 @@ struct PassTiming : public PassInstrumentation {
void PassTiming::runBeforePipeline(const OperationName &name,
const PipelineParentInfo &parentInfo) {
- // We don't actually want to time the piplelines, they gather their total
+ // We don't actually want to time the pipelines, they gather their total
// from their held passes.
getTimer(name.getAsOpaquePointer(), TimerKind::Pipeline,
[&] { return ("'" + name.getStringRef() + "' Pipeline").str(); });
diff --git a/mlir/lib/Transforms/Utils/LoopUtils.cpp b/mlir/lib/Transforms/Utils/LoopUtils.cpp
index 42649ae336c0..f07d0bb29331 100644
--- a/mlir/lib/Transforms/Utils/LoopUtils.cpp
+++ b/mlir/lib/Transforms/Utils/LoopUtils.cpp
@@ -2123,7 +2123,7 @@ void mlir::gatherLoops(FuncOp func,
// TODO: if necessary, this can be extended to also compose in any
// affine.applys, fold to constant if all result dimensions of the map are
// constant (canonicalizeMapAndOperands below already does this for single
-// result bound maps), and use simplifyMap to perform algebraic simplication.
+// result bound maps), and use simplifyMap to perform algebraic simplification.
AffineForOp mlir::createCanonicalizedAffineForOp(
OpBuilder b, Location loc, ValueRange lbOperands, AffineMap lbMap,
ValueRange ubOperands, AffineMap ubMap, int64_t step) {
diff --git a/mlir/test/Conversion/AffineToStandard/lower-affine.mlir b/mlir/test/Conversion/AffineToStandard/lower-affine.mlir
index 18ef4e201c8d..faac1cbf153a 100644
--- a/mlir/test/Conversion/AffineToStandard/lower-affine.mlir
+++ b/mlir/test/Conversion/AffineToStandard/lower-affine.mlir
@@ -347,7 +347,7 @@ func @loop_min_max(%N : index) {
#map_7_values = affine_map<(d0, d1, d2, d3, d4, d5, d6) -> (d0, d1, d2, d3, d4, d5, d6)>
// Check that the "min" (cmpi "slt" + select) reduction sequence is emitted
-// correctly for a an affine map with 7 results.
+// correctly for an affine map with 7 results.
// CHECK-LABEL: func @min_reduction_tree
// CHECK-NEXT: %[[c0:.*]] = constant 0 : index
diff --git a/mlir/test/Dialect/SPIRV/types.mlir b/mlir/test/Dialect/SPIRV/types.mlir
index 266790d4d954..3c11d3b88a02 100644
--- a/mlir/test/Dialect/SPIRV/types.mlir
+++ b/mlir/test/Dialect/SPIRV/types.mlir
@@ -78,7 +78,7 @@ func @llvm_type(!spv.array<4x!llvm.i32>) -> ()
// -----
// expected-error @+1 {{ArrayStride must be greater than zero}}
-func @array_type_zero_stide(!spv.array<4xi32 [0]>) -> ()
+func @array_type_zero_stride(!spv.array<4xi32 [0]>) -> ()
// -----
diff --git a/mlir/test/lib/Dialect/Test/TestPatterns.cpp b/mlir/test/lib/Dialect/Test/TestPatterns.cpp
index 23d650e15479..e6cc52d29722 100644
--- a/mlir/test/lib/Dialect/Test/TestPatterns.cpp
+++ b/mlir/test/lib/Dialect/Test/TestPatterns.cpp
@@ -499,7 +499,7 @@ static llvm::cl::opt<TestLegalizePatternDriver::ConversionMode>
//===----------------------------------------------------------------------===//
// ConversionPatternRewriter::getRemappedValue testing. This method is used
-// to get the remapped value of a original value that was replaced using
+// to get the remapped value of an original value that was replaced using
// ConversionPatternRewriter.
namespace {
/// Converter that replaces a one-result one-operand OneVResOneVOperandOp1 with
diff --git a/mlir/test/mlir-tblgen/op-format-spec.td b/mlir/test/mlir-tblgen/op-format-spec.td
index 5c3e344f68d7..4e20b5ef4cf8 100644
--- a/mlir/test/mlir-tblgen/op-format-spec.td
+++ b/mlir/test/mlir-tblgen/op-format-spec.td
@@ -243,7 +243,7 @@ def OptionalInvalidK : TestFormat_Op<"optional_invalid_k", [{
// Variables
//===----------------------------------------------------------------------===//
-// CHECK: error: expected variable to refer to a argument, result, or successor
+// CHECK: error: expected variable to refer to an argument, result, or successor
def VariableInvalidA : TestFormat_Op<"variable_invalid_a", [{
$unknown_arg attr-dict
}]>;
diff --git a/mlir/tools/mlir-tblgen/OpFormatGen.cpp b/mlir/tools/mlir-tblgen/OpFormatGen.cpp
index 965a6961b16e..fdf8f0265509 100644
--- a/mlir/tools/mlir-tblgen/OpFormatGen.cpp
+++ b/mlir/tools/mlir-tblgen/OpFormatGen.cpp
@@ -931,7 +931,7 @@ static void genElementPrinter(Element *element, OpMethodBody &body,
if (auto *attr = dyn_cast<AttributeVariable>(element)) {
const NamedAttribute *var = attr->getVar();
- // If we are formatting as a enum, symbolize the attribute as a string.
+ // If we are formatting as an enum, symbolize the attribute as a string.
if (canFormatEnumAttr(var)) {
const EnumAttr &enumAttr = cast<EnumAttr>(var->attr);
body << " p << \"\\\"\" << " << enumAttr.getSymbolToStringFnName() << "("
@@ -1656,7 +1656,7 @@ LogicalResult FormatParser::parseVariable(std::unique_ptr<Element> &element,
return success();
}
return emitError(
- loc, "expected variable to refer to a argument, result, or successor");
+ loc, "expected variable to refer to an argument, result, or successor");
}
LogicalResult FormatParser::parseDirective(std::unique_ptr<Element> &element,
diff --git a/mlir/tools/mlir-tblgen/RewriterGen.cpp b/mlir/tools/mlir-tblgen/RewriterGen.cpp
index a42c7390bb75..0cac412fecef 100644
--- a/mlir/tools/mlir-tblgen/RewriterGen.cpp
+++ b/mlir/tools/mlir-tblgen/RewriterGen.cpp
@@ -127,7 +127,7 @@ class PatternEmitter {
void createSeparateLocalVarsForOpArgs(DagNode node,
ChildNodeIndexNameMap &childNodeNames);
- // Emits the concrete arguments used to call a op's builder.
+ // Emits the concrete arguments used to call an op's builder.
void supplyValuesForOpArgs(DagNode node,
const ChildNodeIndexNameMap &childNodeNames);
diff --git a/mlir/tools/mlir-vulkan-runner/VulkanRuntime.cpp b/mlir/tools/mlir-vulkan-runner/VulkanRuntime.cpp
index 77b12b1d9c5f..97591f65272d 100644
--- a/mlir/tools/mlir-vulkan-runner/VulkanRuntime.cpp
+++ b/mlir/tools/mlir-vulkan-runner/VulkanRuntime.cpp
@@ -363,7 +363,7 @@ LogicalResult VulkanRuntime::createMemoryBuffers() {
resourceStorageClassData.find(descriptorSetIndex);
if (resourceStorageClassMapIt == resourceStorageClassData.end()) {
llvm::errs()
- << "cannot find storge class for resource in descriptor set: "
+ << "cannot find storage class for resource in descriptor set: "
<< descriptorSetIndex;
return failure();
}
diff --git a/mlir/tools/mlir-vulkan-runner/VulkanRuntime.h b/mlir/tools/mlir-vulkan-runner/VulkanRuntime.h
index 270665160447..f7838cc1e1ca 100644
--- a/mlir/tools/mlir-vulkan-runner/VulkanRuntime.h
+++ b/mlir/tools/mlir-vulkan-runner/VulkanRuntime.h
@@ -91,7 +91,7 @@ inline void emitVulkanError(const llvm::Twine &message, VkResult error) {
/// SPIR-V shader, number of work groups and entry point. After the creation of
/// VulkanRuntime, special methods must be called in the following
/// sequence: initRuntime(), run(), updateHostMemoryBuffers(), destroy();
-/// each method in the sequence returns succes or failure depends on the Vulkan
+/// each method in the sequence returns success or failure depends on the Vulkan
/// result code.
class VulkanRuntime {
public:
diff --git a/mlir/utils/spirv/gen_spirv_dialect.py b/mlir/utils/spirv/gen_spirv_dialect.py
index 2c735907063a..ce7cda4fe3cf 100755
--- a/mlir/utils/spirv/gen_spirv_dialect.py
+++ b/mlir/utils/spirv/gen_spirv_dialect.py
@@ -528,7 +528,7 @@ def snake_casify(name):
def map_spec_operand_to_ods_argument(operand):
- """Maps a operand in SPIR-V JSON spec to an op argument in ODS.
+ """Maps an operand in SPIR-V JSON spec to an op argument in ODS.
Arguments:
- A dict containing the operand's kind, quantifier, and name
@@ -842,7 +842,7 @@ def update_td_op_definitions(path, instructions, docs, filter_list,
with open(path, 'r') as f:
content = f.read()
- # Split the file into chuncks, each containing one op.
+ # Split the file into chunks, each containing one op.
ops = content.split(AUTOGEN_OP_DEF_SEPARATOR)
header = ops[0]
footer = ops[-1]
More information about the Mlir-commits
mailing list