This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
Re: [RFA] minsyms.c: Fix switching to GNU v3 ABI
On Mar 10 11:37, Daniel Jacobowitz wrote:
> What's the one symbol with just one underscore?
_ZZN9__gnu_cxx27__verbose_terminate_handlerEvE11terminating
I have a revised patch to solve the GDB problem. The leading_char
is removed right before the call to SYMBOL_SET_NAMES. The same
functionality is removed from install_minimal_symbols entirely.
I tested on i686-pc-linux with gcc 3.3 and sh-elf with gcc 3.4.
The testsuite has 48 less FAILs on sh-elf, all in gdb.cp.
The testsuite has one FAIL more for i686-pc-linux:
FAIL: gdb.cp/annota3.exp: annotate-quit (pattern 1)
though I must admit that I don't see what that has to do with my patch.
Corinna
* minsyms.c (install_minimal_symbols): Move dropping leading
char from linkage name from here...
(prim_record_minimal_symbol_and_info): ...to here.
Index: minsyms.c
===================================================================
RCS file: /cvs/src/src/gdb/minsyms.c,v
retrieving revision 1.41
diff -u -p -r1.41 minsyms.c
--- minsyms.c 9 Feb 2004 19:13:46 -0000 1.41
+++ minsyms.c 10 Mar 2004 17:17:37 -0000
@@ -611,6 +611,8 @@ prim_record_minimal_symbol_and_info (con
msymbol = &msym_bunch->contents[msym_bunch_index];
SYMBOL_INIT_LANGUAGE_SPECIFIC (msymbol, language_unknown);
SYMBOL_LANGUAGE (msymbol) = language_auto;
+ if (name[0] == get_symbol_leading_char (objfile->obfd))
+ ++name;
SYMBOL_SET_NAMES (msymbol, (char *)name, strlen (name), objfile);
SYMBOL_VALUE_ADDRESS (msymbol) = address;
@@ -864,13 +866,7 @@ install_minimal_symbols (struct objfile
for (bunch = msym_bunch; bunch != NULL; bunch = bunch->next)
{
for (bindex = 0; bindex < msym_bunch_index; bindex++, mcount++)
- {
- msymbols[mcount] = bunch->contents[bindex];
- if (SYMBOL_LINKAGE_NAME (&msymbols[mcount])[0] == leading_char)
- {
- SYMBOL_LINKAGE_NAME (&msymbols[mcount])++;
- }
- }
+ msymbols[mcount] = bunch->contents[bindex];
msym_bunch_index = BUNCH_SIZE;
}
--
Corinna Vinschen
Cygwin Developer
Red Hat, Inc.