[Lldb-commits] [lldb] [lldb] Use correct size when dumping DWARF64 DW_FORM_ref_addr (PR #146686)
David Spickett via lldb-commits
lldb-commits at lists.llvm.org
Thu Jul 3 03:03:16 PDT 2025
================
@@ -416,12 +416,8 @@ void DWARFFormValue::Dump(Stream &s) const {
case DW_FORM_ref_addr: {
assert(m_unit); // Unit must be valid for DW_FORM_ref_addr objects or we
// will get this wrong
- if (m_unit->GetVersion() <= 2)
- 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
----------------
DavidSpickett wrote:
I wouldn't be surprised if it was just incorrect forever and no one has used this code in a long time. Generally dump() is used by llvm developers when debugging.
I doubt we want to add tests for this, but I put this fix in review just in case people think we should.
https://github.com/llvm/llvm-project/pull/146686
More information about the lldb-commits
mailing list