Supporting pthreads in libjava on Tru64 UNIX

Rainer Orth ro@TechFak.Uni-Bielefeld.DE
Fri Jul 11 18:20:00 GMT 2003


Richard Henderson writes:

> On Fri, Jul 04, 2003 at 07:20:55PM +0200, Rainer Orth wrote:
> >                               "       beq %0,3f\n"
> >                               "       mb\n"
> >                               "2:\n"
> > +#       ifdef __ELF__
> >                               ".section .text2,\"ax\"\n"
> > +#       endif
> >                               "3:     br 1b\n"
> > +#       ifdef __ELF__
> >                               ".previous"
> > +#       endif
> 
> With the ifdefing, you've created an infinite loop.

That's what you get for working late at night ;-(

> Just nuke it all and do "beq %0,1b"; ev6 machines
> have much better bracnch prediction and don't care
> so much about forward vs back branches.

I'll leave the forward branch and the section switching stuff inside
__ELF__ to avoid possible performance problems on pre-ev6 systems, as Hans
prefers.

> Alternately, if you're using gas, do ".subsection 1"
> instead of ".section .text2".

Alpha/ECOFF gas doesn't support .subsection (or any other ELF directive),
as far as I can see.  Anyway, this will have to work with the native
assembler as well, so this is not an option.

Besides, Alpha/ECOFF gas had serious problems when I tried to use it for
gcc a couple of weeks ago.  I'll defer looking into this to some later
time.

	Rainer



More information about the Java mailing list