[llvm] 6e73f12 - Fix buildbots errors after comitting D78782.
Greg Clayton via llvm-commits
llvm-commits at lists.llvm.org
Wed May 13 22:03:05 PDT 2020
Author: Greg Clayton
Date: 2020-05-13T22:01:57-07:00
New Revision: 6e73f12a641bb8fd965d28937ea3a6d1dcecc8c0
URL: https://github.com/llvm/llvm-project/commit/6e73f12a641bb8fd965d28937ea3a6d1dcecc8c0
DIFF: https://github.com/llvm/llvm-project/commit/6e73f12a641bb8fd965d28937ea3a6d1dcecc8c0.diff
LOG: Fix buildbots errors after comitting D78782.
Rename "Ranges" variables to "DebugRanges" to avoid warnings/errors on machines that have extra settings enabled.
https://reviews.llvm.org/D78782
Added:
Modified:
llvm/include/llvm/ObjectYAML/DWARFYAML.h
llvm/lib/ObjectYAML/DWARFEmitter.cpp
llvm/lib/ObjectYAML/DWARFYAML.cpp
llvm/tools/obj2yaml/dwarf2yaml.cpp
Removed:
################################################################################
diff --git a/llvm/include/llvm/ObjectYAML/DWARFYAML.h b/llvm/include/llvm/ObjectYAML/DWARFYAML.h
index 3c87a5f0c499..8049d4911b86 100644
--- a/llvm/include/llvm/ObjectYAML/DWARFYAML.h
+++ b/llvm/include/llvm/ObjectYAML/DWARFYAML.h
@@ -159,7 +159,7 @@ struct Data {
std::vector<Abbrev> AbbrevDecls;
std::vector<StringRef> DebugStrings;
std::vector<ARange> ARanges;
- std::vector<Ranges> Ranges;
+ std::vector<Ranges> DebugRanges;
PubSection PubNames;
PubSection PubTypes;
diff --git a/llvm/lib/ObjectYAML/DWARFEmitter.cpp b/llvm/lib/ObjectYAML/DWARFEmitter.cpp
index 645558d9ddd0..a04f3c8f08d0 100644
--- a/llvm/lib/ObjectYAML/DWARFEmitter.cpp
+++ b/llvm/lib/ObjectYAML/DWARFEmitter.cpp
@@ -116,18 +116,18 @@ void DWARFYAML::EmitDebugAranges(raw_ostream &OS, const DWARFYAML::Data &DI) {
void DWARFYAML::EmitDebugRanges(raw_ostream &OS, const DWARFYAML::Data &DI) {
const size_t RangesOffset = OS.tell();
- for (auto Ranges : DI.Ranges) {
+ for (auto DebugRanges : DI.DebugRanges) {
const size_t CurrOffset = OS.tell() - RangesOffset;
- assert(Ranges.Offset <= CurrOffset);
- if (Ranges.Offset > CurrOffset)
- ZeroFillBytes(OS, Ranges.Offset - CurrOffset);
- for (auto Entry : Ranges.Entries) {
- writeVariableSizedInteger(Entry.LowOffset, Ranges.AddrSize, OS,
+ assert(DebugRanges.Offset <= CurrOffset);
+ if (DebugRanges.Offset > CurrOffset)
+ ZeroFillBytes(OS, DebugRanges.Offset - CurrOffset);
+ for (auto Entry : DebugRanges.Entries) {
+ writeVariableSizedInteger(Entry.LowOffset, DebugRanges.AddrSize, OS,
DI.IsLittleEndian);
- writeVariableSizedInteger(Entry.HighOffset, Ranges.AddrSize, OS,
+ writeVariableSizedInteger(Entry.HighOffset, DebugRanges.AddrSize, OS,
DI.IsLittleEndian);
}
- ZeroFillBytes(OS, Ranges.AddrSize * 2);
+ ZeroFillBytes(OS, DebugRanges.AddrSize * 2);
}
}
diff --git a/llvm/lib/ObjectYAML/DWARFYAML.cpp b/llvm/lib/ObjectYAML/DWARFYAML.cpp
index 82033b4f90c6..cff8c2b3359b 100644
--- a/llvm/lib/ObjectYAML/DWARFYAML.cpp
+++ b/llvm/lib/ObjectYAML/DWARFYAML.cpp
@@ -28,8 +28,8 @@ void MappingTraits<DWARFYAML::Data>::mapping(IO &IO, DWARFYAML::Data &DWARF) {
IO.mapOptional("debug_abbrev", DWARF.AbbrevDecls);
if (!DWARF.ARanges.empty() || !IO.outputting())
IO.mapOptional("debug_aranges", DWARF.ARanges);
- if (!DWARF.Ranges.empty() || !IO.outputting())
- IO.mapOptional("debug_ranges", DWARF.Ranges);
+ if (!DWARF.DebugRanges.empty() || !IO.outputting())
+ IO.mapOptional("debug_ranges", DWARF.DebugRanges);
if (!DWARF.PubNames.Entries.empty() || !IO.outputting())
IO.mapOptional("debug_pubnames", DWARF.PubNames);
if (!DWARF.PubTypes.Entries.empty() || !IO.outputting())
@@ -82,10 +82,10 @@ void MappingTraits<DWARFYAML::RangeEntry>::mapping(
}
void MappingTraits<DWARFYAML::Ranges>::mapping(IO &IO,
- DWARFYAML::Ranges &Ranges) {
- IO.mapRequired("Offset", Ranges.Offset);
- IO.mapRequired("AddrSize", Ranges.AddrSize);
- IO.mapRequired("Entries", Ranges.Entries);
+ DWARFYAML::Ranges &DebugRanges) {
+ IO.mapRequired("Offset", DebugRanges.Offset);
+ IO.mapRequired("AddrSize", DebugRanges.AddrSize);
+ IO.mapRequired("Entries", DebugRanges.Entries);
}
void MappingTraits<DWARFYAML::PubEntry>::mapping(IO &IO,
diff --git a/llvm/tools/obj2yaml/dwarf2yaml.cpp b/llvm/tools/obj2yaml/dwarf2yaml.cpp
index df876853fd31..a007efe7e507 100644
--- a/llvm/tools/obj2yaml/dwarf2yaml.cpp
+++ b/llvm/tools/obj2yaml/dwarf2yaml.cpp
@@ -109,7 +109,7 @@ Error dumpDebugRanges(DWARFContext &DCtx, DWARFYAML::Data &Y) {
return E;
for (const auto &RLE : DwarfRanges.getEntries())
YamlRanges.Entries.push_back({RLE.StartAddress, RLE.EndAddress});
- Y.Ranges.push_back(std::move(YamlRanges));
+ Y.DebugRanges.push_back(std::move(YamlRanges));
}
return ErrorSuccess();
}
More information about the llvm-commits
mailing list