This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils 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: 64bit bfd_vma vs 32bit address space in linker


Alan Modra <amodra at bigpond dot net dot au> writes:

> On Tue, Apr 08, 2003 at 03:25:34AM -0300, Alexandre Oliva wrote:
>> On Apr  8, 2003, Alan Modra <amodra at bigpond dot net dot au> wrote:
>> 
>> > Without looking in detail at the code, I believe that bits_per_address
>> > is exactly the right thing to use to implement the (currently missing
>> > when BFD64) linker address wrap.
>> 
>> I'm afraid it isn't.  Consider 32-bit code (say o32) running on a
>> 64-bit architecture (MIPS III).  You do want to truncate addresses to
>> 32 bits, since the ABI mandates 32-bit addresses, but bits_per_address
>> will return 64.
>
> So why isn't bits_per_address == 32 if the ABI says addresses are
> 32-bit?

It is for i386/x86-64 - but where do we need to add the "currently
missing linker address wrap"?  Is this something that has to be added
for each CPU?  Or should it be added to ld?

Andreas
-- 
 Andreas Jaeger
  SuSE Labs aj at suse dot de
   private aj at arthur dot inka dot de
    http://www.suse.de/~aj


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