From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 07E783851427; Mon, 20 Apr 2020 07:56:38 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 07E783851427 From: "vries at gcc dot gnu.org" To: gdb-prs@sourceware.org Subject: [Bug symtab/25858] [readnow] FAIL: gdb.ada/bp_c_mixed_case.exp: break Date: Mon, 20 Apr 2020 07:56:37 +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 X-BeenThere: gdb-prs@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-prs mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 20 Apr 2020 07:56:38 -0000 https://sourceware.org/bugzilla/show_bug.cgi?id=3D25858 --- Comment #1 from Tom de Vries --- The minimal symbol NoDebugMixedCaseFunc has this address: ... $ nm outputs/gdb.ada/bp_c_mixed_case/foo_h731_021 | grep NoDebugMixedCaseFu= nc 0000000000401f7a T NoDebugMixedCaseFunc ... and originates from source file qux.c, which is compiled without debug info. But during the process of setting the breakpoint, we try to find out the source/line info for the function, and hit find_pc_sect_compunit_symtab, wh= ich returns the symtab for crtn.S. The corresponding CU in the debug info looks like this: ... <0><1ff76>: Abbrev Number: 1 (DW_TAG_compile_unit) <1ff77> DW_AT_stmt_list : 0x513d <1ff7b> DW_AT_ranges : 0x3490 <1ff7f> DW_AT_name : ../sysdeps/x86_64/crtn.S <1ff83> DW_AT_comp_dir : /home/abuild/rpmbuild/BUILD/glibc-2.26/csu <1ff87> DW_AT_producer : GNU AS 2.32.0 <1ff8b> DW_AT_language : 32769 (MIPS assembler) ... and the DW_AT_ranges attribute refers to: ... 00003490 ffffffffffffffff 0000000000000000 (base address) 00003490 0000000000401822 0000000000401827 00003490 000000000040dc98 000000000040dc9d 00003490 ... So, the address of NoDebugMixedCaseFunc 0x401f7e doesn't fall in any of the= two ranges, but the global block for the CU has these BLOCK_START/BLOCK_END/BLOCK_RANGES values: ... (gdb) p /x b.startaddr $8 =3D 0x401822 (gdb) p /x b.endaddr $9 =3D 0x40dc9d (gdb) p b->ranges $10 =3D (blockranges *) 0x0 ... so find_pc_sect_compunit_symtab decides that the symbol is part of that CU. Note btw that the static block does have ranges: ... (gdb) p /x cust->blockvector->block[1].startaddr $20 =3D 0x401822 (gdb) p /x cust->blockvector->block[1].endaddr $21 =3D 0x40dc9d (gdb) p cust->blockvector->block[1].ranges $22 =3D (blockranges *) 0x1ca6860 (gdb) p /x cust->blockvector->block[1].ranges.range[0] $24 =3D {startaddr =3D 0x401822, endaddr =3D 0x401827} (gdb) p /x cust->blockvector->block[1].ranges.range[1] $25 =3D {startaddr =3D 0x40dc98, endaddr =3D 0x40dc9d} ... --=20 You are receiving this mail because: You are on the CC list for the bug.=