diff options
author | Kevin Buettner <kevinb@redhat.com> | 2002-08-26 23:20:53 +0000 |
---|---|---|
committer | Kevin Buettner <kevinb@redhat.com> | 2002-08-26 23:20:53 +0000 |
commit | 64b841757f879d5a3164a18a300007a76a69ddda (patch) | |
tree | d1eca9bd0a57125be49c50d63624201a1037ab00 /gdb | |
parent | 68a4c07345e6cf85d8b6fbe0d846028ed48f0dba (diff) | |
download | fsf-binutils-gdb-64b841757f879d5a3164a18a300007a76a69ddda.zip fsf-binutils-gdb-64b841757f879d5a3164a18a300007a76a69ddda.tar.gz fsf-binutils-gdb-64b841757f879d5a3164a18a300007a76a69ddda.tar.bz2 |
* rs6000-tdep.c (altivec_register_p): Restore function inadvertently
deleted in 2002-08-20 commit. This function is still used by
ppc-linux-nat.c.
Diffstat (limited to 'gdb')
-rw-r--r-- | gdb/ChangeLog | 6 | ||||
-rw-r--r-- | gdb/rs6000-tdep.c | 11 |
2 files changed, 17 insertions, 0 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 4bf6a75..eeb211a 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,9 @@ +2002-08-26 Kevin Buettner <kevinb@redhat.com> + + * rs6000-tdep.c (altivec_register_p): Restore function inadvertently + deleted in 2002-08-20 commit. This function is still used by + ppc-linux-nat.c. + 2002-08-26 Keith Seitz <keiths@redhat.com> * gdb-events.sh: Add selected-frame-level-changed event. diff --git a/gdb/rs6000-tdep.c b/gdb/rs6000-tdep.c index 398b0e0..f661861 100644 --- a/gdb/rs6000-tdep.c +++ b/gdb/rs6000-tdep.c @@ -123,6 +123,17 @@ static void frame_get_saved_regs (struct frame_info * fi, struct rs6000_framedata * fdatap); static CORE_ADDR frame_initial_stack_address (struct frame_info *); +/* Is REGNO an AltiVec register? Return 1 if so, 0 otherwise. */ +int +altivec_register_p (int regno) +{ + struct gdbarch_tdep *tdep = gdbarch_tdep (current_gdbarch); + if (tdep->ppc_vr0_regnum < 0 || tdep->ppc_vrsave_regnum < 0) + return 0; + else + return (regno >= tdep->ppc_vr0_regnum && regno <= tdep->ppc_vrsave_regnum); +} + /* Read a LEN-byte address from debugged memory address MEMADDR. */ static CORE_ADDR |