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]

Re: RFA: Do solib address arithmetic with appropriate truncation


On Wed, Feb 06, 2002 at 02:28:59PM -0500, Jim Blandy wrote:
> 
> Andrew Cagney <ac131313@cygnus.com> writes:
> > Assuming a 32 bit MIPS section header and offset:
> > 
> > 0x70000000
> > 0x20000000
> > ----------
> > 0x90000000 -> 0xffffffff90000000
> 
> Okay, thanks.
> 
> Now, on such a system --- 32 bit MIPS section headers and 32-bit
> pointers --- where will a value like 0xffffffff90000000 ever actually
> appear *on the target*?  That is, why isn't this sign extension just a
> figment of GDB's imagination?

Just to provide an alternate wording of Andrew's answer - one of the
quirks of MIPS is that it can use a 32-bit data space, and a 32-bit ELF
format, and yet have 64-bit GPRs.  Another is that those 64-bit GPRs
may be usable in 64-bit mode from user programs, and may not be - and
might be readable by the stub in 64-bit mode or not.

-- 
Daniel Jacobowitz                           Carnegie Mellon University
MontaVista Software                         Debian GNU/Linux Developer


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