[PATCH] D107535: [ELF] Support copy relocation on non-default version symbols

Peter Smith via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Aug 5 10:03:48 PDT 2021


peter.smith accepted this revision.
peter.smith added a comment.
This revision is now accepted and ready to land.

I think this is worth doing as an improvement over where we are today. A quick empirical test with GNU ld by extending copy-rel-version.s with an extra non-default version and 2 separate copy-relocs to each non-default version also results in two separate copy relocations to two separate locations. So I don't think that there is likely to be a program today that relies on the addresses being identical, although there may be in the future.

IIUC if we were to fix the alias problem then we'd need to load the versym section and get the version info for each alias candidate so that we'd do find("sym at ver") rather than ("sym").


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D107535/new/

https://reviews.llvm.org/D107535



More information about the llvm-commits mailing list