Skip to content

Commit 64574d3

Browse files
wenju-heMaetveis
andauthored
[libclc] Remove -fno-builtin from compile options (#162075)
The flag was added in 8ef48d0 to suppress build warning and is no longer needed. It adds "no-builtins" attribute, which prevents libclc functions from being inlined into caller that don't have the attribute. The flag is meant to prevent folding standard library calls into optimized implementations. For libclc device targets, however, such target‑driven folding is desirable. llvm-diff shows no change to amdgcn--amdhsa.bc and nvptx--nvidiacl.bc. Co-authored-by: Mészáros Gergely <[email protected]>
1 parent f490dbd commit 64574d3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

libclc/cmake/modules/AddLibclc.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -353,7 +353,7 @@ function(add_libclc_builtin_set)
353353
TRIPLE ${ARG_TRIPLE}
354354
INPUT ${input_file}
355355
OUTPUT ${output_file}
356-
EXTRA_OPTS -fno-builtin -nostdlib "${ARG_COMPILE_FLAGS}"
356+
EXTRA_OPTS -nostdlib "${ARG_COMPILE_FLAGS}"
357357
"${file_specific_compile_options}"
358358
-I${CMAKE_CURRENT_SOURCE_DIR}/${file_dir}
359359
DEPENDENCIES ${input_file_dep}

0 commit comments

Comments
 (0)