diff options
-rw-r--r-- | gcc/ChangeLog | 6 | ||||
-rw-r--r-- | gcc/config/m68k/m68k.c | 2 | ||||
-rw-r--r-- | gcc/config/m68k/m68k.h | 1 | ||||
-rw-r--r-- | gcc/config/m68k/m68k.md | 14 |
4 files changed, 15 insertions, 8 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index a8e0835..2363472 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,4 +1,10 @@ 2007-01-12 Julian Brown <julian@codesourcery.com> + + * config/m68k/m68k.h (TUNE_68040_60): New macro. + * config/m68k/m68k.c (standard_68881_constant_p): Use it. + * config/m68k/m68k.md: Likewise. + +2007-01-12 Julian Brown <julian@codesourcery.com> Richard Sandiford <richard@codesourcery.com> * config/m68k/m68k.h (TARGET_CPU_CPP_BUILTINS): Use TUNE_68030 diff --git a/gcc/config/m68k/m68k.c b/gcc/config/m68k/m68k.c index 0fae1d9..2a2b1aa 100644 --- a/gcc/config/m68k/m68k.c +++ b/gcc/config/m68k/m68k.c @@ -2789,7 +2789,7 @@ standard_68881_constant_p (rtx x) /* fmovecr must be emulated on the 68040 and 68060, so it shouldn't be used at all on those chips. */ - if (TUNE_68040 || TUNE_68060) + if (TUNE_68040_60) return 0; if (! inited_68881_table) diff --git a/gcc/config/m68k/m68k.h b/gcc/config/m68k/m68k.h index b50bf10..5eedd9a 100644 --- a/gcc/config/m68k/m68k.h +++ b/gcc/config/m68k/m68k.h @@ -130,6 +130,7 @@ Boston, MA 02110-1301, USA. */ #define TUNE_68030 TARGET_68030 #define TUNE_68040 TARGET_68040 #define TUNE_68060 TARGET_68060 +#define TUNE_68040_60 (TUNE_68040 || TUNE_68060) #define TUNE_CFV2 TARGET_5200 #define OVERRIDE_OPTIONS override_options() diff --git a/gcc/config/m68k/m68k.md b/gcc/config/m68k/m68k.md index 92fd31c..c02c75c 100644 --- a/gcc/config/m68k/m68k.md +++ b/gcc/config/m68k/m68k.md @@ -618,10 +618,10 @@ if (ADDRESS_REG_P (operands[0])) { /* On the '040, 'subl an,an' takes 2 clocks while lea takes only 1 */ - if (!TUNE_68040 && !TUNE_68060) - return "sub%.l %0,%0"; - else + if (TUNE_68040_60) return MOTOROLA ? "lea 0.w,%0" : "lea 0:w,%0"; + else + return "sub%.l %0,%0"; } /* moveq is faster on the 68000. */ if (DATA_REG_P (operands[0]) && TUNE_68000_10) @@ -846,10 +846,10 @@ if (ADDRESS_REG_P (operands[0])) { /* On the '040, 'subl an,an' takes 2 clocks while lea takes only 1 */ - if (!TUNE_68040 && !TUNE_68060) - return "sub%.l %0,%0"; - else + if (TUNE_68040_60) return MOTOROLA ? "lea 0.w,%0" : "lea 0:w,%0"; + else + return "sub%.l %0,%0"; } /* moveq is faster on the 68000. */ if (DATA_REG_P (operands[0]) && TUNE_68000_10) @@ -2869,7 +2869,7 @@ "TARGET_68881" { if (GET_CODE (operands[2]) == CONST_DOUBLE - && floating_exact_log2 (operands[2]) && !TUNE_68040 && !TUNE_68060) + && floating_exact_log2 (operands[2]) && !TUNE_68040_60) { int i = floating_exact_log2 (operands[2]); operands[2] = GEN_INT (i); |