mirror of
https://github.com/intel/llvm.git
synced 2026-01-26 12:26:52 +08:00
Simplify. NFC.
llvm-svn: 257432
This commit is contained in:
@@ -177,10 +177,9 @@ void LinkerDriver::readConfigs(opt::InputArgList &Args) {
|
||||
Config->RPath = llvm::join(RPaths.begin(), RPaths.end(), ":");
|
||||
|
||||
if (auto *Arg = Args.getLastArg(OPT_m)) {
|
||||
// Parse ELF{32,64}{LE,BE} and CPU type.
|
||||
StringRef S = Arg->getValue();
|
||||
std::pair<ELFKind, uint16_t> P = parseEmulation(S);
|
||||
Config->EKind = P.first;
|
||||
Config->EMachine = P.second;
|
||||
std::tie(Config->EKind, Config->EMachine) = parseEmulation(S);
|
||||
Config->Emulation = S;
|
||||
}
|
||||
|
||||
|
||||
@@ -98,10 +98,7 @@ private:
|
||||
};
|
||||
} // anonymous namespace
|
||||
|
||||
template <class ELFT> static bool shouldUseRela() {
|
||||
ELFKind K = cast<ELFFileBase<ELFT>>(Config->FirstElf)->getELFKind();
|
||||
return K == ELF64LEKind || K == ELF64BEKind;
|
||||
}
|
||||
template <class ELFT> static bool shouldUseRela() { return ELFT::Is64Bits; }
|
||||
|
||||
template <class ELFT> void elf2::writeResult(SymbolTable<ELFT> *Symtab) {
|
||||
// Initialize output sections that are handled by Writer specially.
|
||||
|
||||
Reference in New Issue
Block a user