From mboxrd@z Thu Jan 1 00:00:00 1970 From: Andrew Cagney To: Eli Zaretskii Cc: gdb-patches@sources.redhat.com, David B Anderson Subject: Re: [RFA] Support for GDB on SGI Irix 6.x Date: Wed, 06 Jun 2001 09:43:00 -0000 Message-id: <3B1E5DB2.90209@cygnus.com> References: <200106040813.LAA15320@is.elta.co.il> X-SW-Source: 2001-06/msg00074.html > This is a followup for > > http://sources.redhat.com/ml/gdb-patches/2001-05/msg00341.html > > where I posted a set of patches to make GDB support n32 executables on > SGI Irix. Since then, David Anderson reported that, with a minor > change in irix6.mh, GDB builds and works on SGI for him as well. > > So I would like to commit these changes (reproduced below). Any > objections? > > > 2001-06-04 Eli Zaretskii > > * config/mips/tm-irix6.h: New file. > > * config/mips/irix6.mh: New file. > > * config/mips/irix6.mt: New file. > > * config/mips/xm-irix6.h: New file. > > * config/mips/nm-irix6.h: New file. > > * mips-tdep.c (mips_gdbarch_init) : Set up the > disassembler info in tm_print_insn_info as appropriate for the N32 > ABI. Force N32 ABI to be the default if the CPU is R8000 or > R10000. > > * configure.tgt (mips*-sgi-irix6*): Map to irix6. > > * configure.host (mips*-sgi-irix6*): Ditto. > No. Andrew PS: For those that are wondering. Eli's code contains things like: > +#undef REGISTER_BYTES > +#define REGISTER_BYTES (MIPS_NUMREGS * 8 + (NUM_REGS - MIPS_NUMREGS) * MIPS_REGSIZE) > yet MIPS is ment to be multi-arch. MIPS is actually multi-arch except for the register buffer and a few other things. The MIPS register buffer hasn't been multi-arched because doing it would break GDB's remote MIPS G packet support. (Yes, this is exactly what JimB was refering to). To safely fix this, I think remote.c would need to be changed so that it allowed: o several different pre-defined G packet layouts for a single architecture o a CLI mechanism that allows the user to either select a pre-defiend G packet format _OR_ define their own custom G packet format. The latter is the key requirement. When the MIPS registers get multi-arched I think the process is 100% guarenteed to break support for GDB talking to some obscure remote MIPS target. Adding support for G packet CLI specs at lets users of such targets work around the problem. Andrew