diff options
author | Matthias Springer <me@m-sp.org> | 2023-08-14 08:40:13 +0200 |
---|---|---|
committer | Matthias Springer <me@m-sp.org> | 2023-08-14 09:03:11 +0200 |
commit | ce254598b73b119c9463f5b7f4131559e276e844 (patch) | |
tree | 6e85c0724ca9da8098352426cae14fe51c8f538c /mlir/lib/Conversion/GPUCommon/GPUOpsLowering.cpp | |
parent | ce16c3cf30f5e63a395927ede95161393383d636 (diff) | |
download | llvm-ce254598b73b119c9463f5b7f4131559e276e844.zip llvm-ce254598b73b119c9463f5b7f4131559e276e844.tar.gz llvm-ce254598b73b119c9463f5b7f4131559e276e844.tar.bz2 |
[mlir][Conversion] Store const type converter in ConversionPattern
ConversionPatterns do not (and should not) modify the type converter that they are using.
* Make `ConversionPattern::typeConverter` const.
* Make member functions of the `LLVMTypeConverter` const.
* Conversion patterns take a const type converter.
* Various helper functions (that are called from patterns) now also take a const type converter.
Differential Revision: https://reviews.llvm.org/D157601
Diffstat (limited to 'mlir/lib/Conversion/GPUCommon/GPUOpsLowering.cpp')
-rw-r--r-- | mlir/lib/Conversion/GPUCommon/GPUOpsLowering.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/mlir/lib/Conversion/GPUCommon/GPUOpsLowering.cpp b/mlir/lib/Conversion/GPUCommon/GPUOpsLowering.cpp index f7caf02..2a26587 100644 --- a/mlir/lib/Conversion/GPUCommon/GPUOpsLowering.cpp +++ b/mlir/lib/Conversion/GPUCommon/GPUOpsLowering.cpp @@ -464,7 +464,7 @@ LogicalResult GPUPrintfOpToVPrintfLowering::matchAndRewrite( /// Unrolls op if it's operating on vectors. LogicalResult impl::scalarizeVectorOp(Operation *op, ValueRange operands, ConversionPatternRewriter &rewriter, - LLVMTypeConverter &converter) { + const LLVMTypeConverter &converter) { TypeRange operandTypes(operands); if (llvm::none_of(operandTypes, [](Type type) { return isa<VectorType>(type); })) { |