This is the mail archive of the mailing list for the glibc project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH roland/nptl-mips] MIPS: Consolidate NPTL/non versions of vfork

On Wed, 25 Jun 2014, Roland McGrath wrote:

> Not tested at all.  It looks to me like MIPS calls don't use a PLT per se,
> but always load from the GOT and then do a proper tail call via register.
> So I think the generic pt-vfork.c is safe even without IFUNC, but you tell me.
> Thanks,
> Roland
> 2014-06-25  Roland McGrath  <>
> 	* sysdeps/unix/sysv/linux/mips/clone.S: Deconditionalize the code
> 	that was previously under [RESET_PID].
> 	* sysdeps/unix/sysv/linux/mips/nptl/clone.S: File removed.

This appears to be a copy of the clone patch, not a vfork patch....

The generic pt-vfork.c gives a #error for the non-IFUNC case.  The AArch64 
version (which I now notice is returning void not pid_t, which looks 
suspicious to me) won't work for MIPS n32/n64 - for the 64-bit ABIs, gp 
($28) is callee-saved, and so the attempt at a tail call involves saving 
the caller's value and computing a new value, then restoring the old value 
of gp after the non-tail call before returning.  It might work for o32, 
but it seems simpler just to #include the alpha version for all three 

Joseph S. Myers

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]