mirror of
https://github.com/capstone-engine/llvm-capstone.git
synced 2025-04-01 12:43:47 +00:00
[mlir][NFC] Cleanup Passes documentation
- Fix a place of NVGPU dialect's pass - Move a summary of `-finalize-memref-to-llvm` into description - Fix broken links - Replace back-quote dialect headers with single-quote headers for improved readability. Reviewed By: rriddle Differential Revision: https://reviews.llvm.org/D142868
This commit is contained in:
parent
115711c19c
commit
b46e78c7cb
@ -16,39 +16,43 @@ This document describes the available MLIR passes and their contracts.
|
||||
|
||||
[include "ConversionPasses.md"]
|
||||
|
||||
## `async` Dialect Passes
|
||||
## 'async' Dialect Passes
|
||||
|
||||
[include "AsyncPasses.md"]
|
||||
|
||||
## `affine` Dialect Passes
|
||||
## 'affine' Dialect Passes
|
||||
|
||||
[include "AffinePasses.md"]
|
||||
|
||||
## `arith` Dialect Passes
|
||||
## 'arith' Dialect Passes
|
||||
|
||||
[include "ArithPasses.md"]
|
||||
|
||||
## `func` Dialect Passes
|
||||
## 'func' Dialect Passes
|
||||
|
||||
[include "FuncPasses.md"]
|
||||
|
||||
## `gpu` Dialect Passes
|
||||
## 'gpu' Dialect Passes
|
||||
|
||||
[include "GPUPasses.md"]
|
||||
|
||||
## `linalg` Dialect Passes
|
||||
## 'linalg' Dialect Passes
|
||||
|
||||
[include "LinalgPasses.md"]
|
||||
|
||||
## `llvm` Dialect Passes
|
||||
## 'llvm' Dialect Passes
|
||||
|
||||
[include "LLVMPasses.md"]
|
||||
|
||||
## `memref` Dialect Passes
|
||||
## 'memref' Dialect Passes
|
||||
|
||||
[include "MemRefPasses.md"]
|
||||
|
||||
## `quant` Dialect Passes
|
||||
## 'nvgpu' Dialect Passes
|
||||
|
||||
[include "NVGPUPasses.md"]
|
||||
|
||||
## 'quant' Dialect Passes
|
||||
|
||||
[include "QuantPasses.md"]
|
||||
|
||||
@ -56,31 +60,31 @@ This document describes the available MLIR passes and their contracts.
|
||||
|
||||
[include "ReducerPasses.md"]
|
||||
|
||||
## `scf` Dialect Passes
|
||||
## 'scf' Dialect Passes
|
||||
|
||||
[include "SCFPasses.md"]
|
||||
|
||||
## `shape` Dialect Passes
|
||||
## 'shape' Dialect Passes
|
||||
|
||||
[include "ShapePasses.md"]
|
||||
|
||||
## `sparse_tensor` Dialect Passes
|
||||
## 'sparse_tensor' Dialect Passes
|
||||
|
||||
[include "SparseTensorPasses.md"]
|
||||
|
||||
## `spv` Dialect Passes
|
||||
## 'spv' Dialect Passes
|
||||
|
||||
[include "SPIRVPasses.md"]
|
||||
|
||||
## `tensor` Dialect Passes
|
||||
## 'tensor' Dialect Passes
|
||||
|
||||
[include "TensorPasses.md"]
|
||||
|
||||
## `transform` Dialect Passes
|
||||
## 'transform' Dialect Passes
|
||||
|
||||
[include "TransformPasses.md"]
|
||||
|
||||
## `vector` Dialect Passes
|
||||
## 'vector' Dialect Passes
|
||||
|
||||
[include "VectorPasses.md"]
|
||||
|
||||
|
@ -636,11 +636,14 @@ def ConvertMathToFuncs : Pass<"convert-math-to-funcs", "ModuleOp"> {
|
||||
|
||||
def FinalizeMemRefToLLVMConversionPass :
|
||||
Pass<"finalize-memref-to-llvm", "ModuleOp"> {
|
||||
let summary = "Finalize the conversion of the operations from the MemRef "
|
||||
"dialect to the LLVM dialect."
|
||||
"This conversion will not convert some complex MemRef "
|
||||
"operations. Make sure to run `expand-strided-metadata` "
|
||||
"beforehand for these.";
|
||||
let summary = "Finalize MemRef dialect to LLVM dialect conversion";
|
||||
let description = [{
|
||||
Finalize the conversion of the operations from the MemRef
|
||||
dialect to the LLVM dialect.
|
||||
This conversion will not convert some complex MemRef
|
||||
operations. Make sure to run `expand-strided-metadata`
|
||||
beforehand for these.
|
||||
}];
|
||||
let dependentDialects = ["LLVM::LLVMDialect"];
|
||||
let options = [
|
||||
Option<"useAlignedAlloc", "use-aligned-alloc", "bool", /*default=*/"false",
|
||||
|
@ -48,18 +48,17 @@ def NormalizeMemRefs : Pass<"normalize-memrefs", "ModuleOp"> {
|
||||
let summary = "Normalize memrefs";
|
||||
let description = [{
|
||||
This pass transforms memref types with a non-trivial
|
||||
[layout map](https://mlir.llvm.org/docs/LangRef/#layout-map) into
|
||||
memref types with an identity layout map, e.g. (i, j) -> (i, j). This
|
||||
[layout map](https://mlir.llvm.org/docs/Dialects/Builtin/#affine-map-layout)
|
||||
into memref types with an identity layout map, e.g. (i, j) -> (i, j). This
|
||||
pass is inter-procedural, in the sense that it can modify function
|
||||
interfaces and call sites that pass memref types. In order to modify
|
||||
memref types while preserving the original behavior, users of those
|
||||
memref types are also modified to incorporate the resulting layout map.
|
||||
For instance, an [AffineLoadOp]
|
||||
(https://mlir.llvm.org/docs/Dialects/Affine/#affineload-affineloadop)
|
||||
For instance, an [AffineLoadOp](https://mlir.llvm.org/docs/Dialects/Affine/#affineload-mliraffineloadop)
|
||||
will be updated to compose the layout map with with the affine expression
|
||||
contained in the op. Operations marked with the [MemRefsNormalizable]
|
||||
(https://mlir.llvm.org/docs/Traits/#memrefsnormalizable) trait are
|
||||
expected to be normalizable. Supported operations include affine
|
||||
contained in the op. Operations marked with the
|
||||
[MemRefsNormalizable](https://mlir.llvm.org/docs/Traits/#memrefsnormalizable)
|
||||
trait are expected to be normalizable. Supported operations include affine
|
||||
operations, memref.alloc, memref.dealloc, and func.return.
|
||||
|
||||
Given an appropriate layout map specified in the code, this transformation
|
||||
|
@ -133,7 +133,7 @@ def LocationSnapshot : Pass<"snapshot-op-locations"> {
|
||||
```
|
||||
|
||||
* If set, the new location is fused with the original location in the form
|
||||
of a [`Name Location`](Diagnostics.md#name-location) with the specified tag.
|
||||
of a [`Name Location`](Dialects/Builtin.md/#nameloc) with the specified tag.
|
||||
|
||||
Example:
|
||||
|
||||
@ -187,7 +187,7 @@ def StripDebugInfo : Pass<"strip-debuginfo"> {
|
||||
let summary = "Strip debug info from all operations";
|
||||
let description = [{
|
||||
This pass strips the IR of any location information, by replacing all
|
||||
operation locations with [`unknown`](Diagnostics.md#unknown-location).
|
||||
operation locations with [`unknown`](Dialects/Builtin.md/#unknownloc).
|
||||
}];
|
||||
let constructor = "mlir::createStripDebugInfoPass()";
|
||||
}
|
||||
@ -199,7 +199,7 @@ def SymbolDCE : Pass<"symbol-dce"> {
|
||||
by computing the set of operations that are known to be live, propagating
|
||||
that liveness to other symbols, and then deleting all symbols that are not
|
||||
within this live set. Live symbols are those that have a
|
||||
[visibility](SymbolsAndSymbolTables.md#symbol-visibility) that extends
|
||||
[visibility](SymbolsAndSymbolTables.md/#symbol-visibility) that extends
|
||||
beyond the IR, e.g. `public`, or those that are referenced by live symbols
|
||||
or other non-Symbol operations.
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user