digitalmars.D - Discussion on D support in gdb
- Andrei Alexandrescu (3/3) Nov 21 2011 Maybe someone knowledgeable could chime in:
- Trass3r (2/2) Nov 22 2011 It's basically about this:
- mta`chrono (3/3) Nov 22 2011 A noob question from my side: What is DWARF?
- Jacob Carlborg (5/8) Nov 22 2011 It's a standardized debugging data format.
- Denis Shelomovskij (2/5) Nov 22 2011 http://lmgtfy.com/?q=gdb+DWARF&l=1
- Dejan Lekic (2/3) Nov 22 2011 http://dwarfstd.org/
- Martin Nowak (29/32) Nov 22 2011 I think we should follow Tom Tromney's proposal to add the extensions
- Jacob Carlborg (4/5) Nov 22 2011 The LLBD debugger: http://lldb.llvm.org/
- bioinfornatics (2/7) Nov 22 2011 LLDB seem to be great but is OSX only ;'(
- Jacob Carlborg (5/12) Nov 22 2011 I'm certain it will be available on other platforms as well. This page
- Timon Gehr (2/14) Nov 22 2011 Practically everything you can licence is a number.
- Roald Ribe (9/10) Nov 23 2011 Depends on what "taking into account" means in this context.
- Jacob Carlborg (5/15) Nov 23 2011 For Mac OS X it would probably need support for the Mach-O file format,
- Walter Bright (5/20) Nov 24 2011 Because it is presumably harder to get a debugger to recognize a magic s...
- Jerry (4/21) Nov 25 2011 Huh, I swore I had already filed a bug regarding the AA ABI.
- Martin Nowak (14/42) Nov 28 2011 Dwarf-4 supports arbitrary expressions for array base addresses and the ...
- Kagamin (2/4) Nov 24 2011 Yeah, why use extensible debug info format and not use the extensibility...
- Jerry (20/46) Nov 25 2011 I've done a bit of reading on this issue, at least with regards to D
Maybe someone knowledgeable could chime in: http://sourceware.org/ml/gdb/2011-11/msg00066.html Andrei
Nov 21 2011
It's basically about this: http://d.puremagic.com/issues/show_bug.cgi?id=4180
Nov 22 2011
A noob question from my side: What is DWARF? By the way I never touched the sources of gdb. I'm just a friendly user of it.
Nov 22 2011
On 2011-11-22 13:13, mta`chrono wrote:A noob question from my side: What is DWARF? By the way I never touched the sources of gdb. I'm just a friendly user of it.It's a standardized debugging data format. http://en.wikipedia.org/wiki/DWARF -- /Jacob Carlborg
Nov 22 2011
22.11.2011 15:13, mta`chrono пишет:A noob question from my side: What is DWARF? By the way I never touched the sources of gdb. I'm just a friendly user of it.http://lmgtfy.com/?q=gdb+DWARF&l=1
Nov 22 2011
mta`chrono wrote:A noob question from my side: What is DWARF?http://dwarfstd.org/
Nov 22 2011
On Tue, 22 Nov 2011 04:18:47 +0100, Andrei Alexandrescu <SeeWebsiteForEmail erdani.org> wrote:Maybe someone knowledgeable could chime in: http://sourceware.org/ml/gdb/2011-11/msg00066.html AndreiI think we should follow Tom Tromney's proposal to add the extensions under the GNU vendor space, i.e. prefix them with 0x41xx. Numbers hopefully don't fall under licensing issues. It should be fairly straightforward to improve gdb debugging support given that changes are accepted on either side. The GDB codebase is a slightly unfriendly environment but getting rid of 'p ((char*[2])str)[1]' would be great. I would volunteer to do the implementation but it would be great if someone helped with clarifying the following issues. - Can we slowly start to acquire DWARF-3/4? - Why were extensions chosen over say representing an array as two field struct? - There is this request by Robert Clipsham http://dwarfstd.org/ShowIssue.php?issue=100504.1. What's the state of this, it wouldn't be needed any longer. - We should contact http://www.zero-bugs.com, it is said to support the dwarf extensions and would need to be changed. - Find out who else is affected by changing the current extensions. - Fixing the D-ABI specification. - Are there other DWARF debuggers that we should take into account? - Adding a page to GNU wiki describing the D extensions. - We could probably use DW_TAG_GNU_template_parameter_pack for variadic template arguments. http://wiki.dwarfstd.org/index.php?title=C%2B%2B0x:_Variadic_templates martin
Nov 22 2011
On 2011-11-22 16:19, Martin Nowak wrote:- Are there other DWARF debuggers that we should take into account?The LLBD debugger: http://lldb.llvm.org/ -- /Jacob Carlborg
Nov 22 2011
Le mardi 22 novembre 2011 =C3=A0 16:27 +0100, Jacob Carlborg a =C3=A9crit :On 2011-11-22 16:19, Martin Nowak wrote:LLDB seem to be great but is OSX only ;'(- Are there other DWARF debuggers that we should take into account?=20 The LLBD debugger: http://lldb.llvm.org/ =20
Nov 22 2011
On 2011-11-22 21:04, bioinfornatics wrote:Le mardi 22 novembre 2011 à 16:27 +0100, Jacob Carlborg a écrit :I'm certain it will be available on other platforms as well. This page mentions something about Linux: http://lldb.llvm.org/build.html -- /Jacob CarlborgOn 2011-11-22 16:19, Martin Nowak wrote:LLDB seem to be great but is OSX only ;'(- Are there other DWARF debuggers that we should take into account?The LLBD debugger: http://lldb.llvm.org/
Nov 22 2011
On 11/22/2011 04:19 PM, Martin Nowak wrote:On Tue, 22 Nov 2011 04:18:47 +0100, Andrei Alexandrescu <SeeWebsiteForEmail erdani.org> wrote:Practically everything you can licence is a number.Maybe someone knowledgeable could chime in: http://sourceware.org/ml/gdb/2011-11/msg00066.html AndreiI think we should follow Tom Tromney's proposal to add the extensions under the GNU vendor space, i.e. prefix them with 0x41xx. Numbers hopefully don't fall under licensing issues.
Nov 22 2011
On Tue, 22 Nov 2011 12:19:00 -0300, Martin Nowak <dawg dawgfoto.de> wrote:- Are there other DWARF debuggers that we should take into account?Depends on what "taking into account" means in this context. The OpenWatcom debugger (wd/wdw) supports DWARF-2, and is released for WIN32, OS/2 and Linux (wd only). It (wd) probably compiles on BSD and OS/X as well. wd is the full screen character based version. wdw is the gui version. http://www.openwatcom.org Roald
Nov 23 2011
On 2011-11-23 13:24, Roald Ribe wrote:On Tue, 22 Nov 2011 12:19:00 -0300, Martin Nowak <dawg dawgfoto.de> wrote:For Mac OS X it would probably need support for the Mach-O file format, if it already isn't supported. -- /Jacob Carlborg- Are there other DWARF debuggers that we should take into account?Depends on what "taking into account" means in this context. The OpenWatcom debugger (wd/wdw) supports DWARF-2, and is released for WIN32, OS/2 and Linux (wd only). It (wd) probably compiles on BSD and OS/X as well. wd is the full screen character based version. wdw is the gui version. http://www.openwatcom.org Roald
Nov 23 2011
On 11/22/2011 7:19 AM, Martin Nowak wrote:- Can we slowly start to acquire DWARF-3/4?Dwarf 2 is good enough, so why do 3/4?- Why were extensions chosen over say representing an array as two field struct?Because it is presumably harder to get a debugger to recognize a magic struct than explicitly give it a type.- There is this request by Robert Clipsham http://dwarfstd.org/ShowIssue.php?issue=100504.1. What's the state of this, it wouldn't be needed any longer. - We should contact http://www.zero-bugs.com, it is said to support the dwarf extensions and would need to be changed. - Find out who else is affected by changing the current extensions. - Fixing the D-ABI specification.Are the issues in bugzilla?- Are there other DWARF debuggers that we should take into account? - Adding a page to GNU wiki describing the D extensions. - We could probably use DW_TAG_GNU_template_parameter_pack for variadic template arguments. http://wiki.dwarfstd.org/index.php?title=C%2B%2B0x:_Variadic_templates martin
Nov 24 2011
Walter Bright <newshound2 digitalmars.com> writes:On 11/22/2011 7:19 AM, Martin Nowak wrote:Huh, I swore I had already filed a bug regarding the AA ABI. http://d.puremagic.com/issues/show_bug.cgi?id=7008 Jerry- Can we slowly start to acquire DWARF-3/4?Dwarf 2 is good enough, so why do 3/4?- Why were extensions chosen over say representing an array as two field struct?Because it is presumably harder to get a debugger to recognize a magic struct than explicitly give it a type.- There is this request by Robert Clipsham http://dwarfstd.org/ShowIssue.php?issue=100504.1. What's the state of this, it wouldn't be needed any longer. - We should contact http://www.zero-bugs.com, it is said to support the dwarf extensions and would need to be changed. - Find out who else is affected by changing the current extensions. - Fixing the D-ABI specification.Are the issues in bugzilla?
Nov 25 2011
On Fri, 25 Nov 2011 04:13:18 +0100, Walter Bright <newshound2 digitalmars.com> wrote:On 11/22/2011 7:19 AM, Martin Nowak wrote:Dwarf-4 supports arbitrary expressions for array base addresses and the upper bound, one could directly translate D arrays. GDB doesn't support it at the moment, but it basically rules out requesting an extension to the DWARF standard. I think currently the best decision is to use the existing D support in GDB. C++0x will likely lead to extended support in GDB, while llvm-db should improve the OSX debugger support. With better support for the new formats we should be able to express specific D constructs in DWARF.- Can we slowly start to acquire DWARF-3/4?Dwarf 2 is good enough, so why do 3/4?- Why were extensions chosen over say representing an array as two field struct?Because it is presumably harder to get a debugger to recognize a magic struct than explicitly give it a type.- There is this request by Robert Clipsham http://dwarfstd.org/ShowIssue.php?issue=100504.1. What's the state of this, it wouldn't be needed any longer. - We should contact http://www.zero-bugs.com, it is said to support the dwarf extensions and would need to be changed. - Find out who else is affected by changing the current extensions. - Fixing the D-ABI specification.Are the issues in bugzilla?- Are there other DWARF debuggers that we should take into account? - Adding a page to GNU wiki describing the D extensions. - We could probably use DW_TAG_GNU_template_parameter_pack for variadic template arguments. http://wiki.dwarfstd.org/index.php?title=C%2B%2B0x:_Variadic_templates martin
Nov 28 2011
Martin Nowak Wrote:I think we should follow Tom Tromney's proposal to add the extensions under the GNU vendor space, i.e. prefix them with 0x41xx.Yeah, why use extensible debug info format and not use the extensibility feature?
Nov 24 2011
"Martin Nowak" <dawg dawgfoto.de> writes:On Tue, 22 Nov 2011 04:18:47 +0100, Andrei Alexandrescu <SeeWebsiteForEmail erdani.org> wrote:I've done a bit of reading on this issue, at least with regards to D arrays. I'm not a DWARF expert, but it appears that D dynamic arrays could be represented using the existing DWARF support, without an extension. Associative arrays are another issue. The current ABI describes them an opaque type. However, for the debugger to work with them, the structure must be understood somehow by the debugger. If treating them as a void* is the right approach (it still will result in compiler incompatibility), the ABI must define functions that access AA's. And debuggers will have to call those functions to read the AA. Until then, the debugger would have to cheat to access AA's. I don't know enough about delegates to comment on the support issues there.Maybe someone knowledgeable could chime in: http://sourceware.org/ml/gdb/2011-11/msg00066.html AndreiI think we should follow Tom Tromney's proposal to add the extensions under the GNU vendor space, i.e. prefix them with 0x41xx. Numbers hopefully don't fall under licensing issues. It should be fairly straightforward to improve gdb debugging support given that changes are accepted on either side. The GDB codebase is a slightly unfriendly environment but getting rid of 'p ((char*[2])str)[1]' would be great.I would volunteer to do the implementation but it would be great if someone helped with clarifying the following issues. - Can we slowly start to acquire DWARF-3/4? - Why were extensions chosen over say representing an array as two field struct?There was a comment on the ABI page that a struct is passed to functions differently from an array, and therefore debuggers wouldn't handle D arrays correctly if described that way.- We could probably use DW_TAG_GNU_template_parameter_pack for variadic template arguments. http://wiki.dwarfstd.org/index.php?title=C%2B%2B0x:_Variadic_templatesNote that the C++-11 standard also provides variadic templates. Therefore DWARF probably needs to address this in some standard way if it doesn't already. I'd think that D and C++ could share the same solution.
Nov 25 2011