From b75688bde5390e943683d1c9e143b7124447b13e Mon Sep 17 00:00:00 2001 From: Igor Kudrin Date: Fri, 31 Jan 2020 17:56:15 +0700 Subject: [PATCH] [DebugInfo] Remove an unused method DWARFUnit::getDWARF5HeaderSize(). NFC. The method was initially added for DWARFVerifier::verifyUnitHeader() but its results were never actually used. Differential Revision: https://reviews.llvm.org/D73773 --- include/llvm/DebugInfo/DWARF/DWARFUnit.h | 20 -------------------- 1 file changed, 20 deletions(-) diff --git a/include/llvm/DebugInfo/DWARF/DWARFUnit.h b/include/llvm/DebugInfo/DWARF/DWARFUnit.h index b2ddb7e36b0..27c2e6ccd62 100644 --- a/include/llvm/DebugInfo/DWARF/DWARFUnit.h +++ b/include/llvm/DebugInfo/DWARF/DWARFUnit.h @@ -371,26 +371,6 @@ public: return false; } - /// Return the number of bytes for the header of a unit of - /// UnitType type. - /// - /// This function must be called with a valid unit type which in - /// DWARF5 is defined as one of the following six types. - static uint32_t getDWARF5HeaderSize(uint8_t UnitType) { - switch (UnitType) { - case dwarf::DW_UT_compile: - case dwarf::DW_UT_partial: - return 12; - case dwarf::DW_UT_skeleton: - case dwarf::DW_UT_split_compile: - return 20; - case dwarf::DW_UT_type: - case dwarf::DW_UT_split_type: - return 24; - } - llvm_unreachable("Invalid UnitType."); - } - llvm::Optional getBaseAddress(); DWARFDie getUnitDIE(bool ExtractUnitDIEOnly = true) {