[PATCH] csu: Skip ARCH_SETUP_IREL if _dl_relocate_static_pie applied IRELATIVE relocations [BZ #27164]

Fangrui Song maskray@google.com
Tue Jul 13 23:06:39 GMT 2021


On 2021-07-13, Siddhesh Poyarekar wrote:
>On 7/13/21 1:36 PM, Fangrui Song via Libc-alpha wrote:
>>A toolchain project can do some workaround for a libc if this choice
>>makes a large community happy. However, I think it is important not to
>>take it granted. It is inadequate to just dismiss toolchain developers'
>>reasonable complaints. The libc should actively fix the issues so that
>>the toolchain will not need to bear unneeded code in the future.
>>
>>I actually have contributed quite a few lld/ELF patches to work around
>>glibc. For this one I just feel it is not right to just patch lld/ELF
>>without fixing glibc.
>
>What's the utility of having the __rela_iplt{_start,_end} symbols in 
>all binaries other than, maybe, simplifying the static linker 
>implementation?  How does it improve things for the generated 
>application code in the end?  AFAICT it is doing the opposite by 
>requiring application startup to add a conditional to work around the 
>presence of a redundant symbol.
>
>Siddhesh

Please see the sentence from the first message
"In addition, this enables a future simplification to GNU ld: we can
drop a linker script difference between -no-pie and -pie."

This is the only difference other than image base difference.


More information about the Libc-alpha mailing list