Re: [PATCH v2 2/2] compiler-gcc: Remove obsolete RELOC_HIDE() macro
From: Linus Torvalds
Date: Fri Sep 04 2026 - 11:30:06 EST
On Fri, 4 Sept 2026 at 01:28, Uros Bizjak <ubizjak@xxxxxxxxx> wrote:
>
> The GCC specific macro was historically used to workaround very
> old compiler bugs (including pre-4.1 ppc64 GCC). These compilers
> are now long obsolete.
The gcc-4.1 bug in that comment was about how the use of "=g" caused
ppc code generation issues.
It's not entirely clear to me that the original reason for this macro
is actually gone. The cast to 'long' has not always hidden the
provenance of the address.
The use of inline asm in RELOC_HIDE() actually goes back much much further.
I do agree that it probably is no longer relevant, but that commit
message is actively misleading. RELOC_HIDE() itself has nothing to do
with the ppc64-specific gcc bug, that was literally just a small
indepdendent change to the implementation.
Linus