2001-09-04 Elena Zannoni <ezannoni@redhat.com>
authorElena Zannoni <ezannoni@kwikemart.cygnus.com>
Wed, 5 Sep 2001 02:13:11 +0000 (02:13 +0000)
committerElena Zannoni <ezannoni@kwikemart.cygnus.com>
Wed, 5 Sep 2001 02:13:11 +0000 (02:13 +0000)
From Daniel Jacobowitz  <drow@mvista.com>
* 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.

gdb/ChangeLog
gdb/dbxread.c
gdb/dwarf2read.c
gdb/dwarfread.c
gdb/os9kread.c
gdb/xcoffread.c

index 6fe893af1e0e555b99aaad720cdfb148ac77a41f..629cd043b458ccbdacd9f18b6d89032b7f06fb2b 100644 (file)
@@ -1,5 +1,16 @@
 2001-09-04  Elena Zannoni  <ezannoni@redhat.com>
+
+       From Daniel Jacobowitz  <drow@mvista.com>       
+       * 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  <ezannoni@redhat.com>
+
        From Daniel Jacobowitz  <drow@mvista.com>       
        * mdebugread.c (psymtab_to_symtab_1): Handle N_SO stabs without
        a name specially.
index f1382e7ef045e4ffe015fd33671102b6f46f4e3c..ba60fe10511c21a53ae3d248e1d1ff5e7e186b5d 100644 (file)
@@ -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);
index bc559b0ed43e7cc41e15cda82fa149b2abee911f..478b4671566891614b7fae3ddfbcbf68c89d9374 100644 (file)
@@ -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);
     }
index 0bfb4fdda68837e4199807d4b8c76482edbd2e67..d6258b33df93b4005057fb19b9af9272d7499f91 100644 (file)
@@ -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);
     }
index 8dcf2519e2f7618061beca201ed9b6f2af5e705f..591161c1d1046cb095908e5d2bf4ebb8d4c50d89 100644 (file)
@@ -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 ();
index 6e52710d4722b10a370c6a5dfe37741c317af15b..5e7b93504a78e1ad6ebfb50a50c1cd4684314ee4 100644 (file)
@@ -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