This is the mail archive of the libc-alpha@sourceware.org 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] S/390: Fix two issues with the IFUNC optimized mem* routines


On 08/30/2012 08:13 AM, Andreas Krebbel wrote:
>> There's no reason to *ever* drop a hidden function pointer
>> into the constant pool, since LARL is always available.
> 
> The problem was that I unfortunately missed to mark the references
> hidden in a way visible to GCC :(

Ah, well, that'll do it every time.  ;-)

All that said, it's probably reasonable have the linker transform

	lg   r1,x@got(b2)
or
	lgrl r1,x@got
into
	larl r1,x

when it finds that X has appropriate alignment and has been made
hidden via linker maps or other mechanisms not visible to the compiler.

The use of lgrl would be an enhancement to gcc for use on z10+ to
completely eliminate the got register.  Freeing up another register
definitely seems like a useful optimization.


r~


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