diff options
author | Tzachi Zidenberg <tsahee@amazon.com> | 2020-07-05 15:21:43 +0300 |
---|---|---|
committer | Tzachi Zidenberg <tsahee@amazon.com> | 2020-07-23 15:08:54 +0300 |
commit | f843e215f3f640de377d8fd60e85bb372fb138fd (patch) | |
tree | e408f53e303f822aa643340d80ab79bb37bbd5dd /configure.cmake | |
parent | c76b45a5242f50d00c16f0bbf1dbecd4e359e02c (diff) | |
download | mariadb-git-f843e215f3f640de377d8fd60e85bb372fb138fd.tar.gz |
aarch64: use compiler flag outline-atomics if available
outline-atomics compilation flag changes behaviour of builtin_atomics,
by adding runtime detection of LSE atomics. If these are supported, they
will be used. This gains LSE atomics use without hurting compatibility
with older aarch64 machines.
Diffstat (limited to 'configure.cmake')
-rw-r--r-- | configure.cmake | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/configure.cmake b/configure.cmake index 43c32fda0ee..5dd45a6b05d 100644 --- a/configure.cmake +++ b/configure.cmake @@ -69,6 +69,11 @@ IF(CMAKE_SYSTEM_PROCESSOR STREQUAL "i686" AND CMAKE_COMPILER_IS_GNUCC AND SET(PLUGIN_QUERY_RESPONSE_TIME NO CACHE BOOL "Disabled, gcc is too old") ENDIF() +# use runtime atomic-support detection in aarch64 +IF(CMAKE_SYSTEM_PROCESSOR MATCHES "aarch64") + MY_CHECK_AND_SET_COMPILER_FLAG("-moutline-atomics") +ENDIF() + IF(WITHOUT_DYNAMIC_PLUGINS) MESSAGE("Dynamic plugins are disabled.") ENDIF(WITHOUT_DYNAMIC_PLUGINS) |