diff --git a/lldb/source/Plugins/SymbolFile/DWARF/DWARFUnit.cpp b/lldb/source/Plugins/SymbolFile/DWARF/DWARFUnit.cpp index 5d839c40fd3f..ef3d2cf4d550 100644 --- a/lldb/source/Plugins/SymbolFile/DWARF/DWARFUnit.cpp +++ b/lldb/source/Plugins/SymbolFile/DWARF/DWARFUnit.cpp @@ -288,7 +288,7 @@ void DWARFUnit::SetAddrBase(dw_addr_t addr_base, m_base_obj_offset = base_obj_offset; } -void DWARFUnit::ClearDIEs(bool keep_compile_unit_die) { +void DWARFUnit::ClearDIEs() { if (m_die_array.size() > 1) { // std::vectors never get any smaller when resized to a smaller size, or // when clear() or erase() are called, the size will report that it is @@ -300,12 +300,11 @@ void DWARFUnit::ClearDIEs(bool keep_compile_unit_die) { // Save at least the compile unit DIE DWARFDebugInfoEntry::collection tmp_array; m_die_array.swap(tmp_array); - if (keep_compile_unit_die) - m_die_array.push_back(tmp_array.front()); + m_die_array.push_back(tmp_array.front()); } if (m_dwo_symbol_file) - m_dwo_symbol_file->GetCompileUnit()->ClearDIEs(keep_compile_unit_die); + m_dwo_symbol_file->GetCompileUnit()->ClearDIEs(); } void DWARFUnit::BuildAddressRangeTable(SymbolFileDWARF *dwarf, @@ -403,7 +402,7 @@ void DWARFUnit::BuildAddressRangeTable(SymbolFileDWARF *dwarf, // Keep memory down by clearing DIEs if this generate function caused them to // be parsed if (clear_dies) - ClearDIEs(true); + ClearDIEs(); } lldb::ByteOrder DWARFUnit::GetByteOrder() const { diff --git a/lldb/source/Plugins/SymbolFile/DWARF/DWARFUnit.h b/lldb/source/Plugins/SymbolFile/DWARF/DWARFUnit.h index 322e4fcda059..5a8932cfa70f 100644 --- a/lldb/source/Plugins/SymbolFile/DWARF/DWARFUnit.h +++ b/lldb/source/Plugins/SymbolFile/DWARF/DWARFUnit.h @@ -99,7 +99,7 @@ public: dw_addr_t GetRangesBase() const { return m_ranges_base; } void SetAddrBase(dw_addr_t addr_base, dw_addr_t ranges_base, dw_offset_t base_obj_offset); - void ClearDIEs(bool keep_compile_unit_die); + void ClearDIEs(); void BuildAddressRangeTable(SymbolFileDWARF *dwarf, DWARFDebugAranges *debug_aranges); diff --git a/lldb/source/Plugins/SymbolFile/DWARF/ManualDWARFIndex.cpp b/lldb/source/Plugins/SymbolFile/DWARF/ManualDWARFIndex.cpp index 719478537ac1..b089b0ddeae5 100644 --- a/lldb/source/Plugins/SymbolFile/DWARF/ManualDWARFIndex.cpp +++ b/lldb/source/Plugins/SymbolFile/DWARF/ManualDWARFIndex.cpp @@ -96,7 +96,7 @@ void ManualDWARFIndex::Index() { //---------------------------------------------------------------------- for (uint32_t cu_idx = 0; cu_idx < num_compile_units; ++cu_idx) { if (clear_cu_dies[cu_idx]) - debug_info.GetCompileUnitAtIndex(cu_idx)->ClearDIEs(true); + debug_info.GetCompileUnitAtIndex(cu_idx)->ClearDIEs(); } }