[ELF][Mips] Drop an unneeded config->relocatable check

This commit is contained in:
Fangrui Song 2020-01-31 21:00:28 -08:00
parent 0130b6cb5a
commit da1973a241
1 changed files with 1 additions and 1 deletions

View File

@ -465,7 +465,7 @@ void InputSection::copyRelocations(uint8_t *buf, ArrayRef<RelTy> rels) {
if (!RelTy::IsRela)
addend = target->getImplicitAddend(bufLoc, type);
if (config->emachine == EM_MIPS && config->relocatable &&
if (config->emachine == EM_MIPS &&
target->getRelExpr(type, sym, bufLoc) == R_MIPS_GOTREL) {
// Some MIPS relocations depend on "gp" value. By default,
// this value has 0x7ff0 offset from a .got section. But