diff options
| author | Simon Atanasyan <simon@atanasyan.com> | 2016-10-20 17:53:59 +0000 |
|---|---|---|
| committer | Simon Atanasyan <simon@atanasyan.com> | 2016-10-20 17:53:59 +0000 |
| commit | badd5b31b733febc58644d3fdbb23d1b448aeadb (patch) | |
| tree | 3c910c0615c5065251c1eed863eff5f29e4f5a5c /lld/ELF/OutputSections.cpp | |
| parent | f4415a3d77058f2714b2110276a8f40f77cca12d (diff) | |
| download | bcm5719-llvm-badd5b31b733febc58644d3fdbb23d1b448aeadb.tar.gz bcm5719-llvm-badd5b31b733febc58644d3fdbb23d1b448aeadb.zip | |
[ELF][MIPS] Use getMipsLocalEntriesNum() everywhere we need number of `local` GOT entries. NFC
llvm-svn: 284751
Diffstat (limited to 'lld/ELF/OutputSections.cpp')
| -rw-r--r-- | lld/ELF/OutputSections.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/lld/ELF/OutputSections.cpp b/lld/ELF/OutputSections.cpp index 91b89aa715c..e9546f43380 100644 --- a/lld/ELF/OutputSections.cpp +++ b/lld/ELF/OutputSections.cpp @@ -266,8 +266,7 @@ GotSection<ELFT>::getMipsGotOffset(const SymbolBody &B, uintX_t Addend) const { template <class ELFT> typename GotSection<ELFT>::uintX_t GotSection<ELFT>::getMipsTlsOffset() const { - return (MipsPageEntries + MipsLocal.size() + MipsGlobal.size()) * - sizeof(uintX_t); + return (getMipsLocalEntriesNum() + MipsGlobal.size()) * sizeof(uintX_t); } template <class ELFT> @@ -306,7 +305,7 @@ template <class ELFT> void GotSection<ELFT>::finalize() { // in the GOT entry is calculated as (value + 0x8000) & ~0xffff. MipsPageEntries += (OutSec->getSize() + 0x8000 + 0xfffe) / 0xffff; } - EntriesNum += MipsPageEntries + MipsLocal.size() + MipsGlobal.size(); + EntriesNum += getMipsLocalEntriesNum() + MipsGlobal.size(); } this->Header.sh_size = EntriesNum * sizeof(uintX_t); } |

