Debugging symbols broken on Windows

Mikko Ronkainen mikoro at iki.fi
Fri Dec 20 05:38:56 PST 2013


Using LDC 0.12.1 binary distribution from github on Windows 8.1 
64-bit. Using the mingw recommended in the readme.

hello.d:
---
import std.stdio;

void main()
{
     writeln("Hello, World!");
     readln();
}
---

ldc2 hello.d -g
gdb hello.exe
GNU gdb (rubenvb-4.8.0) 7.5.91.20130322-cvs
Copyright (C) 2013 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later 
<http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show 
copying"
and "show warranty" for details.
This GDB was configured as "i686-w64-mingw32".
For bug reporting instructions, please see:
<mingw-w64-public at lists.sourceforge.net>...
Reading symbols from hello.exe...DW_FORM_strp pointing outside of 
.debug_str section [in module hello.exe]
(no debugging symbols found)...done.

ldc2 hello.d
gdb hello.exe
GNU gdb (rubenvb-4.8.0) 7.5.91.20130322-cvs
Copyright (C) 2013 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later 
<http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show 
copying"
and "show warranty" for details.
This GDB was configured as "i686-w64-mingw32".
For bug reporting instructions, please see:
<mingw-w64-public at lists.sourceforge.net>...
Reading symbols from hello.exe...done.


The debugging doesn't work with gdb and for example Intel vtune 
profiler crashes when trying to read the debug info. I wonder why 
gdb doesn't complain of missing debug info when omitting the -g 
flag.

On linux things seem to work fine.


More information about the digitalmars-d-ldc mailing list