This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[RFA] config/rs6000/tm-rs6000.h STAB_REG_TO_REGNUM



This patch is from Vlad Makarov.  I have tested it on aix 4.3 and it
reduces the number of failures by about 20.

It seems like the register numbering in gcc and gdb didn't agree.

Thanks Vlad!

Elena

2001-11-22  Vladimir Makarov  <vmakarov@redhat.com>
 
      * config/rs6000/tm-rs6000.h (STAB_REG_TO_REGNUM): Redefine it.
 

Index: config/rs6000/tm-rs6000.h
===================================================================
RCS file: /cvs/cvsfiles/devo/gdb/config/rs6000/tm-rs6000.h,v
retrieving revision 1.60
diff -c -p -r1.60 tm-rs6000.h
*** tm-rs6000.h 2001/05/01 19:36:54     1.60
--- tm-rs6000.h 2001/11/23 23:16:35
*************** extern void aix_process_linenos (void);
*** 88,94 ****
  
  /* convert a dbx stab register number (from `r' declaration) to a gdb
REGNUM */
  
! #define STAB_REG_TO_REGNUM(value)     (value)
  
  /* Define other aspects of the stack frame.  */
  
--- 88,101 ----
  
  /* convert a dbx stab register number (from `r' declaration) to a gdb REGNUM */
  
! #define STAB_REG_TO_REGNUM(num)  \
!  ((num) == 64                                                 \
!   ? ((TARGET_ARCHITECTURE)->mach == bfd_mach_ppc_601          \
!       ? 124 : 70)   /* mq  */                                 \
!   : (num) == 65 ? 67 /* lr  */				\
!   : (num) == 66 ? 68 /* ctr */				\
!   : (num) == 76 ? 69 /* xer */				\
!   : (num))
  
  /* Define other aspects of the stack frame.  */


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]