[libclc] [libclc] Move sign to the CLC builtins library (PR #115699)
Karol Herbst via cfe-commits
cfe-commits at lists.llvm.org
Wed Nov 20 02:27:50 PST 2024
================
@@ -322,22 +322,26 @@ foreach( t ${LIBCLC_TARGETS_TO_BUILD} )
if ( ARCH STREQUAL spirv OR ARCH STREQUAL spirv64 )
set( build_flags -O0 -finline-hint-functions -DCLC_SPIRV )
- set( opt_flags )
+ set( clc_opt_flags )
+ # Inline CLC functions into OpenCL builtins
+ set( opencl_opt_flags "--passes=always-inline" )
----------------
karolherbst wrote:
yeah, as long as the OpenCL C builtins aren't inlined into the implementations of other builtins (e.g. a builtin implemented using `fma`) we are fine with any internal inlining, just want to keep the calls to OpenCL C builtins there.
And one thing I forgot to mention is, that we rely on the function name mangling to do our custom function lookup/linking, but I guess this won't be touched by any of this here.
https://github.com/llvm/llvm-project/pull/115699
More information about the cfe-commits
mailing list