Add set/show debug dwarf-line.
gdb/ChangeLog: * NEWS: Mention "set debug dwarf-line". * dwarf2read.c (dwarf_line_debug): New static global. (add_include_dir): Add debug dwarf-line support. (add_file_name, dwarf_record_line, dwarf_finish_line): Ditto. (_initialize_dwarf2_read): New parameter "debug dwarf-line". gdb/doc/ChangeLog: * gdb.texinfo (Debugging Output): Mention set/show debug dwarf-line.
This commit is contained in:
parent
4dcabcc2b5
commit
27e0867f4d
|
@ -1,3 +1,11 @@
|
||||||
|
2015-05-27 Doug Evans <dje@google.com>
|
||||||
|
|
||||||
|
* NEWS: Mention "set debug dwarf-line".
|
||||||
|
* dwarf2read.c (dwarf_line_debug): New static global.
|
||||||
|
(add_include_dir): Add debug dwarf-line support.
|
||||||
|
(add_file_name, dwarf_record_line, dwarf_finish_line): Ditto.
|
||||||
|
(_initialize_dwarf2_read): New parameter "debug dwarf-line".
|
||||||
|
|
||||||
2015-05-27 Doug Evans <dje@google.com>
|
2015-05-27 Doug Evans <dje@google.com>
|
||||||
|
|
||||||
* cp-namespace.c (cp_lookup_nested_symbol): New arg "domain".
|
* cp-namespace.c (cp_lookup_nested_symbol): New arg "domain".
|
||||||
|
|
4
gdb/NEWS
4
gdb/NEWS
|
@ -112,6 +112,10 @@ maint set dwarf max-cache-age
|
||||||
maint show dwarf max-cache-age
|
maint show dwarf max-cache-age
|
||||||
Renamed from "maint show dwarf2 max-cache-age".
|
Renamed from "maint show dwarf2 max-cache-age".
|
||||||
|
|
||||||
|
set debug dwarf-line
|
||||||
|
show debug dwarf-line
|
||||||
|
Control display of debugging info regarding DWARF line processing.
|
||||||
|
|
||||||
set max-completions
|
set max-completions
|
||||||
show max-completions
|
show max-completions
|
||||||
Set the maximum number of candidates to be considered during
|
Set the maximum number of candidates to be considered during
|
||||||
|
|
|
@ -1,3 +1,7 @@
|
||||||
|
2015-05-27 Doug Evans <dje@google.com>
|
||||||
|
|
||||||
|
* gdb.texinfo (Debugging Output): Mention set/show debug dwarf-line.
|
||||||
|
|
||||||
2015-05-26 Doug Evans <dje@google.com>
|
2015-05-26 Doug Evans <dje@google.com>
|
||||||
|
|
||||||
* gdb.texinfo (Debugging Output): Update for DWARF "set debug"
|
* gdb.texinfo (Debugging Output): Update for DWARF "set debug"
|
||||||
|
|
|
@ -23417,6 +23417,14 @@ The value is the number of nesting levels to print.
|
||||||
A value of zero turns off the display.
|
A value of zero turns off the display.
|
||||||
@item show debug dwarf-die
|
@item show debug dwarf-die
|
||||||
Show the current state of DWARF DIE debugging.
|
Show the current state of DWARF DIE debugging.
|
||||||
|
@item set debug dwarf-line
|
||||||
|
@cindex DWARF Line Tables
|
||||||
|
Turns on or off display of debugging messages related to reading
|
||||||
|
DWARF line tables. The default is 0 (off).
|
||||||
|
A value of 1 provides basic information.
|
||||||
|
A value greater than 1 provides more verbose information.
|
||||||
|
@item show debug dwarf-line
|
||||||
|
Show the current state of DWARF line table debugging.
|
||||||
@item set debug dwarf-read
|
@item set debug dwarf-read
|
||||||
@cindex DWARF Reading
|
@cindex DWARF Reading
|
||||||
Turns on or off display of debugging messages related to reading
|
Turns on or off display of debugging messages related to reading
|
||||||
|
|
|
@ -84,6 +84,9 @@ static unsigned int dwarf_read_debug = 0;
|
||||||
/* When non-zero, dump DIEs after they are read in. */
|
/* When non-zero, dump DIEs after they are read in. */
|
||||||
static unsigned int dwarf_die_debug = 0;
|
static unsigned int dwarf_die_debug = 0;
|
||||||
|
|
||||||
|
/* When non-zero, dump line number entries as they are read in. */
|
||||||
|
static unsigned int dwarf_line_debug = 0;
|
||||||
|
|
||||||
/* When non-zero, cross-check physname against demangler. */
|
/* When non-zero, cross-check physname against demangler. */
|
||||||
static int check_physname = 0;
|
static int check_physname = 0;
|
||||||
|
|
||||||
|
@ -17152,6 +17155,10 @@ free_line_header_voidp (void *arg)
|
||||||
static void
|
static void
|
||||||
add_include_dir (struct line_header *lh, const char *include_dir)
|
add_include_dir (struct line_header *lh, const char *include_dir)
|
||||||
{
|
{
|
||||||
|
if (dwarf_line_debug >= 2)
|
||||||
|
fprintf_unfiltered (gdb_stdlog, "Adding dir %u: %s\n",
|
||||||
|
lh->num_include_dirs + 1, include_dir);
|
||||||
|
|
||||||
/* Grow the array if necessary. */
|
/* Grow the array if necessary. */
|
||||||
if (lh->include_dirs_size == 0)
|
if (lh->include_dirs_size == 0)
|
||||||
{
|
{
|
||||||
|
@ -17181,6 +17188,10 @@ add_file_name (struct line_header *lh,
|
||||||
{
|
{
|
||||||
struct file_entry *fe;
|
struct file_entry *fe;
|
||||||
|
|
||||||
|
if (dwarf_line_debug >= 2)
|
||||||
|
fprintf_unfiltered (gdb_stdlog, "Adding file %u: %s\n",
|
||||||
|
lh->num_file_names + 1, name);
|
||||||
|
|
||||||
/* Grow the array if necessary. */
|
/* Grow the array if necessary. */
|
||||||
if (lh->file_names_size == 0)
|
if (lh->file_names_size == 0)
|
||||||
{
|
{
|
||||||
|
@ -17529,6 +17540,14 @@ dwarf_record_line (struct gdbarch *gdbarch, struct subfile *subfile,
|
||||||
{
|
{
|
||||||
CORE_ADDR addr = gdbarch_addr_bits_remove (gdbarch, address);
|
CORE_ADDR addr = gdbarch_addr_bits_remove (gdbarch, address);
|
||||||
|
|
||||||
|
if (dwarf_line_debug)
|
||||||
|
{
|
||||||
|
fprintf_unfiltered (gdb_stdlog,
|
||||||
|
"Recording line %u, file %s, address %s\n",
|
||||||
|
line, lbasename (subfile->name),
|
||||||
|
paddress (gdbarch, address));
|
||||||
|
}
|
||||||
|
|
||||||
(*p_record_line) (subfile, line, addr);
|
(*p_record_line) (subfile, line, addr);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -17541,8 +17560,18 @@ static void
|
||||||
dwarf_finish_line (struct gdbarch *gdbarch, struct subfile *subfile,
|
dwarf_finish_line (struct gdbarch *gdbarch, struct subfile *subfile,
|
||||||
CORE_ADDR address, record_line_ftype p_record_line)
|
CORE_ADDR address, record_line_ftype p_record_line)
|
||||||
{
|
{
|
||||||
if (subfile != NULL)
|
if (subfile == NULL)
|
||||||
dwarf_record_line (gdbarch, subfile, 0, address, p_record_line);
|
return;
|
||||||
|
|
||||||
|
if (dwarf_line_debug)
|
||||||
|
{
|
||||||
|
fprintf_unfiltered (gdb_stdlog,
|
||||||
|
"Finishing current line, file %s, address %s\n",
|
||||||
|
lbasename (subfile->name),
|
||||||
|
paddress (gdbarch, address));
|
||||||
|
}
|
||||||
|
|
||||||
|
dwarf_record_line (gdbarch, subfile, 0, address, p_record_line);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Subroutine of dwarf_decode_lines to simplify it.
|
/* Subroutine of dwarf_decode_lines to simplify it.
|
||||||
|
@ -23321,6 +23350,16 @@ The value is the maximum depth to print."),
|
||||||
NULL,
|
NULL,
|
||||||
&setdebuglist, &showdebuglist);
|
&setdebuglist, &showdebuglist);
|
||||||
|
|
||||||
|
add_setshow_zuinteger_cmd ("dwarf-line", no_class, &dwarf_line_debug, _("\
|
||||||
|
Set debugging of the dwarf line reader."), _("\
|
||||||
|
Show debugging of the dwarf line reader."), _("\
|
||||||
|
When enabled (non-zero), line number entries are dumped as they are read in.\n\
|
||||||
|
A value of 1 (one) provides basic information.\n\
|
||||||
|
A value greater than 1 provides more verbose information."),
|
||||||
|
NULL,
|
||||||
|
NULL,
|
||||||
|
&setdebuglist, &showdebuglist);
|
||||||
|
|
||||||
add_setshow_boolean_cmd ("check-physname", no_class, &check_physname, _("\
|
add_setshow_boolean_cmd ("check-physname", no_class, &check_physname, _("\
|
||||||
Set cross-checking of \"physname\" code against demangler."), _("\
|
Set cross-checking of \"physname\" code against demangler."), _("\
|
||||||
Show cross-checking of \"physname\" code against demangler."), _("\
|
Show cross-checking of \"physname\" code against demangler."), _("\
|
||||||
|
|
Loading…
Reference in New Issue