[AArch64,ARM] support bswap tests on aarch64_be.
authorChristophe Lyon <christophe.lyon@linaro.org>
Wed, 5 Nov 2014 15:19:19 +0000 (15:19 +0000)
committerChristophe Lyon <clyon@gcc.gnu.org>
Wed, 5 Nov 2014 15:19:19 +0000 (16:19 +0100)
[AArch64,ARM] support bswap tests on aarch64_be. Skip them on ARM
targets older than v6.

2014-11-05  Christophe Lyon  <christophe.lyon@linaro.org>

* lib/target-supports.exp (check_effective_target_bswap): Update
conditions for AArch64 and ARM targets.

From-SVN: r217133

gcc/testsuite/ChangeLog
gcc/testsuite/lib/target-supports.exp

index 86a9eb9452121b721021312f7518bac2fa315c42..46f62b61aa506b1073d3d05da2b504a959bfe481 100644 (file)
@@ -1,3 +1,8 @@
+2014-11-05  Christophe Lyon  <christophe.lyon@linaro.org>
+
+       * lib/target-supports.exp (check_effective_target_bswap): Update
+       conditions for AArch64 and ARM targets.
+
 2014-11-05  David Edelsohn  <dje.gcc@gmail.com>
 
        * gcc.dg/torture/pr59166.c: XFAIL on AIX.
index e5b04ec5f9057f24f63e43020a24309a384e311a..5a386415220739e91384dac3ca6e485813bd9311 100644 (file)
@@ -4864,15 +4864,24 @@ proc check_effective_target_bswap { } {
         verbose "check_effective_target_bswap: using cached result" 2
     } else {
        set et_bswap_saved 0
-       if { [istarget aarch64-*-*]
+       if { [istarget aarch64*-*-*]
             || [istarget alpha*-*-*]
-            || [istarget arm*-*-*]
             || [istarget i?86-*-*] || [istarget x86_64-*-*]
             || [istarget m68k-*-*]
             || [istarget powerpc*-*-*]
             || [istarget rs6000-*-*]
             || [istarget s390*-*-*] } {
            set et_bswap_saved 1
+       } else {
+           if { [istarget arm*-*-*]
+                && [check_no_compiler_messages_nocache arm_v6_or_later object {
+                    #if __ARM_ARCH < 6
+                    #error not armv6 or later
+                    #endif
+                    int i;
+                } ""] } {
+               set et_bswap_saved 1
+           }
        }
     }