[lld] r297953 - [ELF] - Rename Config->Is64Bit() to is64(). NFC.
George Rimar via llvm-commits
llvm-commits at lists.llvm.org
Thu Mar 16 06:41:30 PDT 2017
Author: grimar
Date: Thu Mar 16 08:41:29 2017
New Revision: 297953
URL: http://llvm.org/viewvc/llvm-project?rev=297953&view=rev
Log:
[ELF] - Rename Config->Is64Bit() to is64(). NFC.
Addresses post commit review comment.
Modified:
lld/trunk/ELF/Config.h
lld/trunk/ELF/SyntheticSections.cpp
lld/trunk/ELF/SyntheticSections.h
Modified: lld/trunk/ELF/Config.h
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/ELF/Config.h?rev=297953&r1=297952&r2=297953&view=diff
==============================================================================
--- lld/trunk/ELF/Config.h (original)
+++ lld/trunk/ELF/Config.h Thu Mar 16 08:41:29 2017
@@ -163,7 +163,7 @@ struct Configuration {
unsigned ThinLTOJobs;
// Returns true if target is 64 bit.
- bool is64Bit() const { return EKind == ELF64LEKind || EKind == ELF64BEKind; }
+ bool is64() const { return EKind == ELF64LEKind || EKind == ELF64BEKind; }
// The ELF spec defines two types of relocation table entries, RELA and
// REL. RELA is a triplet of (offset, info, addend) while REL is a
@@ -181,7 +181,7 @@ struct Configuration {
// are using RELA too.
bool isRela() const {
bool IsX32Abi = (EKind == ELF32LEKind && EMachine == llvm::ELF::EM_X86_64);
- return is64Bit() || IsX32Abi || MipsN32Abi;
+ return is64() || IsX32Abi || MipsN32Abi;
}
// Returns true if we need to pass through relocations in input
Modified: lld/trunk/ELF/SyntheticSections.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/ELF/SyntheticSections.cpp?rev=297953&r1=297952&r2=297953&view=diff
==============================================================================
--- lld/trunk/ELF/SyntheticSections.cpp (original)
+++ lld/trunk/ELF/SyntheticSections.cpp Thu Mar 16 08:41:29 2017
@@ -957,7 +957,7 @@ void GotPltSection::writeTo(uint8_t *Buf
Buf += Target->GotPltHeaderEntriesNum * Target->GotPltEntrySize;
for (const SymbolBody *B : Entries) {
Target->writeGotPlt(Buf, *B);
- Buf += Config->is64Bit() ? 8 : 4;
+ Buf += Config->is64() ? 8 : 4;
}
}
@@ -981,7 +981,7 @@ size_t IgotPltSection::getSize() const {
void IgotPltSection::writeTo(uint8_t *Buf) {
for (const SymbolBody *B : Entries) {
Target->writeIgotPlt(Buf, *B);
- Buf += Config->is64Bit() ? 8 : 4;
+ Buf += Config->is64() ? 8 : 4;
}
}
@@ -2204,7 +2204,7 @@ size_t MergeSyntheticSection::getSize()
MipsRldMapSection::MipsRldMapSection()
: SyntheticSection(SHF_ALLOC | SHF_WRITE, SHT_PROGBITS,
- Config->is64Bit() ? 8 : 4, ".rld_map") {}
+ Config->is64() ? 8 : 4, ".rld_map") {}
void MipsRldMapSection::writeTo(uint8_t *Buf) {
// Apply filler from linker script.
@@ -2236,7 +2236,7 @@ void ARMExidxSentinelSection<ELFT>::writ
ThunkSection::ThunkSection(OutputSection *OS, uint64_t Off)
: SyntheticSection(SHF_ALLOC | SHF_EXECINSTR, SHT_PROGBITS,
- Config->is64Bit() ? 8 : 4, ".text.thunk") {
+ Config->is64() ? 8 : 4, ".text.thunk") {
this->OutSec = OS;
this->OutSecOff = Off;
}
Modified: lld/trunk/ELF/SyntheticSections.h
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/ELF/SyntheticSections.h?rev=297953&r1=297952&r2=297953&view=diff
==============================================================================
--- lld/trunk/ELF/SyntheticSections.h (original)
+++ lld/trunk/ELF/SyntheticSections.h Thu Mar 16 08:41:29 2017
@@ -712,7 +712,7 @@ private:
class MipsRldMapSection : public SyntheticSection {
public:
MipsRldMapSection();
- size_t getSize() const override { return Config->is64Bit() ? 8 : 4; }
+ size_t getSize() const override { return Config->is64() ? 8 : 4; }
void writeTo(uint8_t *Buf) override;
};
More information about the llvm-commits
mailing list