diff options
| author | George Rimar <grimar@accesssoftek.com> | 2016-09-30 13:46:34 +0000 |
|---|---|---|
| committer | George Rimar <grimar@accesssoftek.com> | 2016-09-30 13:46:34 +0000 |
| commit | f50bafc708d87fe526c8dd711e975eccfaaae774 (patch) | |
| tree | 69ef3ee0d2968c658d71f9a454ddc30b20783e9c /lld/ELF/InputSection.cpp | |
| parent | 3da3ffa67f7c5cca532d7f25d397dd3af6189087 (diff) | |
| download | bcm5719-llvm-f50bafc708d87fe526c8dd711e975eccfaaae774.tar.gz bcm5719-llvm-f50bafc708d87fe526c8dd711e975eccfaaae774.zip | |
[ELF] - Inlined template argument variable. NFC.
llvm-svn: 282851
Diffstat (limited to 'lld/ELF/InputSection.cpp')
| -rw-r--r-- | lld/ELF/InputSection.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/lld/ELF/InputSection.cpp b/lld/ELF/InputSection.cpp index 6e73f6ff1d0..789b4e44968 100644 --- a/lld/ELF/InputSection.cpp +++ b/lld/ELF/InputSection.cpp @@ -315,7 +315,6 @@ static typename ELFT::uint getSymVA(uint32_t Type, typename ELFT::uint A, template <class ELFT> template <class RelTy> void InputSection<ELFT>::relocateNonAlloc(uint8_t *Buf, ArrayRef<RelTy> Rels) { - const unsigned Bits = sizeof(uintX_t) * 8; for (const RelTy &Rel : Rels) { uint32_t Type = Rel.getType(Config->Mips64EL); uintX_t Offset = this->getOffset(Rel.r_offset); @@ -331,8 +330,8 @@ void InputSection<ELFT>::relocateNonAlloc(uint8_t *Buf, ArrayRef<RelTy> Rels) { } uintX_t AddrLoc = this->OutSec->getVA() + Offset; - uint64_t SymVA = - SignExtend64<Bits>(getSymVA<ELFT>(Type, Addend, AddrLoc, Sym, R_ABS)); + uint64_t SymVA = SignExtend64<sizeof(uintX_t) * 8>( + getSymVA<ELFT>(Type, Addend, AddrLoc, Sym, R_ABS)); Target->relocateOne(BufLoc, Type, SymVA); } } |

