[parisc-linux] Re: [glibc] tststatic failues, reduced to simp le testcase.

John David Anglin dave@hiauly3.hia.nrc.ca
Sun, 31 Aug 2003 15:10:23 -0400 (EDT)


> > I've added all the caller-saves registers to our clobber lists when
> > making syscalls. Though, r19 being special, I've had to add "STW_PIC"
> > and "LDW_PIC" that do the saving and restore _only_ if we are compiled
> > PIC.
> 
> That seems overly pessimistic and will mean a lot more register saves
> in routines that do syscalls.  It appears the system saves the caller-save
> registers in all syscalls except the fork related calls.  It would
> be best to keep the number of clobbers to a minimum.  I wonder, there
> seems to be a slot in the task struct for r1, but it's never saved in
> a syscall, and r1 is clobbered.  Maybe the r1 slot could be used to save
> r2.  This might mean that we don't need to use GR21 or GR22 at all.
> It would avoid having to have special pic code.

Another possibility might be to define another couple of offsets in the
task struct.  It looks as if there is plenty of space before an alignment
boundary is reached.