From 8785d88cf18403b3f36973820c42ab4990c7a4c5 Mon Sep 17 00:00:00 2001 From: Kazu Hirata Date: Sat, 1 Sep 2007 18:55:48 +0000 Subject: [PATCH] m68k.c (TARGET_DEFAULT_TARGET_FLAGS): Remove. * config/m68k/m68k.c (TARGET_DEFAULT_TARGET_FLAGS): Remove. (override_options): Turn on -mstrict-align on non-ColdFire targets. * config/m68k/m68k.h (BIGGEST_ALIGNMENT): Update a comment. From-SVN: r128015 --- gcc/ChangeLog | 7 +++++++ gcc/config/m68k/m68k.c | 7 +++++-- gcc/config/m68k/m68k.h | 3 +-- 3 files changed, 13 insertions(+), 4 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 4b0271c1c12..60eb7cae1b7 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,10 @@ +2007-09-01 Kazu Hirata + + * config/m68k/m68k.c (TARGET_DEFAULT_TARGET_FLAGS): Remove. + (override_options): Turn on -mstrict-align on non-ColdFire + targets. + * config/m68k/m68k.h (BIGGEST_ALIGNMENT): Update a comment. + 2007-09-01 Kaveh R. Ghazi * c-common.c (const_strip_array_types): Delete. diff --git a/gcc/config/m68k/m68k.c b/gcc/config/m68k/m68k.c index f1f09bc86c1..76d765e7252 100644 --- a/gcc/config/m68k/m68k.c +++ b/gcc/config/m68k/m68k.c @@ -185,8 +185,6 @@ int m68k_last_compare_had_fp_operands; #undef TARGET_ASM_FILE_START_APP_OFF #define TARGET_ASM_FILE_START_APP_OFF true -#undef TARGET_DEFAULT_TARGET_FLAGS -#define TARGET_DEFAULT_TARGET_FLAGS MASK_STRICT_ALIGNMENT #undef TARGET_HANDLE_OPTION #define TARGET_HANDLE_OPTION m68k_handle_option @@ -510,6 +508,11 @@ override_options (void) /* Use the architecture setting to derive default values for certain flags. */ target_mask = 0; + + /* ColdFire is lenient about alignment. */ + if (!TARGET_COLDFIRE) + target_mask |= MASK_STRICT_ALIGNMENT; + if ((m68k_cpu_flags & FL_BITFIELD) != 0) target_mask |= MASK_BITFIELD; if ((m68k_cpu_flags & FL_CF_HWDIV) != 0) diff --git a/gcc/config/m68k/m68k.h b/gcc/config/m68k/m68k.h index a5f6eedf070..96756f3a4c8 100644 --- a/gcc/config/m68k/m68k.h +++ b/gcc/config/m68k/m68k.h @@ -305,8 +305,7 @@ along with GCC; see the file COPYING3. If not see /* No data type wants to be aligned rounder than this. Most published ABIs say that ints should be aligned on 16-bit boundaries, but CPUs with 32-bit busses get better performance - aligned on 32-bit boundaries. ColdFires without a misalignment - module require 32-bit alignment. */ + aligned on 32-bit boundaries. */ #define BIGGEST_ALIGNMENT (TARGET_ALIGN_INT ? 32 : 16) #define STRICT_ALIGNMENT (TARGET_STRICT_ALIGNMENT) -- 2.30.2