Skip to content

Commit 46cb76b

Browse files
committed
Ran clang-format.
1 parent 04363ba commit 46cb76b

File tree

7 files changed

+17
-17
lines changed

7 files changed

+17
-17
lines changed

lldb/source/Plugins/SymbolFile/DWARF/DebugNamesDWARFIndex.cpp

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,6 @@ DebugNamesDWARFIndex::Create(Module &module, DWARFDataExtractor debug_names,
3535
module, std::move(index_up), debug_names, debug_str, dwarf));
3636
}
3737

38-
3938
llvm::DenseSet<uint64_t>
4039
DebugNamesDWARFIndex::GetTypeUnitSignatures(const DebugNames &debug_names) {
4140
llvm::DenseSet<uint64_t> result;
@@ -77,16 +76,17 @@ DebugNamesDWARFIndex::IsForeignTypeUnit(const DebugNames::Entry &entry) const {
7776
std::optional<uint64_t> unit_offset = entry.getForeignTUSkeletonCUOffset();
7877
if (!unit_offset)
7978
return nullptr; // Return NULL, this is a type unit, but couldn't find it.
80-
DWARFUnit *cu = m_debug_info.GetUnitAtOffset(DIERef::Section::DebugInfo,
81-
*unit_offset);
79+
DWARFUnit *cu =
80+
m_debug_info.GetUnitAtOffset(DIERef::Section::DebugInfo, *unit_offset);
8281
if (!cu)
8382
return nullptr; // Return NULL, this is a type unit, but couldn't find it.
8483
DWARFUnit &dwo_cu = cu->GetNonSkeletonUnit();
8584
// We don't need the check if the type unit matches the .dwo file if we have
8685
// a .dwo file (not a .dwp), so we can just return the value here.
8786
if (!dwo_cu.IsDWOUnit())
8887
return nullptr; // We weren't able to load the .dwo file.
89-
return dwo_cu.GetSymbolFileDWARF().DebugInfo().GetTypeUnitForHash(*type_sig);
88+
return dwo_cu.GetSymbolFileDWARF().DebugInfo().GetTypeUnitForHash(
89+
*type_sig);
9090
}
9191
// We have a .dwp file, just get the type unit from there. We need to verify
9292
// that the type unit that ended up in the final .dwp file is the right type
@@ -133,8 +133,8 @@ DebugNamesDWARFIndex::GetNonSkeletonUnit(const DebugNames::Entry &entry) const {
133133
if (!unit_offset)
134134
unit_offset = entry.getLocalTUOffset();
135135
if (unit_offset) {
136-
if (DWARFUnit *cu =
137-
m_debug_info.GetUnitAtOffset(DIERef::Section::DebugInfo, *unit_offset))
136+
if (DWARFUnit *cu = m_debug_info.GetUnitAtOffset(DIERef::Section::DebugInfo,
137+
*unit_offset))
138138
return &cu->GetNonSkeletonUnit();
139139
}
140140
return nullptr;
@@ -355,7 +355,7 @@ void DebugNamesDWARFIndex::GetFullyQualifiedType(
355355
// didn't match.
356356
std::optional<DWARFTypeUnit *> foreign_tu = IsForeignTypeUnit(entry);
357357
if (foreign_tu && foreign_tu.value() == nullptr)
358-
continue;
358+
continue;
359359

360360
// Grab at most one extra parent, subsequent parents are not necessary to
361361
// test equality.

lldb/source/Plugins/SymbolFile/DWARF/DebugNamesDWARFIndex.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,8 @@ class DebugNamesDWARFIndex : public DWARFIndex {
123123
llvm::StringRef name);
124124

125125
static llvm::DenseSet<dw_offset_t> GetUnits(const DebugNames &debug_names);
126-
static llvm::DenseSet<uint64_t> GetTypeUnitSignatures(const DebugNames &debug_names);
126+
static llvm::DenseSet<uint64_t>
127+
GetTypeUnitSignatures(const DebugNames &debug_names);
127128
};
128129

129130
} // namespace dwarf

lldb/source/Plugins/SymbolFile/DWARF/ManualDWARFIndex.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,8 @@ void ManualDWARFIndex::Index() {
6060
}
6161
if (dwp_info && dwp_info->ContainsTypeUnits()) {
6262
for (size_t U = 0; U < dwp_info->GetNumUnits(); ++U) {
63-
if (auto *tu = llvm::dyn_cast<DWARFTypeUnit>(dwp_info->GetUnitAtIndex(U))) {
63+
if (auto *tu =
64+
llvm::dyn_cast<DWARFTypeUnit>(dwp_info->GetUnitAtIndex(U))) {
6465
if (!m_type_sigs_to_avoid.contains(tu->GetTypeHash()))
6566
units_to_index.push_back(tu);
6667
}

lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1753,16 +1753,17 @@ SymbolFileDWARF *SymbolFileDWARF::GetDIERefSymbolFile(const DIERef &die_ref) {
17531753
if (file_index) {
17541754
SymbolFileDWARFDebugMap *debug_map = GetDebugMapSymfile();
17551755
if (debug_map) {
1756-
// We have a SymbolFileDWARFDebugMap, so let it find the right file
1756+
// We have a SymbolFileDWARFDebugMap, so let it find the right file
17571757
return debug_map->GetSymbolFileByOSOIndex(*file_index);
17581758
} else {
17591759
// Handle the .dwp file case correctly
17601760
if (*file_index == DIERef::k_file_index_mask)
17611761
return GetDwpSymbolFile().get(); // DWP case
17621762

17631763
// Handle the .dwo file case correctly
1764-
return DebugInfo().GetUnitAtIndex(*die_ref.file_index())
1765-
->GetDwoSymbolFile(); // DWO case
1764+
return DebugInfo()
1765+
.GetUnitAtIndex(*die_ref.file_index())
1766+
->GetDwoSymbolFile(); // DWO case
17661767
}
17671768
}
17681769
return this;

lldb/test/Shell/SymbolFile/DWARF/x86/dwp-foreign-type-units.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,6 @@
9393
// DWPFOO-NEXT: CustomType::FloatType y;
9494
// DWPFOO-NEXT: }
9595

96-
9796
// We need to do this so we end with a type unit in each .dwo file and that has
9897
// the same signature but different contents. When we make the .dwp file, then
9998
// one of the type units will end up in the .dwp file and we will have

llvm/include/llvm/DebugInfo/DWARF/DWARFAcceleratorTable.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,6 @@ class DWARFAcceleratorTable {
9090
return std::nullopt;
9191
}
9292

93-
9493
/// Returns the Tag of the Debug Info Entry associated with this
9594
/// Accelerator Entry or std::nullopt if the Tag is not recorded in this
9695
/// Accelerator Entry.

llvm/lib/DebugInfo/DWARF/DWARFAcceleratorTable.cpp

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -662,15 +662,14 @@ DWARFDebugNames::Entry::getForeignTUTypeSignature() const {
662662
std::optional<uint64_t> Index = getLocalTUIndex();
663663
const uint32_t NumLocalTUs = NameIdx->getLocalTUCount();
664664
if (!Index || *Index < NumLocalTUs)
665-
return std::nullopt; // Invalid TU index or TU index is for a local TU
665+
return std::nullopt; // Invalid TU index or TU index is for a local TU
666666
// The foreign TU index is the TU index minus the number of local TUs.
667667
const uint64_t ForeignTUIndex = *Index - NumLocalTUs;
668668
if (ForeignTUIndex >= NameIdx->getForeignTUCount())
669-
return std::nullopt; // Invalid foreign TU index.
669+
return std::nullopt; // Invalid foreign TU index.
670670
return NameIdx->getForeignTUSignature(ForeignTUIndex);
671671
}
672672

673-
674673
std::optional<uint64_t>
675674
DWARFDebugNames::Entry::getForeignTUSkeletonCUOffset() const {
676675
// Must have a DW_IDX_type_unit and it must be a foreign type unit.

0 commit comments

Comments
 (0)