[llvm] [mlir] [MLIR][LLVM][Intrinsics] Add new MLIR and LLVM APIs to automatically resolve overload types (PR #168188)

Rajat Bajpai via llvm-commits llvm-commits at lists.llvm.org
Tue Nov 18 05:10:34 PST 2025


================
@@ -3176,12 +3176,7 @@ def NVVM_PrefetchOp : NVVM_Op<"prefetch",
   let llvmBuilder = [{
     auto [id, args] = NVVM::PrefetchOp::getIntrinsicIDAndArgs(op,
                                           moduleTranslation, builder);
-
-    if(op.getTensormap())
-      // Overloaded intrinsic
-      createIntrinsicCall(builder, id, args, {args[0]->getType()});
-    else
-      createIntrinsicCall(builder, id, args);
+    createIntrinsicCall(builder, id, builder.getVoidTy(), args);
----------------
rajatbajpai wrote:

We could also use this API for WMMA, stmatrix, and other cases, but in this commit I kept a single use case as motivation. I do not want to merge this refactoring with the current change.

https://github.com/llvm/llvm-project/pull/168188


More information about the llvm-commits mailing list