From: Matthias Maennich <maennich@google.com>
To: libabigail@sourceware.org
Cc: dodji@seketeli.org, gprocida@google.com, kernel-team@android.com,
maennich@google.com
Subject: [PATCH] dwarf-reader: read_context: drop some unused accessor methods
Date: Mon, 11 May 2020 17:27:08 +0200 [thread overview]
Message-ID: <20200511152708.34098-1-maennich@google.com> (raw)
Those methods were effectively dead code. Hence only keep the actually
used accessors around:
const string_elf_symbols_map_sptr& some_sptr();
string_elf_symbols_map_sptr& some();
* src/abg-dwarf-reader.cc (read_context::fun_syms_sptr): Delete method.
(read_context::fun_syms): Likewise.
(read_context::var_syms_sptr): Likewise.
(read_context::var_syms): Likewise.
(read_context::undefined_fun_syms_sptr): Likewise.
(read_context::undefined_fun_syms): Likewise. Both overloads.
(read_context::undefined_var_syms_sptr): Likewise.
(read_context::undefined_var_syms): Likewise. Both overloads.
Reviewed-by: Giuliano Procida <gprocida@google.com>
Signed-off-by: Matthias Maennich <maennich@google.com>
---
src/abg-dwarf-reader.cc | 108 ----------------------------------------
1 file changed, 108 deletions(-)
diff --git a/src/abg-dwarf-reader.cc b/src/abg-dwarf-reader.cc
index 638375541ef7..5024deb3f857 100644
--- a/src/abg-dwarf-reader.cc
+++ b/src/abg-dwarf-reader.cc
@@ -6026,26 +6026,6 @@ public:
return fun_syms_;
}
- /// Getter for the map of function symbols (name -> sym).
- ///
- /// @return a shared pointer to the map of function symbols.
- string_elf_symbols_map_sptr&
- fun_syms_sptr()
- {
- maybe_load_symbol_maps();
- return fun_syms_;
- }
-
- /// Getter for the map of function symbols (name -> sym).
- ///
- /// @return a reference to the map of function symbols.
- const string_elf_symbols_map_type&
- fun_syms() const
- {
- maybe_load_symbol_maps();
- return *fun_syms_;
- }
-
/// Getter for the map of function symbols (name -> sym).
///
/// @return a reference to the map of function symbols.
@@ -6066,26 +6046,6 @@ public:
return var_syms_;
}
- /// Getter for the map of variable symbols (name -> sym)
- ///
- /// @return a shared pointer to the map of variable symbols.
- string_elf_symbols_map_sptr
- var_syms_sptr()
- {
- maybe_load_symbol_maps();
- return var_syms_;
- }
-
- /// Getter for the map of variable symbols (name -> sym)
- ///
- /// @return a reference to the map of variable symbols.
- const string_elf_symbols_map_type&
- var_syms() const
- {
- maybe_load_symbol_maps();
- return *var_syms_;
- }
-
/// Getter for the map of variable symbols (name -> sym)
///
/// @return a reference to the map of variable symbols.
@@ -6108,40 +6068,6 @@ public:
return undefined_fun_syms_;
}
- /// Getter for the map of undefined function symbols (name -> vector
- /// of symbols).
- ///
- /// @return a (smart) pointer to the map of undefined function
- /// symbols.
- string_elf_symbols_map_sptr&
- undefined_fun_syms_sptr()
- {
- maybe_load_symbol_maps();
- return undefined_fun_syms_;
- }
-
- /// Getter for the map of undefined function symbols (name -> vector
- /// of symbols).
- ///
- /// @return a reference to the map of undefined function symbols.
- const string_elf_symbols_map_type&
- undefined_fun_syms() const
- {
- maybe_load_symbol_maps();
- return *undefined_fun_syms_;
- }
-
- /// Getter for the map of undefined function symbols (name -> vector
- /// of symbols).
- ///
- /// @return a reference to the map of undefined function symbols.
- string_elf_symbols_map_type&
- undefined_fun_syms()
- {
- maybe_load_symbol_maps();
- return *undefined_fun_syms_;
- }
-
/// Getter for the map of undefined variable symbols (name -> vector
/// of symbols).
///
@@ -6154,40 +6080,6 @@ public:
return undefined_var_syms_;
}
- /// Getter for the map of undefined variable symbols (name -> vector
- /// of symbols).
- ///
- /// @return a (smart) pointer to the map of undefined variable
- /// symbols.
- string_elf_symbols_map_sptr&
- undefined_var_syms_sptr()
- {
- maybe_load_symbol_maps();
- return undefined_var_syms_;
- }
-
- /// Getter for the map of undefined variable symbols (name -> vector
- /// of symbols).
- ///
- /// @return a reference to the map of undefined variable symbols.
- const string_elf_symbols_map_type&
- undefined_var_syms() const
- {
- maybe_load_symbol_maps();
- return *undefined_var_syms_;
- }
-
- /// Getter for the map of undefined variable symbols (name -> vector
- /// of symbols).
- ///
- /// @return a reference to the map of undefined variable symbols.
- string_elf_symbols_map_type&
- undefined_var_syms()
- {
- maybe_load_symbol_maps();
- return *undefined_var_syms_;
- }
-
/// Getter for the set of addresses of function symbols that are
/// explicitely exported, for a linux kernel (module) binary. These
/// are the addresses of function symbols present in the __ksymtab
--
2.26.2.645.ge9eca65c58-goog
next reply other threads:[~2020-05-11 15:27 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-05-11 15:27 Matthias Maennich [this message]
2020-05-13 9:53 ` Dodji Seketeli
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200511152708.34098-1-maennich@google.com \
--to=maennich@google.com \
--cc=dodji@seketeli.org \
--cc=gprocida@google.com \
--cc=kernel-team@android.com \
--cc=libabigail@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).