diff options
author | Doug Evans <dje@google.com> | 2011-11-15 17:40:02 +0000 |
---|---|---|
committer | Doug Evans <dje@google.com> | 2011-11-15 17:40:02 +0000 |
commit | c011a4f469702871cbd5a1e7fecdb57d322642bd (patch) | |
tree | e0a8599b1b433bfba3d377eaea9f106df3e48eda /gdb/doc | |
parent | 865ecab4b2b7d6efeaec3072ee843d2d830d2dae (diff) | |
download | gdb-c011a4f469702871cbd5a1e7fecdb57d322642bd.zip gdb-c011a4f469702871cbd5a1e7fecdb57d322642bd.tar.gz gdb-c011a4f469702871cbd5a1e7fecdb57d322642bd.tar.bz2 |
* NEWS: Mention new parameter basenames-may-differ.
* dwarf2read.c (dw2_lookup_symtab): Avoid calling gdb_realpath if
! basenames_may_differ.
* psymtab.c (lookup_partial_symtab): Ditto.
* symtab.c (lookup_symtab): Ditto.
(basenames_may_differ): New global.
(_initialize_symtab): New parameter basenames-may-differ.
* symtab.h (basenames_may_differ): Declare.
doc/
* gdb.texinfo (Files): Document basenames-may-differ.
Diffstat (limited to 'gdb/doc')
-rw-r--r-- | gdb/doc/ChangeLog | 4 | ||||
-rw-r--r-- | gdb/doc/gdb.texinfo | 27 |
2 files changed, 31 insertions, 0 deletions
diff --git a/gdb/doc/ChangeLog b/gdb/doc/ChangeLog index 15659d6..4975cd2 100644 --- a/gdb/doc/ChangeLog +++ b/gdb/doc/ChangeLog @@ -1,3 +1,7 @@ +2011-11-15 Doug Evans <dje@google.com> + + * gdb.texinfo (Files): Document basenames-may-differ. + 2011-11-14 Doug Evans <dje@google.com> * gdb.texinfo (Shell Commands): Document "!". diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo index 9255b89..f4f7f1e 100644 --- a/gdb/doc/gdb.texinfo +++ b/gdb/doc/gdb.texinfo @@ -15705,6 +15705,33 @@ This is the default. @end table @end table +@cindex file name canonicalization +@cindex base name differences +When processing file names provided by the user, @value{GDBN} +frequently needs to compare them to the file names recorded in the +program's debug info. Normally, @value{GDBN} compares just the +@dfn{base names} of the files as strings, which is reasonably fast +even for very large programs. (The base name of a file is the last +portion of its name, after stripping all the leading directories.) +This shortcut in comparison is based upon the assumption that files +cannot have more than one base name. This is usually true, but +references to files that use symlinks or similar filesystem +facilities violate that assumption. If your program records files +using such facilities, or if you provide file names to @value{GDBN} +using symlinks etc., you can set @code{basenames-may-differ} to +@code{true} to instruct @value{GDBN} to completely canonicalize each +pair of file names it needs to compare. This will make file-name +comparisons accurate, but at a price of a significant slowdown. + +@table @code +@item set basenames-may-differ +@kindex set basenames-may-differ +Set whether a source file may have multiple base names. + +@item show basenames-may-differ +@kindex show basenames-may-differ +Show whether a source file may have multiple base names. +@end table @node Separate Debug Files @section Debugging Information in Separate Files |