ret value of bfd_get_sign_extend_vma

Dave Korn dk@artimi.com
Tue Jun 22 09:23:00 GMT 2004


> -----Original Message-----
> From: Michael Mueller  
> Sent: 22 June 2004 08:33

> > bits.  So on these systems, 16-bit addresses 0x0000 to 
> 0x7fff address 32-bit
> > range 0x00000000 to 0x00007fff, and 16-bit addresses 0x8000 
> to 0xffff
> > address 32-bit range 0xffff8000 to 0xffffffff.
> 
> So that means that if I access a 16 bit range from 0x7ff0 to 0x8010 I 
> access two noncontiguous pieces of memory. Funny.

  Well, you can't access a 16 byte range with a single instruction.  Each
word address you load from will be in either one range or the other.
There's just a boundary in there.  It's no funnier than the fact that if
you're using a signed 16-bit integer and you increment the positive number
32767 you get the negative number -32768; in fact it's exactly the same!
 
> But bfd_get_sign_extend_vma returns 0 on m68k doesn't it?

  I haven't actually checked; maybe that port handles the issue using some
different mechanism.



    cheers, 
      DaveK
-- 
Can't think of a witty .sigline today....



More information about the Binutils mailing list