]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
Add dwarf2_per_objfile parameter to process_full_{comp,type}_unit
authorSimon Marchi <simon.marchi@efficios.com>
Wed, 27 May 2020 15:13:58 +0000 (11:13 -0400)
committerSimon Marchi <simon.marchi@efficios.com>
Wed, 27 May 2020 15:15:56 +0000 (11:15 -0400)
This allows removing the dwarf2_per_cu_data::dwarf2_per_objfile
references in them.

gdb/ChangeLog:

* dwarf2/read.c (process_full_comp_unit): Add dwarf2_per_objfile
parameter.
(process_full_type_unit): Likewise.
(process_queue): Update.

Change-Id: Ie68baa8cc4bf1f81cc67d4ad13a59881b4c3feb6

gdb/ChangeLog
gdb/dwarf2/read.c

index 4b7898309ec9d32f90cf6aa26fc96f0ada270572..5136a2b73d0983dd9d6cd5ad8904b74f919d452d 100644 (file)
@@ -1,3 +1,10 @@
+2020-05-27  Simon Marchi  <simon.marchi@efficios.com>
+
+       * dwarf2/read.c (process_full_comp_unit): Add dwarf2_per_objfile
+       parameter.
+       (process_full_type_unit): Likewise.
+       (process_queue): Update.
+
 2020-05-27  Simon Marchi  <simon.marchi@efficios.com>
 
        * dwarf2/read.c (recursively_compute_inclusions): Add
index 070d8809bda7330760192048023f4906db3fad36..7b4cfb329e64533a1dc78a70708678b58715e007 100644 (file)
@@ -1572,11 +1572,13 @@ static void load_full_comp_unit (dwarf2_per_cu_data *per_cu,
                                 bool skip_partial,
                                 enum language pretend_language);
 
-static void process_full_comp_unit (struct dwarf2_per_cu_data *,
-                                   enum language);
+static void process_full_comp_unit (dwarf2_per_cu_data *per_cu,
+                                   dwarf2_per_objfile *per_objfile,
+                                   enum language pretend_language);
 
-static void process_full_type_unit (struct dwarf2_per_cu_data *,
-                                   enum language);
+static void process_full_type_unit (dwarf2_per_cu_data *per_cu,
+                                   dwarf2_per_objfile *per_objfile,
+                                   enum language pretend_language);
 
 static void dwarf2_add_dependence (struct dwarf2_cu *,
                                   struct dwarf2_per_cu_data *);
@@ -9035,9 +9037,11 @@ process_queue (struct dwarf2_per_objfile *dwarf2_per_objfile)
            fprintf_unfiltered (gdb_stdlog, "Expanding symtab of %s\n", buf);
 
          if (per_cu->is_debug_types)
-           process_full_type_unit (per_cu, item.pretend_language);
+           process_full_type_unit (per_cu, dwarf2_per_objfile,
+                                   item.pretend_language);
          else
-           process_full_comp_unit (per_cu, item.pretend_language);
+           process_full_comp_unit (per_cu, dwarf2_per_objfile,
+                                   item.pretend_language);
 
          if (dwarf_read_debug >= debug_print_threshold)
            fprintf_unfiltered (gdb_stdlog, "Done expanding %s\n", buf);
@@ -9741,11 +9745,11 @@ process_cu_includes (struct dwarf2_per_objfile *dwarf2_per_objfile)
    already been loaded into memory.  */
 
 static void
-process_full_comp_unit (struct dwarf2_per_cu_data *per_cu,
+process_full_comp_unit (dwarf2_per_cu_data *per_cu,
+                       dwarf2_per_objfile *dwarf2_per_objfile,
                        enum language pretend_language)
 {
   struct dwarf2_cu *cu = per_cu->cu;
-  struct dwarf2_per_objfile *dwarf2_per_objfile = per_cu->dwarf2_per_objfile;
   struct objfile *objfile = dwarf2_per_objfile->objfile;
   struct gdbarch *gdbarch = objfile->arch ();
   CORE_ADDR lowpc, highpc;
@@ -9841,11 +9845,11 @@ process_full_comp_unit (struct dwarf2_per_cu_data *per_cu,
    already been loaded into memory.  */
 
 static void
-process_full_type_unit (struct dwarf2_per_cu_data *per_cu,
+process_full_type_unit (dwarf2_per_cu_data *per_cu,
+                       dwarf2_per_objfile *dwarf2_per_objfile,
                        enum language pretend_language)
 {
   struct dwarf2_cu *cu = per_cu->cu;
-  struct dwarf2_per_objfile *dwarf2_per_objfile = per_cu->dwarf2_per_objfile;
   struct objfile *objfile = dwarf2_per_objfile->objfile;
   struct compunit_symtab *cust;
   struct signatured_type *sig_type;