mirror of
https://github.com/capstone-engine/llvm-capstone.git
synced 2025-04-01 12:43:47 +00:00
[BOLT][runtime] Test for outline-atomics support
I'm using clang-10 to build bolt which doesn't have moutline-atomics option and though it doesn't do it. So test compiler for supporting it before appending to the list of cxxflags. Differential Revision: https://reviews.llvm.org/D159521
This commit is contained in:
parent
682270877d
commit
80c01dd626
@ -1,4 +1,5 @@
|
||||
cmake_minimum_required(VERSION 3.20.0)
|
||||
include(CheckCXXCompilerFlag)
|
||||
include(CheckIncludeFiles)
|
||||
include(GNUInstallDirs)
|
||||
|
||||
@ -33,7 +34,10 @@ if (CMAKE_SYSTEM_PROCESSOR MATCHES "x86_64")
|
||||
set(BOLT_RT_FLAGS ${BOLT_RT_FLAGS} "-mno-sse")
|
||||
endif()
|
||||
if (CMAKE_SYSTEM_PROCESSOR MATCHES "aarch64")
|
||||
set(BOLT_RT_FLAGS ${BOLT_RT_FLAGS} "-mno-outline-atomics")
|
||||
check_cxx_compiler_flag("-mno-outline-atomics" CXX_SUPPORTS_OUTLINE_ATOMICS)
|
||||
if (CXX_SUPPORTS_OUTLINE_ATOMICS)
|
||||
set(BOLT_RT_FLAGS ${BOLT_RT_FLAGS} "-mno-outline-atomics")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
# Don't let the compiler think it can create calls to standard libs
|
||||
|
Loading…
x
Reference in New Issue
Block a user