freebsd.h: Only enable unaligned access for armv6 on FreeBSD 11 and above.
authorAndreas Tobler <andreast@gcc.gnu.org>
Tue, 14 Jun 2016 19:53:01 +0000 (21:53 +0200)
committerAndreas Tobler <andreast@gcc.gnu.org>
Tue, 14 Jun 2016 19:53:01 +0000 (21:53 +0200)
2016-06-14  Andreas Tobler  <andreast@gcc.gnu.org>

    * config/arm/freebsd.h: Only enable unaligned access for armv6 on
    FreeBSD 11 and above.

From-SVN: r237457

gcc/ChangeLog
gcc/config/arm/freebsd.h

index f95e4a659e573790b5afa07f18a0d00912aaac58..2389681f418a2ed42ff5b6e01d5a293f643b1efa 100644 (file)
@@ -1,3 +1,8 @@
+2016-06-14  Andreas Tobler  <andreast@gcc.gnu.org>
+
+       * config/arm/freebsd.h: Only enable unaligned access for armv6 on
+       FreeBSD 11 and above.
+
 2016-06-14  Uros Bizjak  <ubizjak@gmail.com>
 
        * config/i386/i386.md (signbittf2): Emit sse_movmskps for TARGET_SSE.
index 948fdd6843e35c7e8e99d36df6b8ab0fa757e4e1..0ade4e99be17ca5f752c034c1ca18ef33d5cb4bb 100644 (file)
 #define SUBTARGET_CPU_DEFAULT   TARGET_CPU_arm9
 #endif
 
+/* FreeBSD 10 does not support unaligned access for armv6 and up.
+   Unaligned access support was added in FreeBSD 11.  */
+#if FBSD_MAJOR < 11
 #define SUBTARGET_OVERRIDE_INTERNAL_OPTIONS                            \
 do {                                                                   \
     if (opts_set->x_unaligned_access == 1)                             \
@@ -127,6 +130,7 @@ do {                                                                        \
     if (opts->x_unaligned_access)                                      \
        opts->x_unaligned_access = 0;                                   \
 } while (0)
+#endif
 
 #undef MAX_SYNC_LIBFUNC_SIZE
 #define MAX_SYNC_LIBFUNC_SIZE 4 /* UNITS_PER_WORD not defined yet.  */