[Lldb-commits] [lldb] [lldb][DWARF64] Enable support for DWARF64 format handling (PR #145645)

Michael Buch via lldb-commits lldb-commits at lists.llvm.org
Wed Jun 25 03:22:05 PDT 2025


================
@@ -121,8 +124,12 @@ bool DWARFFormValue::ExtractValue(const DWARFDataExtractor &data,
       assert(m_unit);
       if (m_unit->GetVersion() <= 2)
         ref_addr_size = m_unit->GetAddressByteSize();
-      else
-        ref_addr_size = 4;
+      else {
+        if (m_unit->GetFormat() == DwarfFormat::DWARF32)
+          ref_addr_size = 4;
+        else if (m_unit->GetFormat() == DwarfFormat::DWARF64)
+          ref_addr_size = 8;
+      }
----------------
Michael137 wrote:

Can't we just always use `m_unit->GetAddressByteSize`?

https://github.com/llvm/llvm-project/pull/145645


More information about the lldb-commits mailing list