[all-commits] [llvm/llvm-project] 610139: [mlir] replace 'emit_c_wrappers' func->llvm conver...
ftynse via All-commits
all-commits at lists.llvm.org
Fri Jun 17 02:10:47 PDT 2022
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 610139d2d9ce6746b3c617fb3e2f7886272d26ff
https://github.com/llvm/llvm-project/commit/610139d2d9ce6746b3c617fb3e2f7886272d26ff
Author: Alex Zinenko <zinenko at google.com>
Date: 2022-06-17 (Fri, 17 Jun 2022)
Changed paths:
M mlir/include/mlir/Conversion/LLVMCommon/LoweringOptions.h
M mlir/include/mlir/Conversion/Passes.td
M mlir/include/mlir/Dialect/LLVMIR/LLVMOpBase.td
M mlir/include/mlir/Dialect/LLVMIR/Transforms/Passes.h
M mlir/include/mlir/Dialect/LLVMIR/Transforms/Passes.td
A mlir/include/mlir/Dialect/LLVMIR/Transforms/RequestCWrappers.h
M mlir/lib/Conversion/FuncToLLVM/FuncToLLVM.cpp
M mlir/lib/Conversion/GPUToNVVM/LowerGpuOpsToNVVMOps.cpp
M mlir/lib/Conversion/GPUToROCDL/LowerGpuOpsToROCDLOps.cpp
M mlir/lib/Conversion/LinalgToStandard/LinalgToStandard.cpp
M mlir/lib/Conversion/SPIRVToLLVM/ConvertLaunchFuncToLLVMCalls.cpp
M mlir/lib/Dialect/LLVMIR/Transforms/CMakeLists.txt
M mlir/lib/Dialect/LLVMIR/Transforms/PassDetail.h
A mlir/lib/Dialect/LLVMIR/Transforms/RequestCWrappers.cpp
M mlir/lib/Dialect/SparseTensor/Transforms/SparseTensorConversion.cpp
M mlir/test/Conversion/FuncToLLVM/calling-convention.mlir
A mlir/test/Conversion/FuncToLLVM/emit-c-wrappers-for-external-callers.mlir
A mlir/test/Conversion/FuncToLLVM/emit-c-wrappers-for-external-functions.mlir
M mlir/test/Conversion/GPUToNVVM/wmma-ops-to-nvvm.mlir
R mlir/test/Conversion/StandardToLLVM/emit-c-wrappers-for-external-callers.mlir
R mlir/test/Conversion/StandardToLLVM/emit-c-wrappers-for-external-functions.mlir
A mlir/test/Dialect/LLVMIR/request-c-wrappers.mlir
M mlir/tools/mlir-vulkan-runner/mlir-vulkan-runner.cpp
M utils/bazel/llvm-project-overlay/mlir/BUILD.bazel
Log Message:
-----------
[mlir] replace 'emit_c_wrappers' func->llvm conversion option with a pass
The 'emit_c_wrappers' option in the FuncToLLVM conversion requests C interface
wrappers to be emitted for every builtin function in the module. While this has
been useful to bootstrap the interface, it is problematic in the longer term as
it may unintentionally affect the functions that should retain their existing
interface, e.g., libm functions obtained by lowering math operations (see
D126964 for an example). Since D77314, we have a finer-grain control over
interface generation via an attribute that avoids the problem entirely. Remove
the 'emit_c_wrappers' option. Introduce the '-llvm-request-c-wrappers' pass
that can be run in any pipeline that needs blanket emission of functions to
annotate all builtin functions with the attribute before performing the usual
lowering that accounts for the attribute.
Reviewed By: chelini
Differential Revision: https://reviews.llvm.org/D127952
More information about the All-commits
mailing list