This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Re: [PATCH] MIPS gas: use $zero as alias for $0
- From: Daniel Jacobowitz <drow at mvista dot com>
- To: Thiemo Seufer <ica2_ts at csv dot ica dot uni-stuttgart dot de>
- Cc: binutils at sources dot redhat dot com
- Date: Sat, 1 Jun 2002 02:32:19 -0400
- Subject: Re: [PATCH] MIPS gas: use $zero as alias for $0
- References: <20020601020019.GA23411@rembrandt.csv.ica.uni-stuttgart.de>
On Sat, Jun 01, 2002 at 04:00:20AM +0200, Thiemo Seufer wrote:
> Hi All,
>
> this adds '$zero' as an alias name for the hardware special register $0.
> It also allows the use of $kt0, $kt1 aliases, this is compatible to native
> mips tools.
> @@ -8231,6 +8219,11 @@ mips_ip (str, ip)
> s += 4;
> regno = KT1;
> }
> + else if (s[1] == 'z' && s[2] == 'e' && s[3] == 'r' && s[4] == '0')
> + {
> + s += 5;
> + regno = ZERO;
> + }
> else if (itbl_have_entries)
> {
> char *p, *n;
Surely you meant 's[4] == 'o''?
> @@ -12230,6 +12203,12 @@ tc_get_register (frame)
> reg = GP;
> else if (strncmp (input_line_pointer, "at", 2) == 0)
> reg = AT;
> + else if (strncmp (input_line_pointer, "kt0", 3) == 0)
> + reg = KT0;
> + else if (strncmp (input_line_pointer, "kt1", 3) == 0)
> + reg = KT1;
> + else if (strncmp (input_line_pointer, "zero", 4) == 0)
> + reg = ZERO;
> else
> {
> as_warn (_("Unrecognized register name"));
This isn't introduced by your patch, but - what will this code do with
"$at1" or "$kt12"?
--
Daniel Jacobowitz Carnegie Mellon University
MontaVista Software Debian GNU/Linux Developer