diff options
author | Jan Kratochvil <jan.kratochvil@redhat.com> | 2011-04-27 20:03:04 +0000 |
---|---|---|
committer | Jan Kratochvil <jan.kratochvil@redhat.com> | 2011-04-27 20:03:04 +0000 |
commit | 559a7a62019960bacbbe4b099f3c7926352cb131 (patch) | |
tree | 612e31c7864fb3ef5cc4c477f3633c4a7da0579e /gdb/doc | |
parent | 681bf369ead4c4264cc9fcc8ba603cb06e7c2994 (diff) | |
download | gdb-559a7a62019960bacbbe4b099f3c7926352cb131.zip gdb-559a7a62019960bacbbe4b099f3c7926352cb131.tar.gz gdb-559a7a62019960bacbbe4b099f3c7926352cb131.tar.bz2 |
gdb/doc/
* gdb.texinfo (Index Section Format): Change the version to 5.
Describe the different formula.
gdb/
Case insensitive lookups implementation.
* dwarf2read.c: Include ctype.h.
(struct mapped_index): New field version.
(mapped_index_string_hash): New parameter index_version. New comment
for it. Call tolower appropriately.
(find_slot_in_mapped_hash): New variable cmp, initialize it, use it.
Choose the right index version for mapped_index_string_hash.
(dwarf2_read_index): Support also the index version 5. Initialize the
new struct mapped_index field version.
(hash_strtab_entry): Pass INT_MAX for the new parameter, explain why.
(find_slot): Explain the version needs. Pass INT_MAX for the new
parameter.
(write_psymtabs_to_index): Produce version 5.
* minsyms.c (lookup_minimal_symbol): New variable cmp, initialize it,
use it. New comment for SYMBOL_MATCHES_SEARCH_NAME.
* psymtab.c (lookup_partial_symbol): Find the
SYMBOL_MATCHES_SEARCH_NAME start of the found block of matching
entries.
* symtab.c (lookup_symbol_in_language): Remove the case_sensitive_off
NAME lowercasing.
(search_symbols): Pass REG_ICASE to regcomp for case_sensitive_off.
(completion_list_add_name): New variable ncmp, initialize it, use it.
* symtab.h (SYMBOL_HASH_NEXT): Always call tolower.
* utils.c (strcmp_iw): Support case_sensitive_off.
(strcmp_iw_ordered): Sort in a way compatible with case_sensitive_off.
New function comment part. New variables saved_string1,
saved_string2 and case_pass. Add a proper second pass.
gdb/testsuite/
* gdb.base/fortran-sym-case.c: New file.
* gdb.base/fortran-sym-case.exp: New file.
* gdb.dwarf2/dw2-case-insensitive-debug.S: New file.
* gdb.dwarf2/dw2-case-insensitive.c: New file.
* gdb.dwarf2/dw2-case-insensitive.exp: New file.
Diffstat (limited to 'gdb/doc')
-rw-r--r-- | gdb/doc/ChangeLog | 6 | ||||
-rw-r--r-- | gdb/doc/gdb.texinfo | 18 |
2 files changed, 20 insertions, 4 deletions
diff --git a/gdb/doc/ChangeLog b/gdb/doc/ChangeLog index aa3c893..514d584 100644 --- a/gdb/doc/ChangeLog +++ b/gdb/doc/ChangeLog @@ -1,3 +1,9 @@ +2011-04-27 Jan Kratochvil <jan.kratochvil@redhat.com> + Eli Zaretskii <eliz@gnu.org> + + * gdb.texinfo (Index Section Format): Change the version to 5. + Describe the different formula. + 2011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com> Eli Zaretskii <eliz@gnu.org> diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo index 15ccf2e..ff5b7cb 100644 --- a/gdb/doc/gdb.texinfo +++ b/gdb/doc/gdb.texinfo @@ -36993,7 +36993,8 @@ unless otherwise noted: @enumerate @item -The version number, currently 4. Versions 1, 2 and 3 are obsolete. +The version number, currently 5. Versions 1, 2 and 3 are obsolete. +Version 4 differs by its hashing function. @item The offset, from the start of the file, of the CU list. @@ -37061,9 +37062,18 @@ valid index for both a string and a CU vector. The hash value for a table entry is computed by applying an iterative hash function to the symbol's name. Starting with an initial value of @code{r = 0}, each (unsigned) character @samp{c} in -the string is incorporated into the hash using the formula -@code{r = r * 67 + c - 113}. The terminating @samp{\0} is not -incorporated into the hash. +the string is incorporated into the hash using the formula depending on the +index version: + +@table @asis +@item Version 4 +The formula is @code{r = r * 67 + c - 113}. + +@item Version 5 +The formula is @code{r = r * 67 + tolower (c) - 113}. +@end table + +The terminating @samp{\0} is not incorporated into the hash. The step size used in the hash table is computed via @code{((hash * 17) & (size - 1)) | 1}, where @samp{hash} is the hash |