D issues are now tracked on GitHub. This Bugzilla instance remains as a read-only archive.
Issue 22845 - DWARF .debug_line section is not standard compliant
Summary: DWARF .debug_line section is not standard compliant
Status: RESOLVED FIXED
Alias: None
Product: D
Classification: Unclassified
Component: dmd (show other issues)
Version: D2
Hardware: All Linux
: P1 normal
Assignee: No Owner
URL:
Keywords: pull
Depends on:
Blocks:
 
Reported: 2022-03-04 02:28 UTC by Luís Ferreira
Modified: 2022-03-04 04:38 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this issue.
Description Luís Ferreira 2022-03-04 02:28:00 UTC
GNU dwarfdump can't print .debug_line section due to bad opcodes operand:

------------------

dwarfdump ERROR:  ERROR: dwarf_srcfiles problem :  DW_DLE_LINE_NUM_OPERANDS_BAD (56). Attempting to continue.

CU Name = <unknown>
CU Producer = Digital Mars D v2.099.0-rc.1-70-g9d1fb6f6c-dirty
DIE OFF = 0x0000000b GOFF = 0x0000000b, Low PC = unknown   , High PC = unknown   

.debug_line: line number info for a single cu

dwarfdump ERROR:  dwarf_srclines:  DW_DLE_LINE_NUM_OPERANDS_BAD (56). Attempting to continue.

CU Name = <unknown>
CU Producer = Digital Mars D v2.099.0-rc.1-70-g9d1fb6f6c-dirty
DIE OFF = 0x0000000b GOFF = 0x0000000b, Low PC = unknown   , High PC = unknown   

There were 2 DWARF errors reported: see ERROR above.
Comment 1 Dlang Bot 2022-03-04 02:35:05 UTC
@ljmf00 created dlang/dmd pull request #13752 "Fix issue 22845: DWARF .debug_line section is not standard compliant" fixing this issue:

- Fix issue 22845: DWARF .debug_line section is not standard compliant
  
  According to DWARF standard, DW_LNS_set_isa standard opcode takes one operand,
  the generator is reporting 0, wrongly.
  
  Signed-off-by: Luís Ferreira <contact@lsferreira.net>

https://github.com/dlang/dmd/pull/13752
Comment 2 Dlang Bot 2022-03-04 04:38:19 UTC
dlang/dmd pull request #13752 "Fix issue 22845: DWARF .debug_line section is not standard compliant" was merged into master:

- a969b998e59ed730915f19b9d27d694304f096c1 by Luís Ferreira:
  Fix issue 22845: DWARF .debug_line section is not standard compliant
  
  According to DWARF standard, DW_LNS_set_isa standard opcode takes one operand,
  the generator is reporting 0, wrongly.
  
  Signed-off-by: Luís Ferreira <contact@lsferreira.net>

https://github.com/dlang/dmd/pull/13752