public inbox for gdb-cvs@sourceware.org help / color / mirror / Atom feed
From: Markus Metzger <mmetzger@sourceware.org> To: gdb-cvs@sourceware.org Subject: [binutils-gdb] gdb, hppa: remove unused hppa_lookup_stub_minimal_symbol Date: Tue, 18 Oct 2022 13:25:38 +0000 (GMT) [thread overview] Message-ID: <20221018132538.8FA003858415@sourceware.org> (raw) https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=6f96c196beccb6f30b78ef878b3eaa420dfaa687 commit 6f96c196beccb6f30b78ef878b3eaa420dfaa687 Author: Markus Metzger <markus.t.metzger@intel.com> Date: Thu Apr 28 11:14:57 2022 +0200 gdb, hppa: remove unused hppa_lookup_stub_minimal_symbol I stumbled over this while reviewing all objfiles traversals with regards to impact of linker namespaces. Recursive grep only finds two occurrences of hppa_lookup_stub_minimal_symbol: - the declaration in hppa-tdep.h. - the definition in hppa-tdep.c. There appear to be no calls to this function. Remove it. Diff: --- gdb/hppa-tdep.c | 31 ------------------------------- gdb/hppa-tdep.h | 4 ---- 2 files changed, 35 deletions(-) diff --git a/gdb/hppa-tdep.c b/gdb/hppa-tdep.c index 9088225f206..e35e08b22c1 100644 --- a/gdb/hppa-tdep.c +++ b/gdb/hppa-tdep.c @@ -2509,37 +2509,6 @@ hppa_unwind_pc (struct gdbarch *gdbarch, frame_info_ptr next_frame) return pc & ~0x3; } -/* Return the minimal symbol whose name is NAME and stub type is STUB_TYPE. - Return NULL if no such symbol was found. */ - -struct bound_minimal_symbol -hppa_lookup_stub_minimal_symbol (const char *name, - enum unwind_stub_types stub_type) -{ - struct bound_minimal_symbol result; - - for (objfile *objfile : current_program_space->objfiles ()) - { - for (minimal_symbol *msym : objfile->msymbols ()) - { - if (strcmp (msym->linkage_name (), name) == 0) - { - struct unwind_table_entry *u; - - u = find_unwind_entry (msym->value_longest ()); - if (u != NULL && u->stub_unwind.stub_type == stub_type) - { - result.objfile = objfile; - result.minsym = msym; - return result; - } - } - } - } - - return result; -} - static void unwind_command (const char *exp, int from_tty) { diff --git a/gdb/hppa-tdep.h b/gdb/hppa-tdep.h index d0e0d4d6a3a..6ebcdc5e90a 100644 --- a/gdb/hppa-tdep.h +++ b/gdb/hppa-tdep.h @@ -210,10 +210,6 @@ extern void hppa_write_pc (struct regcache *regcache, CORE_ADDR pc); extern CORE_ADDR hppa_unwind_pc (struct gdbarch *gdbarch, frame_info_ptr next_frame); -extern struct bound_minimal_symbol - hppa_lookup_stub_minimal_symbol (const char *name, - enum unwind_stub_types stub_type); - extern int hppa_in_solib_call_trampoline (struct gdbarch *gdbarch, CORE_ADDR pc); extern CORE_ADDR hppa_skip_trampoline_code (frame_info_ptr , CORE_ADDR pc);
reply other threads:[~2022-10-18 13:25 UTC|newest] Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20221018132538.8FA003858415@sourceware.org \ --to=mmetzger@sourceware.org \ --cc=gdb-cvs@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: linkBe 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).