Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-pascal / 2010-05

annoying gdb bug fixed

4 messages · 3 people · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Seth Grover

For those of you interested, in the GDB 7.1 release there is a bug which prevents "var" arguments from being "print"ed correctly in GDB. I logged a bug for this
(http://sourceware.org/bugzilla/show_bug.cgi?id=11349), for which a GDB developer checked up a fix into the GDB cvs trunk late last week.

I've tested it and the patches they provided do fix the problem. So, if you feel inclined to compile GDB from scratch this will solve a very annoying problem debugging FPC-compiled binaries with GDB.

Good luck,

-SG

This email is fiction. Any resemblance to actual events or persons living or dead is purely coincidental. Seth Grover sethdgrover[at]gmail[dot]com

Reply by email

Pierre Muller
to Seth Grover
Show quoted text 12 lines
-----Message d'origine----- De : [mailto:fpc-pascal- De la part de Seth Grover Envoyé : Monday, May 10, 2010 2:48 PM À : Objet : [fpc-pascal] annoying gdb bug fixed For those of you interested, in the GDB 7.1 release there is a bug which prevents "var" arguments from being "print"ed correctly in GDB. I logged a bug for this (http://sourceware.org/bugzilla/show_bug.cgi?id=11349), for which a GDB developer checked up a fix into the GDB cvs trunk late last week.

This was me...
I just wanted to add that this bug is
most probably specific to the debug format used:
only the dwarf debug format generated information
that triggered that bug.
So don't be surprised if you never saw that problem, it's just because you probably use stabs debug information.

Pierre Muller
Pascal language support maintainer for GDB
... and Free Pascal Core developper

Reply by email

Jonas Maebe
to Pierre Muller
Pierre Muller wrote
I just wanted to add that this bug is most probably specific to the debug format used: only the dwarf debug format generated information that triggered that bug.

The reason that we generate such debug info for DWARF (namely encoding "var" parameters as C++ reference parameters) is because the DWARF attribute to specify var parameters (DW_AT_variable_parameter) is not yet supported by GDB (which is partly my fault, because I never submitted a bug about this). You can compile the compiler with - dgdb_supports_DW_AT_variable_parameter to make it generate such tags instead of reference parameters when using DWARF.

So don't be surprised if you never saw that problem, it's just because you probably use stabs debug information.

It did work correctly (with DWARF) in GDB 6.8. It broke with 7.0.

Jonas

Reply by email

Seth Grover
This was me... Pierre Muller

Pierre, thanks so much for taking the time to look at and resolve this bug. It's working beautifully now.

-SG

This email is fiction. Any resemblance to actual events or persons living or dead is purely coincidental. Seth Grover sethdgrover[at]gmail[dot]com

Reply by email