This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [patch] MIPS: Two classes associated with the "e" constraint
- From: "Maciej W. Rozycki" <macro at ds2 dot pg dot gda dot pl>
- To: Richard Sandiford <rsandifo at redhat dot com>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Sat, 28 Feb 2004 10:19:26 +0100 (CET)
- Subject: Re: [patch] MIPS: Two classes associated with the "e" constraint
- Organization: Technical University of Gdansk
- References: <Pine.LNX.4.55.0402272339550.10715@jurand.ds.pg.gda.pl><87d67zd1gm.fsf@redhat.com>
On Sat, 28 Feb 2004, Richard Sandiford wrote:
> Yes:
>
> mips_char_to_class['e'] = M16_NA_REGS;
>
> should just be removed. Like you say, it's not used by any of the
> .md patterns. Nor is it documented as a MIPS-specific constraint,
> so I don't see any need to keep it for inline asm.
>
> I remember checking that "e" wasn't needed before remapping it to
> LEA_REGS. ("e" for effective address, of course.) I was supposed
> to get rid of the line above at the same time. but obviously I forgot.
Here's an updated patch then.
2004-02-28 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
* config/mips/mips.c (override_options): Remove an obsolete
duplicate definition of the "e" constraint.
config/mips/mips.h: Update a comment accordingly.
Please apply.
Maciej
--
+ Maciej W. Rozycki, Technical University of Gdansk, Poland +
+--------------------------------------------------------------+
+ e-mail: macro@ds2.pg.gda.pl, PGP key available +
gcc-3.4-20031107-mips-lea_regs.patch
diff -up --recursive --new-file gcc-3.4-20031107.macro/gcc/config/mips/mips.c gcc-3.4-20031107/gcc/config/mips/mips.c
--- gcc-3.4-20031107.macro/gcc/config/mips/mips.c 2003-11-07 08:14:32.000000000 +0000
+++ gcc-3.4-20031107/gcc/config/mips/mips.c 2004-02-28 09:01:58.000000000 +0000
@@ -4832,7 +4832,6 @@ override_options (void)
mips_print_operand_punct['~'] = 1;
mips_char_to_class['d'] = TARGET_MIPS16 ? M16_REGS : GR_REGS;
- mips_char_to_class['e'] = M16_NA_REGS;
mips_char_to_class['t'] = T_REG;
mips_char_to_class['f'] = (TARGET_HARD_FLOAT ? FP_REGS : NO_REGS);
mips_char_to_class['h'] = HI_REG;
diff -up --recursive --new-file gcc-3.4-20031107.macro/gcc/config/mips/mips.h gcc-3.4-20031107/gcc/config/mips/mips.h
--- gcc-3.4-20031107.macro/gcc/config/mips/mips.h 2003-11-04 22:13:30.000000000 +0000
+++ gcc-3.4-20031107/gcc/config/mips/mips.h 2004-02-28 09:05:13.000000000 +0000
@@ -1924,7 +1924,7 @@ extern const enum reg_class mips_regno_t
'd' General (aka integer) registers
Normally this is GR_REGS, but in mips16 mode this is M16_REGS
'y' General registers (in both mips16 and non mips16 mode)
- 'e' mips16 non argument registers (M16_NA_REGS)
+ 'e' Effective address registers (general registers except $25)
't' mips16 temporary register ($24)
'f' Floating point registers
'h' Hi register