diff --git a/test/Conversion/amd/amd-convert-builtin-func.mlir b/test/Conversion/amd/amd-convert-builtin-func.mlir deleted file mode 100644 index 85aff4f62d5e..000000000000 --- a/test/Conversion/amd/amd-convert-builtin-func.mlir +++ /dev/null @@ -1,27 +0,0 @@ -// RUN: triton-opt --convert-builtin-func-to-llvm %s | FileCheck %s - -// Trying to merge those blocks will cause a lot of duplication in the block arguments, which will cause -// an exponential growth of the argument length. Make sure we don't try to merge those blocks. -// CHECK-COUNT-7: ^bb{{[0-9]+}}: -module { - llvm.func @rand() -> i1 - llvm.func @"__predicated_store_!llvm.void_!llvm.ptr<1>_i32_i1_"(!llvm.ptr<1>, i32, i1) attributes {libname = "", libpath = ""} - - llvm.func @top(%arg0: i64, %1 : !llvm.ptr<1>, %2 : !llvm.ptr<1>, %3 : !llvm.ptr<1>, %4 : !llvm.ptr<1>) { - %0 = llvm.mlir.constant(0 : i64) : i64 - %10 = llvm.icmp "eq" %arg0, %0 : i64 - %true = llvm.mlir.constant(1 : i1) : i1 - %c = llvm.mlir.constant(1 : i32) : i32 - llvm.cond_br %10, ^bb1, ^bb2 - ^bb1: // pred: ^bb0 - llvm.call @"__predicated_store_!llvm.void_!llvm.ptr<1>_i32_i1_"(%1, %c, %true) : (!llvm.ptr<1>, i32, i1) -> () - llvm.br ^bb3 - - ^bb2: // pred: ^bb0 - llvm.call @"__predicated_store_!llvm.void_!llvm.ptr<1>_i32_i1_"(%4, %c, %true) : (!llvm.ptr<1>, i32, i1) -> () - llvm.br ^bb3 - - ^bb3: // 2 preds: ^bb1, ^bb2 - llvm.return - } -} diff --git a/third_party/amd/lib/TritonAMDGPUToLLVM/BuiltinFuncToLLVM.cpp b/third_party/amd/lib/TritonAMDGPUToLLVM/BuiltinFuncToLLVM.cpp index 1788f0780cec..62a1c502145a 100644 --- a/third_party/amd/lib/TritonAMDGPUToLLVM/BuiltinFuncToLLVM.cpp +++ b/third_party/amd/lib/TritonAMDGPUToLLVM/BuiltinFuncToLLVM.cpp @@ -206,11 +206,8 @@ struct ConvertBuiltinFuncToLLVM MLIRContext *context = &getContext(); ModuleOp mod = getOperation(); - // Disable block merging because of: - // https://github.com/llvm/llvm-project/issues/63230 - // TODO(giuseros): enable block merging once the above ticket is completed GreedyRewriteConfig config; - config.enableRegionSimplification = GreedySimplifyRegionLevel::Normal; + config.enableRegionSimplification = GreedySimplifyRegionLevel::Aggressive; RewritePatternSet patterns(context); patterns.add(context);