[PATCH] D39493: [ELF] Fix DT_MIPS_LOCAL_GOTNO value when using linker scripts to change section sizes

Simon Atanasyan via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Nov 9 02:35:19 PST 2017


atanasyan added inline comments.


================
Comment at: ELF/SyntheticSections.cpp:1189
     case Entry::PlainInt:
-      P->d_un.d_val = E.Val;
+      if (E.Tag == DT_MIPS_LOCAL_GOTNO)
+        P->d_un.d_val = InX::MipsGot->getLocalEntriesNum();
----------------
Other targets might have dynamic table tags with the same value so we have to check `Config->EMachine == EM_MIPS` here.


https://reviews.llvm.org/D39493





More information about the llvm-commits mailing list