Similar to D107861. Some tools required the GNU ABI mark to output
the symbol is a IFUNC type correctly (for instance binutils readelf).
Details
Details
- Reviewers
MaskRay joerg jrtc27 - Commits
- rGabcb3d58d999: [MC][ELF] Mark GNU ABI if ifunc are used
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
Comment Actions
The SHF_GNU_RETAIN change is more so that GNU ld recognizes its semantics, less about the readelf -s output. With many systems adopting GNU ABI features, I do not know whether it makes significant sense to "upgrade" ELFOSABI_NONE to ELFOSABI_GNU.
Comment Actions
I came up with this change mainly to make glibc configure script to detect that clang can actually use the ifunc attribute, otherwise it will use the old inline asm macros which might be subpar regarding debug information [1].
And I think this change also aligns with the recent discussion gABI where iFUNC does make the object ELFOSABI_GNU.
Comment Actions
IMO we ought to test that FreeBSD (or some other non-OS/ABI NONE case) isn't changed to GNU, similar to the test in D97976.