diff options
author | Maxim Uvarov <maxim.uvarov@linaro.org> | 2018-11-19 17:53:46 +0300 |
---|---|---|
committer | Maxim Uvarov <maxim.uvarov@linaro.org> | 2018-11-21 17:51:57 +0300 |
commit | d63f90cf86c4f531007122fff497537dab81c088 (patch) | |
tree | 3e7a7c923322408f530967a7970bf766faf56ef4 /configure.ac | |
parent | 6c2c1bbf83a2a69b99d28baecfc8bd3421b651d6 (diff) |
configure: disable -march=native for clang
for clang we see strange optimizations for TM code which breaks
code flow execution. There might be number of such places. For
now it's better to disable march=native until we completely
test and validate clang support for this.
Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
Reviewed-by: Petri Savolainen <petri.savolainen@linaro.org>
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/configure.ac b/configure.ac index 6715a7ef2..2ce476a61 100644 --- a/configure.ac +++ b/configure.ac @@ -200,7 +200,12 @@ AC_ARG_ENABLE([abi-compat], abi_compat=no #if there is no ABI compatibility the .so numbers are meaningless ODP_LIBSO_VERSION=0:0:0 - ODP_CHECK_CFLAG([-march=native]) + # do not try -march=native for clang due to possible failures on + # clang optimizations + $CC --version | grep -q clang + if test $? -ne 0; then + ODP_CHECK_CFLAG([-march=native]) + fi fi]) AM_CONDITIONAL(ODP_ABI_COMPAT, [test "x$ODP_ABI_COMPAT" = "x1"]) |