[clang] [CIR] Add support for indirect calls (PR #139748)

Bruno Cardoso Lopes via cfe-commits cfe-commits at lists.llvm.org
Tue May 13 11:22:50 PDT 2025


================
@@ -1500,6 +1507,14 @@ static void prepareTypeConverter(mlir::LLVMTypeConverter &converter,
   converter.addConversion([&](cir::BF16Type type) -> mlir::Type {
     return mlir::BFloat16Type::get(type.getContext());
   });
+  converter.addConversion([&](cir::FuncType type) -> mlir::Type {
+    auto result = converter.convertType(type.getReturnType());
+    llvm::SmallVector<mlir::Type> arguments;
----------------
bcardosolopes wrote:

Please use the `type.getInputs()` length to reserve the capacity for `arguments`.

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


More information about the cfe-commits mailing list