[PATCH v2 0/2] elf: Fix IFUNC resolvers running under ldd [BZ #34428]
Adhemerval Zanella <[email protected]> Mon, 3 Aug 2026 11:02:52 -0300
| Newsgroups | gmane.comp.lib.glibc.alpha |
|---|---|
| Message-ID | <[email protected]> |
Patch 1 fixes the BZ 34428 regression. The non-IRELATIVE pass stopped propagating skip_ifunc, on the assumption that the deferred pass handles everything that can run a resolver. That only holds for IFUNCs defined in the object being relocated; a reference to an IFUNC in another object is an ordinary JMP_SLOT/GLOB_DAT against an undefined symbol, which is triggered by ldd -u/-r. Patch 2 fixes a latent mismatch found while auditing the same split. It is not observable on any current port. Adhemerval Zanella (2): elf: Honour skip_ifunc for cross-object IFUNC relocations [BZ #34428] elf: Use the effective lazy mode for the deferred IRELATIVE pass elf/Makefile | 28 +++++++ elf/dl-reloc-static-pie.c | 12 ++- elf/dl-reloc.c | 7 +- elf/do-rel.h | 24 ++++-- elf/dynamic-link.h | 123 +++++++++++++++--------------- elf/tst-ifunc-fault-dep-bindnow.c | 19 +++++ elf/tst-ifunc-fault-dep-lazy.c | 27 +++++++ elf/tst-ifunc-fault-mod.c | 38 +++++++++ 8 files changed, 202 insertions(+), 76 deletions(-) create mode 100644 elf/tst-ifunc-fault-dep-bindnow.c create mode 100644 elf/tst-ifunc-fault-dep-lazy.c create mode 100644 elf/tst-ifunc-fault-mod.c -- 2.53.0