]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
gdb/dwarf: rename cache -> abbrev_cache
authorSimon Marchi <simon.marchi@efficios.com>
Wed, 26 Mar 2025 19:55:37 +0000 (15:55 -0400)
committerSimon Marchi <simon.marchi@polymtl.ca>
Thu, 3 Apr 2025 18:47:28 +0000 (14:47 -0400)
"cache" is just a bit too generic to be clear.

Change-Id: I8bf01c5fe84e076af1afd2453b1a115777630271

gdb/dwarf2/read.c
gdb/dwarf2/read.h

index 17f06ff134220d7753e7d9ac25e424965e9e55ed..71fd352343a69ded751865dd72e2268d10fcfd51 100644 (file)
@@ -2970,7 +2970,7 @@ cutu_reader::cutu_reader (dwarf2_per_cu &this_cu,
                          dwarf2_cu *existing_cu,
                          bool skip_partial,
                          enum language pretend_language,
-                         const abbrev_table_cache *cache)
+                         const abbrev_table_cache *abbrev_cache)
 {
   struct objfile *objfile = per_objfile.objfile;
   struct dwarf2_section_info *section = this_cu.section;
@@ -3030,7 +3030,7 @@ cutu_reader::cutu_reader (dwarf2_per_cu &this_cu,
         indexer.  This assert is avoided in this case because (1) it
         is irrelevant, and (2) the get_cu method is not
         thread-safe.  */
-      gdb_assert (cache != nullptr
+      gdb_assert (abbrev_cache != nullptr
                  || per_objfile.get_cu (&this_cu) == nullptr);
       m_new_cu = std::make_unique<dwarf2_cu> (&this_cu, &per_objfile);
       cu = m_new_cu.get ();
@@ -3092,9 +3092,9 @@ cutu_reader::cutu_reader (dwarf2_per_cu &this_cu,
        gdb_assert (cu->header.abbrev_sect_off == abbrev_table->sect_off);
       else
        {
-         if (cache != nullptr)
-           abbrev_table = cache->find (abbrev_section,
-                                       cu->header.abbrev_sect_off);
+         if (abbrev_cache != nullptr)
+           abbrev_table = abbrev_cache->find (abbrev_section,
+                                              cu->header.abbrev_sect_off);
          if (abbrev_table == nullptr)
            {
              abbrev_section->read (objfile);
index 7f56dac32f186a321978190c388885999a7ea3fd..b13e42d764f7a94b05ce95c05b1742b34cff1fc7 100644 (file)
@@ -927,7 +927,7 @@ public:
               dwarf2_cu *existing_cu,
               bool skip_partial,
               enum language pretend_language,
-              const abbrev_table_cache *cache = nullptr);
+              const abbrev_table_cache *abbrev_cache = nullptr);
 
   cutu_reader (dwarf2_per_cu &this_cu,
               dwarf2_per_objfile &per_objfile,