From: Elena Zannoni Date: Wed, 5 Sep 2001 02:13:11 +0000 (+0000) Subject: 2001-09-04 Elena Zannoni X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=ef96bde82e147421678d9f5390f5d3632d314d2c;p=binutils-gdb.git 2001-09-04 Elena Zannoni From Daniel Jacobowitz * dbxread.c (dbx_symfile_read): Only reinitialize the psymbol list if mainline or if both static and global lists are empty. * dwarf2read.c (dwarf2_build_psymtabs): Likewise. * dwarfread.c (dwarf_build_psymtabs): Likewise. * xcoffread.c (xcoff_initial_scan): Likewise. * os9kread.c (os9k_symfile_read): Likewise. --- diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 6fe893af1e0..629cd043b45 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,5 +1,16 @@ 2001-09-04 Elena Zannoni + + From Daniel Jacobowitz + * dbxread.c (dbx_symfile_read): Only reinitialize + the psymbol list if mainline or if both static + and global lists are empty. + * dwarf2read.c (dwarf2_build_psymtabs): Likewise. + * dwarfread.c (dwarf_build_psymtabs): Likewise. + * xcoffread.c (xcoff_initial_scan): Likewise. + * os9kread.c (os9k_symfile_read): Likewise. +2001-09-04 Elena Zannoni + From Daniel Jacobowitz * mdebugread.c (psymtab_to_symtab_1): Handle N_SO stabs without a name specially. diff --git a/gdb/dbxread.c b/gdb/dbxread.c index f1382e7ef04..ba60fe10511 100644 --- a/gdb/dbxread.c +++ b/gdb/dbxread.c @@ -582,8 +582,8 @@ dbx_symfile_read (struct objfile *objfile, int mainline) /* If we are reinitializing, or if we have never loaded syms yet, init */ if (mainline - || objfile->global_psymbols.size == 0 - || objfile->static_psymbols.size == 0) + || (objfile->global_psymbols.size == 0 + && objfile->static_psymbols.size == 0)) init_psymbol_list (objfile, DBX_SYMCOUNT (objfile)); symbol_size = DBX_SYMBOL_SIZE (objfile); diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c index bc559b0ed43..478b4671566 100644 --- a/gdb/dwarf2read.c +++ b/gdb/dwarf2read.c @@ -869,8 +869,9 @@ dwarf2_build_psymtabs (struct objfile *objfile, int mainline) dwarf_line_offset, dwarf_line_size); - if (mainline || objfile->global_psymbols.size == 0 || - objfile->static_psymbols.size == 0) + if (mainline + || (objfile->global_psymbols.size == 0 + && objfile->static_psymbols.size == 0)) { init_psymbol_list (objfile, 1024); } diff --git a/gdb/dwarfread.c b/gdb/dwarfread.c index 0bfb4fdda68..d6258b33df9 100644 --- a/gdb/dwarfread.c +++ b/gdb/dwarfread.c @@ -706,8 +706,9 @@ dwarf_build_psymtabs (struct objfile *objfile, int mainline, file_ptr dbfoff, Since we have no idea how many DIES we are looking at, we just guess some arbitrary value. */ - if (mainline || objfile->global_psymbols.size == 0 || - objfile->static_psymbols.size == 0) + if (mainline + || (objfile->global_psymbols.size == 0 + && objfile->static_psymbols.size == 0)) { init_psymbol_list (objfile, 1024); } diff --git a/gdb/os9kread.c b/gdb/os9kread.c index 8dcf2519e2f..591161c1d10 100644 --- a/gdb/os9kread.c +++ b/gdb/os9kread.c @@ -320,8 +320,9 @@ os9k_symfile_read (struct objfile *objfile, int mainline) sym_bfd = objfile->obfd; /* If we are reinitializing, or if we have never loaded syms yet, init */ - if (mainline || objfile->global_psymbols.size == 0 || - objfile->static_psymbols.size == 0) + if (mainline + || (objfile->global_psymbols.size == 0 + && objfile->static_psymbols.size == 0)) init_psymbol_list (objfile, DBX_SYMCOUNT (objfile)); free_pending_blocks (); diff --git a/gdb/xcoffread.c b/gdb/xcoffread.c index 6e52710d472..5e7b93504a7 100644 --- a/gdb/xcoffread.c +++ b/gdb/xcoffread.c @@ -2684,8 +2684,8 @@ xcoff_initial_scan (struct objfile *objfile, int mainline) /* If we are reinitializing, or if we have never loaded syms yet, init */ if (mainline - || objfile->global_psymbols.size == 0 - || objfile->static_psymbols.size == 0) + || (objfile->global_psymbols.size == 0 + && objfile->static_psymbols.size == 0)) /* I'm not sure how how good num_symbols is; the rule of thumb in init_psymbol_list was developed for a.out. On the one hand, num_symbols includes auxents. On the other hand, it doesn't