Subject: Re: LITERALSLEAZY .lita
To: John Birrell <jb@cimlogic.com.au>
From: Chris G Demetriou <Chris_G_Demetriou@ux2.sp.cs.cmu.edu>
List: port-alpha
Date: 10/19/1996 01:55:55
> Arrrgh! So much for building a massively threaded application. So 
> much for a you-beaut-64-bit-processor. All that address space, but
> only 64k rungs in the ladder to get you there.

really only 8k rungs, since your average, uh, foot? is 8 units tall...
8-)

yeah, this is a lose.


> I already ran up against this with DEC's OSF/1 linker when I tried
> to link just part of this same software for VxWorks/Alpha (which
> *must* be linked as a single program). DEC's response was "tough".
> There turned out to be a work around in that case - VxWorks can
> dynamically load modules and their module handling doesn't suffer
> from the same limitation.

So, at least Richard Henderson (the guy who did ELF support for the
Alpha) realizes that the 64k GOT limit is a problem, and feels guilty
about not fixing it yet.  8-)


> > moving to ELF helps this slightly, but there's still a limit in the
> > hopefully, that'll be fixed.
> 
> Hmm. When will your ELF stuff be available? I feel the need to hack...

*sigh*  This is a good question.


The remaining details right now:

	(1) getting weak symbols into libc (J.T. only has .S files
	    left to do, apparently...)

	(2) importing the ELF ld.so.

	(3) getting a toolchain that works.

(1) and (2) could be taken care of quickly.

(3) is harder.  Not only have the relevant bits of code (gcc and
binutils, mostly) changed drastically since their last releases.
While i've got diffs to released various tools, there are still
serious outstanding bugs in binutils that keep the system from
working in a reasonable manner, depending on what flags, etc. you
use with various toolchain commands.

I'd like to get (3) resolved soon, but it's more or less out of my
hands.


As far as I know, all system bugs relating to ELF are gone.  (I
certainly killed a lot of them.  8-)  When i can actually build
binaries that work, they work great.  the problem is a fluctuating bug
set in the toolchain.  8-(


Anyway, the answer to this is "as soon as I can" -- i'd like to get
something out before I go to OSDI at the end of this month, but i
can't say for sure.


> Will shared libraries under ELF help me?

I don't know for sure.  Logically, they should help at least a little.

If i understand correctly, shared libraries have their own GOT
segment, and therefore library GOT entries wouldn't end up in the
program's GOT.  Certainly, the program could still get entries because
of calls to library routines, but those might go into a different
segment.  (i'm not sure how all these things map out.)

What that actually would get you, i don't know.

Apparently (from comments that Richard has made) ELF is smarter about
its use of GP-relative data to begin with, so that should help some.


chris