File tree Expand file tree Collapse file tree 2 files changed +4
-9
lines changed Expand file tree Collapse file tree 2 files changed +4
-9
lines changed Original file line number Diff line number Diff line change @@ -36,13 +36,6 @@ list(APPEND compile_options -Wno-unknown-cuda-version)
3636if (LLVM_DEFAULT_TARGET_TRIPLE)
3737 list (APPEND compile_options --target =${LLVM_DEFAULT_TARGET_TRIPLE} )
3838endif ()
39- # Ensure that CPU-related parameters won't be brought in.
40- string (REGEX REPLACE "-mcpu[^ \t\r\n ]*" "" CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} " )
41- string (REGEX REPLACE "-march[^ \t\r\n ]*" "" CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} " )
42- string (REGEX REPLACE "-mtune[^ \t\r\n ]*" "" CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} " )
43- string (REGEX REPLACE "-mbranch-protection[^ \t\r\n ]*" "" CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} " )
44- string (REGEX REPLACE "-fcf-protection[^ \t\r\n ]*" "" CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} " )
45- list (APPEND compile_options -Wno-unused-command -line-argument)
4639
4740# We disable the slp vectorizer during the runtime optimization to avoid
4841# vectorized accesses to the shared state. Generally, those are "good" but
Original file line number Diff line number Diff line change @@ -82,8 +82,10 @@ Support for the device library comes from a separate build of the OpenMP library
8282that targets the GPU architecture. Building it requires enabling the runtime
8383targets, or setting the target manually when doing a standalone build. This is
8484done with the ``LLVM_RUNTIME_TARGETS `` option and then enabling the OpenMP
85- runtime for the GPU target. ``RUNTIMES_<triple>_LLVM_ENABLE_RUNTIMES ``. Refer to
86- the cache file for the specific invocation.
85+ runtime for the GPU target via ``RUNTIMES_<triple>_LLVM_ENABLE_RUNTIMES ``.
86+ It's possible to set different flags for each device library by using
87+ ``RUNTIMES_<triple>_CMAKE_CXX_FLAGS ``. Refer to the cache file for the specific
88+ invocation.
8789
8890For Nvidia offload, please see :ref: `build_nvidia_offload_capable_compiler `.
8991For AMDGPU offload, please see :ref: `build_amdgpu_offload_capable_compiler `.
You can’t perform that action at this time.
0 commit comments