From: Renlin Li Date: Wed, 19 Nov 2014 12:47:26 +0000 (+0000) Subject: This is simple patch to add more conditional macros defined in ACLE 2.0. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=45b70a7372142320ffcd73d98a5ddc7862ac283c;p=gcc.git This is simple patch to add more conditional macros defined in ACLE 2.0. 2014-10-17 Renlin Li * config/aarch64/aarch64.h (TARGET_CPU_CPP_BUILTINS): Define __ARM_FP_FAST, __ARM_FEATURE_FMA, __ARM_FP, __ARM_FEATURE_NUMERIC_MAXMIN, __ARM_NEON_FP. From-SVN: r217768 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 0e9638888d6..c5bd5e73ac0 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2014-11-19 Renlin Li + + * config/aarch64/aarch64.h (TARGET_CPU_CPP_BUILTINS): Define __ARM_FP_FAST, + __ARM_FEATURE_FMA, __ARM_FP, __ARM_FEATURE_NUMERIC_MAXMIN, __ARM_NEON_FP. + 2014-11-19 Marek Polacek PR sanitizer/63879 diff --git a/gcc/config/aarch64/aarch64.h b/gcc/config/aarch64/aarch64.h index c046b43c662..bbe33a92983 100644 --- a/gcc/config/aarch64/aarch64.h +++ b/gcc/config/aarch64/aarch64.h @@ -38,6 +38,8 @@ builtin_define ("__ARM_FEATURE_CLZ"); \ builtin_define ("__ARM_FEATURE_IDIV"); \ builtin_define ("__ARM_FEATURE_UNALIGNED"); \ + if (flag_unsafe_math_optimizations) \ + builtin_define ("__ARM_FP_FAST"); \ builtin_define ("__ARM_PCS_AAPCS64"); \ builtin_define_with_int_value \ ("__ARM_SIZEOF_WCHAR_T", WCHAR_TYPE_SIZE / 8); \ @@ -52,10 +54,19 @@ else \ builtin_define ("__AARCH64EL__"); \ \ - if (TARGET_SIMD) \ - builtin_define ("__ARM_NEON"); \ - \ - if (TARGET_CRC32) \ + if (TARGET_FLOAT) \ + { \ + builtin_define ("__ARM_FEATURE_FMA"); \ + builtin_define_with_int_value ("__ARM_FP", 0x0C); \ + } \ + if (TARGET_SIMD) \ + { \ + builtin_define ("__ARM_FEATURE_NUMERIC_MAXMIN"); \ + builtin_define ("__ARM_NEON"); \ + builtin_define_with_int_value ("__ARM_NEON_FP", 0x0C);\ + } \ + \ + if (TARGET_CRC32) \ builtin_define ("__ARM_FEATURE_CRC32"); \ \ switch (aarch64_cmodel) \