[lld] [ELF] --pack-dyn-relocs=android: place IRELATIVE in .rela.dyn (PR #86751)

Fangrui Song via llvm-commits llvm-commits at lists.llvm.org
Tue Mar 26 17:15:45 PDT 2024


================
@@ -1659,10 +1659,16 @@ static bool handleNonPreemptibleIfunc(Symbol &sym, uint16_t flags) {
   // original section/value pairs. For non-GOT non-PLT relocation case below, we
   // may alter section/value, so create a copy of the symbol to make
   // section/value fixed.
+  //
+  // Prior to Android V, there was a bug that caused RELR relocations to be
+  // applied after packed relocations. This meant that resolvers referenced
+  // IRELATIVE relocations in the packed relocation section could not read
----------------
MaskRay wrote:

Oh, I am confused by the sentence "... would have been able to read globals with RELR relocations before they were relocated".

Isn't it "could not ... " because RELR relocations have been applied yet?

https://github.com/llvm/llvm-project/pull/86751


More information about the llvm-commits mailing list