From mboxrd@z Thu Jan 1 00:00:00 1970 From: Daniel Jacobowitz To: Elena Zannoni Cc: gdb-patches@sources.redhat.com Subject: Re: [rfa] eliminate some annoying mdebug-related symtab crashes Date: Fri, 20 Jul 2001 18:31:00 -0000 Message-id: <20010720183150.A23780@nevyn.them.org> References: <20010709151122.A18937@nevyn.them.org> <15192.48720.958756.789421@krustylu.cygnus.com> <20010720154708.A16109@nevyn.them.org> <15192.59353.70860.131763@krustylu.cygnus.com> X-SW-Source: 2001-07/msg00542.html On Fri, Jul 20, 2001 at 10:24:25PM -0400, Elena Zannoni wrote: > Oh dear, I feel ill. Where is the paper bag, quick! So, the || check > before calling init_psymbol_list works if the two lists are kind of in > synch. They are grown/allocated together. They are both zero at > start, and they get initialized both to the same size in > init_psymbol_lists. Exactly. > Mon Apr 8 23:57:43 1991 John Gilmore (gnu at cygint.cygnus.com) > > * dbxread.c (dbx_symfile_read): Initialize psymbol list if this > is the first symbol read, even if not mainline. > > I would think that extend_psymbol_list was introduced afterwards, and > this broke the logic of Gilmore's change. > > So what to do? I am kind of convinced that your patch is > correct. But..., is there any chance you can run the gdb testsuite > before and after your changes on a couple of platforms that have at > least dwarf2 and stabs debug info (I mean separately, not in the same > objfile)? I'll try to do this and get back to you about it next week. > Another alternative would be to insert a call to > init_psymbol_lists(objfile, NUM_OF_SYMBOLS) somewhere in mdebugread.c. I didn't do that because I couldn't find a reasonable NUM_OF_SYMBOLS, but I could just use a hardcoded guess like some of the other symbol readers do, I suppose. I'd rather fix it as I proposed; I'll run those testsuites and see what I can turn up. -- Daniel Jacobowitz Carnegie Mellon University MontaVista Software Debian GNU/Linux Developer