public inbox for gdb-prs@sourceware.org help / color / mirror / Atom feed
From: "vries at gcc dot gnu.org" <sourceware-bugzilla@sourceware.org> To: gdb-prs@sourceware.org Subject: [Bug symtab/30728] [gdb/symtab, cc-with-dwz] FAIL: gdb.cp/breakpoint-locs.exp: break N1::C1::baz Date: Sun, 06 Aug 2023 22:00:24 +0000 [thread overview] Message-ID: <bug-30728-4717-tD6DgIZXid@http.sourceware.org/bugzilla/> (raw) In-Reply-To: <bug-30728-4717@http.sourceware.org/bugzilla/> https://sourceware.org/bugzilla/show_bug.cgi?id=30728 --- Comment #4 from Tom de Vries <vries at gcc dot gnu.org> --- I'm starting to understand somewhat why it's not 100% reproducible. With this patch: ... diff --git a/gdb/dwarf2/read.c b/gdb/dwarf2/read.c index dd4fac52ca8..ed36b5e890b 100644 --- a/gdb/dwarf2/read.c +++ b/gdb/dwarf2/read.c @@ -16889,6 +16889,13 @@ cooked_index_functions::expand_symtabs_matching = lookup_name_without_params.split_name (lang); std::string last_name = gdb::to_string (name_vec.back ()); + for (const cooked_index_entry *entry : table->find (last_name, + completing)) + { + QUIT; + fprintf (stderr, "Trying entry: %lx\n", (unsigned long)entry->die_offset); + } + for (const cooked_index_entry *entry : table->find (last_name, completing)) { @@ -16953,6 +16960,7 @@ cooked_index_functions::expand_symtabs_matching continue; } + fprintf (stderr, "matched entry: %lx\n", (unsigned long)entry->die_offset); if (!dw2_expand_symtabs_matching_one (entry->per_cu, per_objfile, file_matcher, expansion_notify)) ... I get: ... $ gdb -q -batch ./breakpoint-locs -ex "break N1::C1::baz" Trying entry: 14 Trying entry: 10e Trying entry: 199 matched entry: 14 Trying entry: 2e Trying entry: 2e Trying entry: 2e Breakpoint 1 at 0x4004db: file /data/vries/gdb/src/gdb/testsuite/gdb.cp/breakpoint-locs.h, line 23. ... or: ... $ gdb -q -batch ./breakpoint-locs -ex "break N1::C1::baz" Trying entry: 10e Trying entry: 14 Trying entry: 199 matched entry: 10e Trying entry: 2e matched entry: 2e Trying entry: 2e Trying entry: 2e Breakpoint 1 at 0x4004db: N1::C1::baz. (2 locations) ... The root cause of the difference seems to be that the order of table->find is not stable. -- You are receiving this mail because: You are on the CC list for the bug.
next prev parent reply other threads:[~2023-08-06 22:00 UTC|newest] Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top 2023-08-06 15:50 [Bug symtab/30728] New: " vries at gcc dot gnu.org 2023-08-06 16:16 ` [Bug symtab/30728] " vries at gcc dot gnu.org 2023-08-06 16:31 ` vries at gcc dot gnu.org 2023-08-06 18:15 ` vries at gcc dot gnu.org 2023-08-06 22:00 ` vries at gcc dot gnu.org [this message] 2023-08-07 10:23 ` vries at gcc dot gnu.org 2023-08-07 10:44 ` vries at gcc dot gnu.org 2023-08-07 15:14 ` vries at gcc dot gnu.org 2023-08-07 16:35 ` tromey at sourceware dot org 2023-08-08 23:32 ` vries at gcc dot gnu.org 2023-08-09 15:31 ` vries at gcc dot gnu.org 2023-08-10 8:49 ` vries at gcc dot gnu.org 2023-08-25 15:56 ` vries at gcc dot gnu.org 2023-10-02 12:55 ` vries at gcc dot gnu.org 2023-11-29 15:08 ` jamborm at gcc dot gnu.org 2024-01-15 0:47 ` tromey at sourceware dot org 2024-01-15 1:34 ` tromey at sourceware dot org 2024-01-15 1:54 ` tromey at sourceware dot org 2024-02-09 19:48 ` tromey at sourceware dot org 2024-02-16 2:42 ` tromey at sourceware dot org 2024-05-06 13:57 ` vries at gcc dot gnu.org
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=bug-30728-4717-tD6DgIZXid@http.sourceware.org/bugzilla/ \ --to=sourceware-bugzilla@sourceware.org \ --cc=gdb-prs@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).