[Mlir-commits] [mlir] [MLIR][LLVM] Add vararg support in LLVM::LLVMFuncOp (PR #67274)

Christian Ulmann llvmlistbot at llvm.org
Tue Sep 26 00:07:22 PDT 2023


================
@@ -211,9 +211,15 @@ convertOperationImpl(Operation &opInst, llvm::IRBuilderBase &builder,
       call = builder.CreateCall(
           moduleTranslation.lookupFunction(attr.getValue()), operandsRef);
     } else {
-      call = builder.CreateCall(getCalleeFunctionType(callOp.getResultTypes(),
-                                                      callOp.getArgOperands()),
-                                operandsRef.front(), operandsRef.drop_front());
+      llvm::FunctionType *calleeType;
+      if (callOp.getCalleeType().has_value())
----------------
Dinistro wrote:

NIT: `has_value()` is not necessary
```suggestion
      if (callOp.getCalleeType())
```

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


More information about the Mlir-commits mailing list