Refactor RelocVisitor to take an object. This removes some

string comparisons and makes it a bit easier to check individual
targets.

Patch by Charlie Turner.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@219108 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Eric Christopher
2014-10-06 06:55:55 +00:00
parent b23e9d77e8
commit 7d0a297dbd
3 changed files with 116 additions and 98 deletions

View File

@@ -924,6 +924,8 @@ unsigned ELFObjectFile<ELFT>::getArch() const {
default:
report_fatal_error("Invalid ELFCLASS!");
}
case ELF::EM_PPC:
return Triple::ppc;
case ELF::EM_PPC64:
return IsLittleEndian ? Triple::ppc64le : Triple::ppc64;
case ELF::EM_S390: