Subject: Re: PIC hacks
To: Neil A. Carson <neil@causality.com>
From: Richard Earnshaw <rearnsha@arm.com>
List: port-arm32
Date: 12/05/1998 10:12:59
> Do EGCS and ELF really work? I notice on the linux arm list they think
> this is causing another StrongARM bug to be triggered (well most of what
> he reported sounded like his consistency was just screwing up due to
> lack of a proper bus-dma thing, but there did seem to be something valid
> in the second point).
> 

Errm, how can a file format cause/trigger a processor bug?  That's an 
execution problem.  I'm not reading any of the Linux lists, so I've no 
idea what this is about; can you explain?  Anyway, I'm not convinced the 
Linux/ARM/ELF shared lib mechanism is necessarily the correct way to go: 
they have to doctor their assembly language to mark any jumps into the PLT 
(read most procedure calls).

> If so, how much work will this involve?
> 
It certainly won't be "trivial", but I can't quantify beyond that.  It 
depends on too many factors.

For example (note, this is only an example), ARM has been working on a new 
ATPCS (to replace the old APCS) which is much better suited to 
interworking between ARM and Thumb code -- ok we don't have thumb support 
in NetBSD yet, but it would be sensible to plan for it.  If we decided to 
go with that, then one variant would make all code naturally PIC, much 
like the rs6000/AIX model.  But this would probably mean rewriting a large 
amount of the .S files.  At the other end of the spectrum, we could stick 
with the current ABI, and all we might need to do is change a few 
assembler directives -- I'm not entirely sure here, since I haven't tried 
it.