summaryrefslogtreecommitdiff
path: root/gdb/alpha-tdep.c
diff options
context:
space:
mode:
authorRichard Henderson <rth@redhat.com>2003-06-02 22:54:01 +0000
committerRichard Henderson <rth@redhat.com>2003-06-02 22:54:01 +0000
commit9ea9fa6c1f9028cd70849e442379bc0bd7ba94ad (patch)
tree290d4217efcd480510a79658aed4d2e66903341c /gdb/alpha-tdep.c
parent65651f6f9235598b3f4993d12a38dd81114ff6bd (diff)
downloadgdb-9ea9fa6c1f9028cd70849e442379bc0bd7ba94ad.tar.gz
* alpha-tdep.c (alpha_register_reggroup_p): Zero is only
a member of all_reggroup.
Diffstat (limited to 'gdb/alpha-tdep.c')
-rw-r--r--gdb/alpha-tdep.c16
1 files changed, 12 insertions, 4 deletions
diff --git a/gdb/alpha-tdep.c b/gdb/alpha-tdep.c
index 6d9c58d4e5d..da514bf1c1e 100644
--- a/gdb/alpha-tdep.c
+++ b/gdb/alpha-tdep.c
@@ -107,10 +107,18 @@ alpha_register_reggroup_p (struct gdbarch *gdbarch, int regnum,
if (REGISTER_NAME (regnum) == NULL || *REGISTER_NAME (regnum) == '\0')
return 0;
- /* Since we implement no pseudo registers, save/restore is equal to all. */
- if (group == all_reggroup
- || group == save_reggroup
- || group == restore_reggroup)
+ if (group == all_reggroup)
+ return 1;
+
+ /* Zero should not be saved or restored. Technically it is a general
+ register (just as $f31 would be a float if we represented it), but
+ there's no point displaying it during "info regs", so leave it out
+ of all groups except for "all". */
+ if (regnum == ALPHA_ZERO_REGNUM)
+ return 0;
+
+ /* All other registers are saved and restored. */
+ if (group == save_reggroup || group == restore_reggroup)
return 1;
/* All other groups are non-overlapping. */