Comment #0 by lucien.perregaux — 2020-08-13T14:59:42Z
Actually, DMD emits the module's tag, but it has no childrens and no references to it.
Also, the attribute DW_AT_name of the childrens shouldn't contain the module name as a prefix
program:
---
module bar;
void main()
{
bar();
}
void bar()
{
}
---
Emitted by DMD:
---
0x00000076: DW_TAG_module
DW_AT_name ("bar")
0x000000a2: DW_TAG_subprogram
DW_AT_name ("bar.bar")
DW_AT_MIPS_linkage_name ("_D3barQeFZv")
DW_AT_decl_file ("src/main.d")
DW_AT_decl_line (9)
DW_AT_external (0x01)
DW_AT_low_pc (0x000000000003f6ac)
DW_AT_high_pc (0x000000000003f6b2)
DW_AT_frame_base (0x0000004c:
[0x000000000003f6ac, 0x000000000003f6ad): DW_OP_breg7 RSP+8
[0x000000000003f6ad, 0x000000000003f6af): DW_OP_breg7 RSP+16
[0x000000000003f6af, 0x000000000003f6b2): DW_OP_breg6 RBP+16)
---
Comment #1 by dlang-bot — 2020-08-20T13:02:35Z
@Luhrel created dlang/dmd pull request #11599 "Fix Issue 21155 - DWARF: symbols within a module are not children of …" fixing this issue:
- Fix Issue 21155 - DWARF: symbols within a module are not children of DW_TAG_module
https://github.com/dlang/dmd/pull/11599
Comment #2 by robert.schadek — 2024-12-13T19:10:59Z