mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-22 10:42:39 +01:00
[DWARFYAML] Rename getUsedSectionNames() to getNonEmptySectionNames().
This patch renames getUsedSectionNames() to getNonEmptySectionNames. NFC.
This commit is contained in:
parent
57ae573dba
commit
33fdabb077
@ -225,7 +225,7 @@ struct Data {
|
||||
|
||||
bool isEmpty() const;
|
||||
|
||||
SetVector<StringRef> getUsedSectionNames() const;
|
||||
SetVector<StringRef> getNonEmptySectionNames() const;
|
||||
};
|
||||
|
||||
} // end namespace DWARFYAML
|
||||
|
@ -22,7 +22,7 @@ bool DWARFYAML::Data::isEmpty() const {
|
||||
!GNUPubTypes && CompileUnits.empty() && DebugLines.empty();
|
||||
}
|
||||
|
||||
SetVector<StringRef> DWARFYAML::Data::getUsedSectionNames() const {
|
||||
SetVector<StringRef> DWARFYAML::Data::getNonEmptySectionNames() const {
|
||||
SetVector<StringRef> SecNames;
|
||||
if (!DebugStrings.empty())
|
||||
SecNames.insert("debug_str");
|
||||
|
@ -355,7 +355,7 @@ ELFState<ELFT>::ELFState(ELFYAML::Object &D, yaml::ErrorHandler EH)
|
||||
if (Doc.Symbols)
|
||||
ImplicitSections.push_back(".symtab");
|
||||
if (Doc.DWARF)
|
||||
for (StringRef DebugSecName : Doc.DWARF->getUsedSectionNames()) {
|
||||
for (StringRef DebugSecName : Doc.DWARF->getNonEmptySectionNames()) {
|
||||
std::string SecName = ("." + DebugSecName).str();
|
||||
ImplicitSections.push_back(StringRef(SecName).copy(StringAlloc));
|
||||
}
|
||||
@ -931,7 +931,7 @@ void ELFState<ELFT>::initStrtabSectionHeader(Elf_Shdr &SHeader, StringRef Name,
|
||||
}
|
||||
|
||||
static bool shouldEmitDWARF(DWARFYAML::Data &DWARF, StringRef Name) {
|
||||
SetVector<StringRef> DebugSecNames = DWARF.getUsedSectionNames();
|
||||
SetVector<StringRef> DebugSecNames = DWARF.getNonEmptySectionNames();
|
||||
return Name.consume_front(".") && DebugSecNames.count(Name);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user