From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 517D63858D20; Tue, 8 Aug 2023 23:32:53 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 517D63858D20 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1691537573; bh=eG34YQNcl+edwSO4rNxjs8oF4zhh8mNhVhuhsm5poZU=; h=From:To:Subject:Date:In-Reply-To:References:From; b=oUDnEJDcZ6VoeNq1W3dFhXNvcBsiy4RRcuPTUi0AcEJK1xVkYviy48jBmnlfaakyS tGK16Mmu1oC4+4mdjt6m/Ksz8cu2PYdTik5x0vgtEsL/H6Ox+iCX8giNqMr19SQL/2 BJtyg54k5MkaHhCUcJR02PU2UA8Ekkn3l411/LA8= From: "vries at gcc dot gnu.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: Tue, 08 Aug 2023 23:32:52 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gdb X-Bugzilla-Component: symtab X-Bugzilla-Version: HEAD X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: vries at gcc dot gnu.org X-Bugzilla-Status: NEW X-Bugzilla-Resolution: X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: unassigned at sourceware dot org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 List-Id: https://sourceware.org/bugzilla/show_bug.cgi?id=3D30728 --- Comment #9 from Tom de Vries --- With this patch we got a bit more info: ... diff --git a/gdb/dwarf2/cooked-index.c b/gdb/dwarf2/cooked-index.c index 92ef0e35c5e..c53565dd317 100644 --- a/gdb/dwarf2/cooked-index.c +++ b/gdb/dwarf2/cooked-index.c @@ -583,6 +583,8 @@ cooked_index::dump (gdbarch *arch) const gdb_printf (" flags: %s\n", to_string (entry->flags).c_str (= )); gdb_printf (" DIE offset: 0x%" PRIx64 "\n", to_underlying (entry->die_offset)); + gdb_printf (" per_cu offset: 0x%" PRIx64 "\n", + to_underlying (entry->per_cu->sect_off)); if (entry->parent_entry !=3D nullptr) gdb_printf (" parent: ((cooked_index_entry *) %p) [%s]\n", ... In the failing case, we have: ... Breakpoint 1 at 0x4004db: file /data/vries/gdb/src/gdb/testsuite/gdb.cp/breakpoint-locs.h, line 23. ... [5] ((cooked_index_entry *) 0x7f5384002f00) name: baz canonical: baz DWARF tag: DW_TAG_subprogram flags: 0x0 [] DIE offset: 0x2e per_cu offset: 0xe3 parent: ((cooked_index_entry *) 0x7f5384002ed0) [C1] ... and in the passing case we have: ... Breakpoint 1 at 0x4004db: N1::C1::baz. (2 locations) ... [12] ((cooked_index_entry *) 0x7f6968002f00) name: baz canonical: baz DWARF tag: DW_TAG_subprogram flags: 0x0 [] DIE offset: 0x2e per_cu offset: 0x16e parent: ((cooked_index_entry *) 0x7f6968002ed0) [C1] ... So, the per_cu doesn't refer to the PU, but rather to the importing CU that wins the race. The PU should have the info that it has two includer CU, and expansion of b= oth should be triggered. So, my guess is that the PU dies have the wrong per_cu value. --=20 You are receiving this mail because: You are on the CC list for the bug.=