diff options
author | Richard Sandiford <rdsandiford@googlemail.com> | 2011-07-04 20:22:52 +0000 |
---|---|---|
committer | Richard Sandiford <rdsandiford@googlemail.com> | 2011-07-04 20:22:52 +0000 |
commit | fe35f09f47706967f1ccc7c29b6b07823b8d36c6 (patch) | |
tree | bd8a6cf58944f64955265fb7e2487216418e2363 /gas | |
parent | efae1d92444eb89a85b336fd1654e7376cad7bd7 (diff) | |
download | gdb-fe35f09f47706967f1ccc7c29b6b07823b8d36c6.zip gdb-fe35f09f47706967f1ccc7c29b6b07823b8d36c6.tar.gz gdb-fe35f09f47706967f1ccc7c29b6b07823b8d36c6.tar.bz2 |
gas/
* config/tc-mips.c (gpr_read_mask, gpr_write_mask): Fix handling
of register 0.
Diffstat (limited to 'gas')
-rw-r--r-- | gas/ChangeLog | 5 | ||||
-rw-r--r-- | gas/config/tc-mips.c | 6 |
2 files changed, 9 insertions, 2 deletions
diff --git a/gas/ChangeLog b/gas/ChangeLog index 8bc4f50..9c0ded1 100644 --- a/gas/ChangeLog +++ b/gas/ChangeLog @@ -1,3 +1,8 @@ +2011-07-04 Richard Sandiford <rdsandiford@googlemail.com> + + * config/tc-mips.c (gpr_read_mask, gpr_write_mask): Fix handling + of register 0. + 2011-07-04 Maciej W. Rozycki <macro@codesourcery.com> * config/tc-mips.c (append_insn): Make sure DWARF-2 location diff --git a/gas/config/tc-mips.c b/gas/config/tc-mips.c index 2b3e4dc..bcb1822 100644 --- a/gas/config/tc-mips.c +++ b/gas/config/tc-mips.c @@ -2450,7 +2450,8 @@ gpr_read_mask (const struct mips_cl_insn *ip) if (pinfo2 & INSN2_READ_GPR_Z) mask |= 1 << EXTRACT_OPERAND (RZ, *ip); } - return mask & ~0; + /* Don't include register 0. */ + return mask & ~1; } /* Return the mask of core registers that IP writes. */ @@ -2492,7 +2493,8 @@ gpr_write_mask (const struct mips_cl_insn *ip) if (pinfo2 & INSN2_WRITE_GPR_Z) mask |= 1 << EXTRACT_OPERAND (RZ, *ip); } - return mask & ~0; + /* Don't include register 0. */ + return mask & ~1; } /* Return the mask of floating-point registers that IP reads. */ |