Skip to content

Commit

Permalink
[BACKEND] Add arith::CeilFloorDivExpandOpsPatterns (#5934)
Browse files Browse the repository at this point in the history
Unfortunately `CeilFloorDivExpandOpsPatterns` is not included in
`mlir::arith::populateArithToLLVMConversionPatterns` but still included
in `populateConvertToLLVMConversionPatterns`.


https://github.com/llvm/llvm-project/blob/main/mlir/lib/Conversion/ArithToLLVM/ArithToLLVM.cpp#L544
  • Loading branch information
Jokeren authored Feb 16, 2025
1 parent 0f8533a commit 66ae17f
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
#include "mlir/Conversion/GPUToNVVM/GPUToNVVMPass.h"
#include "mlir/Conversion/MathToLLVM/MathToLLVM.h"
#include "mlir/Conversion/UBToLLVM/UBToLLVM.h"
#include "mlir/Dialect/Arith/Transforms/Passes.h"
#include "mlir/Dialect/LLVMIR/LLVMDialect.h"
#include "mlir/Dialect/LLVMIR/NVVMDialect.h"
#include "mlir/Pass/Pass.h"
Expand Down Expand Up @@ -141,6 +142,7 @@ struct ConvertTritonGPUToLLVM
// TODO(thomas): this should probably be done in a separate step to not
// interfere with our own lowering of arith ops. Add arith/math's patterns
// to help convert scalar expression to LLVM.
mlir::arith::populateCeilFloorDivExpandOpsPatterns(patterns);
mlir::arith::populateArithToLLVMConversionPatterns(typeConverter, patterns);
mlir::populateMathToLLVMConversionPatterns(typeConverter, patterns);
mlir::populateGpuToNVVMConversionPatterns(typeConverter, patterns);
Expand Down

0 comments on commit 66ae17f

Please sign in to comment.