[Mlir-commits] [mlir] [mlir][GPUToNVVM] enable fallback to generic LLVM lowering for math dialect in convert-gpu-to-nvvm pass (PR #165728)
Fabian Mora
llvmlistbot at llvm.org
Thu Oct 30 09:03:41 PDT 2025
================
@@ -0,0 +1,29 @@
+// RUN: mlir-opt %s -convert-gpu-to-nvvm -split-input-file | FileCheck %s
+
+/// Math/arith ops that are not supported by libdevice
+/// should be converted by generic LLVM lowering patterns.
+
+gpu.module @generic_llvm_test_module_0 {
+ // CHECK-LABEL: @arith_add
+ func.func @arith_add(%left: i64, %right: i64) -> i64 {
+ // CHECK: llvm.add {{.*}}, {{.*}} : i64
+ %result = arith.addi %left, %right : i64
+ return %result : i64
+ }
----------------
fabianmcg wrote:
Better to remove, as it's unrelated to the change.
https://github.com/llvm/llvm-project/pull/165728
More information about the Mlir-commits
mailing list