mirror of
https://github.com/intel/llvm.git
synced 2026-01-26 21:53:12 +08:00
Don't apply a recolation that the dynamic linker will rewrite.
This matches the behavior of both bfd and gold. Looks like we just got here for mips because of a bad ordering of an if else chain. llvm-svn: 265147
This commit is contained in:
@@ -316,11 +316,11 @@ void InputSectionBase<ELFT>::relocate(uint8_t *Buf, uint8_t *BufEnd,
|
||||
} else if (Target->needsThunk(Type, *this->getFile(), Body)) {
|
||||
// Get address of a thunk code related to the symbol.
|
||||
SymVA = Body.getThunkVA<ELFT>();
|
||||
} else if (Config->EMachine == EM_MIPS) {
|
||||
SymVA = adjustMipsSymVA<ELFT>(Type, *File, Body, AddrLoc, SymVA);
|
||||
} else if (!Target->needsCopyRel<ELFT>(Type, Body) &&
|
||||
Body.isPreemptible()) {
|
||||
continue;
|
||||
} else if (Config->EMachine == EM_MIPS) {
|
||||
SymVA = adjustMipsSymVA<ELFT>(Type, *File, Body, AddrLoc, SymVA);
|
||||
}
|
||||
if (Target->isSizeRel(Type))
|
||||
SymVA = Body.getSize<ELFT>() + A;
|
||||
|
||||
Reference in New Issue
Block a user