[Lldb-commits] [lldb] [lldb] Use correct size when dumping DWARF64 DW_FORM_ref_addr (PR #146686)

via lldb-commits lldb-commits at lists.llvm.org
Wed Jul 2 06:08:30 PDT 2025


llvmbot wrote:


<!--LLVM PR SUMMARY COMMENT-->

@llvm/pr-subscribers-lldb

Author: David Spickett (DavidSpickett)

<details>
<summary>Changes</summary>

Not that we ever do that, because this is unused code, but if someone was debugging lldb I guess they'd call this.

Was missed in https://github.com/llvm/llvm-project/pull/145645

Relates to https://github.com/llvm/llvm-project/issues/135208

---
Full diff: https://github.com/llvm/llvm-project/pull/146686.diff


1 Files Affected:

- (modified) lldb/source/Plugins/SymbolFile/DWARF/DWARFFormValue.cpp (+1-2) 


``````````diff
diff --git a/lldb/source/Plugins/SymbolFile/DWARF/DWARFFormValue.cpp b/lldb/source/Plugins/SymbolFile/DWARF/DWARFFormValue.cpp
index 2e98e3c33acaf..40e2a9669e258 100644
--- a/lldb/source/Plugins/SymbolFile/DWARF/DWARFFormValue.cpp
+++ b/lldb/source/Plugins/SymbolFile/DWARF/DWARFFormValue.cpp
@@ -420,8 +420,7 @@ void DWARFFormValue::Dump(Stream &s) const {
       DumpAddress(s.AsRawOstream(), uvalue, sizeof(uint64_t) * 2);
     else
       DumpAddress(s.AsRawOstream(), uvalue,
-                  4 * 2); // 4 for DWARF32, 8 for DWARF64, but we don't
-                          // support DWARF64 yet
+                  m_unit->GetFormParams().getRefAddrByteSize());
     break;
   }
   case DW_FORM_ref1:

``````````

</details>


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


More information about the lldb-commits mailing list