mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-23 17:24:48 +00:00
[Object][Mips] Return address of MIPS symbol with cleared microMIPS indicator bit
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@222726 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -280,8 +280,9 @@ std::error_code ELFObjectFile<ELFT>::getSymbolAddress(DataRefImpl Symb,
|
||||
const Elf_Ehdr *Header = EF.getHeader();
|
||||
Result = ESym->st_value;
|
||||
|
||||
// Clear the ARM/Thumb indicator flag.
|
||||
if (Header->e_machine == ELF::EM_ARM && ESym->getType() == ELF::STT_FUNC)
|
||||
// Clear the ARM/Thumb or microMIPS indicator flag.
|
||||
if ((Header->e_machine == ELF::EM_ARM || Header->e_machine == ELF::EM_MIPS) &&
|
||||
ESym->getType() == ELF::STT_FUNC)
|
||||
Result &= ~1;
|
||||
|
||||
if (Header->e_type == ELF::ET_REL)
|
||||
|
Reference in New Issue
Block a user