diff options
author | Simon Atanasyan <simon@atanasyan.com> | 2016-03-11 13:57:53 +0000 |
---|---|---|
committer | Simon Atanasyan <simon@atanasyan.com> | 2016-03-11 13:57:53 +0000 |
commit | 019049fca96d85fcbd26ec2492109feb93880c41 (patch) | |
tree | d45f9815162a69b42793c0279c20a3543f7362a4 | |
parent | 5bfbc3f94122e26f5fe07e905ec31d391f2cecae (diff) | |
download | bcm5719-llvm-019049fca96d85fcbd26ec2492109feb93880c41.tar.gz bcm5719-llvm-019049fca96d85fcbd26ec2492109feb93880c41.zip |
[ELF][MIPS] Update comment about creation local GOT entries for non-local symbols. NFC.
llvm-svn: 263236
-rw-r--r-- | lld/ELF/InputSection.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/lld/ELF/InputSection.cpp b/lld/ELF/InputSection.cpp index 17bcf89d21e..746ee0ba04b 100644 --- a/lld/ELF/InputSection.cpp +++ b/lld/ELF/InputSection.cpp @@ -249,9 +249,11 @@ void InputSectionBase<ELFT>::relocate(uint8_t *Buf, uint8_t *BufEnd, AHL += SignExtend64<16>(read32<E>(LowLoc)); SymVA = Out<ELFT>::Got->getMipsLocalPageAddr(SymVA + AHL); } else { - // Under some conditions relocations against non-local symbols require - // entries in the local part of MIPS GOT. In that case we need an - // entryinitialized by full address of the symbol. + // For non-local symbols GOT entries should contain their full + // addresses. But if such symbol cannot be preempted, we do not + // have to put them into the "global" part of GOT and use dynamic + // linker to determine their actual addresses. That is why we + // create GOT entries for them in the "local" part of GOT. SymVA = Out<ELFT>::Got->getMipsLocalFullAddr(Body) + A; } } else { |