On Fri, Oct 29, 1999 at 09:47:42AM +0100, Dominic Sweetman wrote:
> I don't know Linux well enough to understand how deep its reliance on
> PIC code is - I assume that at least code-position-independence is
> essential for shared libraries. But what about data? Specifically,
> is it essential for Linux to run libraries whose static data lives at
> virtual locations which are relocated when a program is loaded?
> That's equally difficult on x86, after all.
The way shared libraries work is identical to IRIX 5. We just don't use
the extensions of IRIX ELF over MIPS ABI ELF.
> If you don't need the data relocation, MIPS-ABI is a huge overkill.
Agreed. However Linux does rather agressive copy on write as an
optimization. Without PIC code alot of addresses would have to fixed
up during loading. This would reduce the number of shared pages that
far that the total memory consumption would actually increase
significantly. Resulting from this also physically indexed caches
would loose efficiency ...
This system is clearly a special case, I wouldn't wonder if a compressed
ROMFS-like filesystem would since space seems to be more important than
performance in this case.