mirror of
https://github.com/RPCS3/llvm.git
synced 2024-12-15 16:09:57 +00:00
fix crash
fix segfault by checking for UnknownArch, since getArchTypePrefix() will return nullptr for UnknownArch. This fixes regression caused by r238424. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@239456 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
f095095d4a
commit
e11157c668
@ -519,7 +519,8 @@ void RuntimeDyldELF::resolveMIPSRelocation(const SectionEntry &Section,
|
||||
}
|
||||
|
||||
void RuntimeDyldELF::setMipsABI(const ObjectFile &Obj) {
|
||||
if (!StringRef(Triple::getArchTypePrefix(Arch)).equals("mips")) {
|
||||
if (Arch == Triple::UnknownArch ||
|
||||
!StringRef(Triple::getArchTypePrefix(Arch)).equals("mips")) {
|
||||
IsMipsO32ABI = false;
|
||||
IsMipsN64ABI = false;
|
||||
return;
|
||||
|
Loading…
Reference in New Issue
Block a user