From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from eggs.gnu.org (eggs.gnu.org [209.51.188.92]) by sourceware.org (Postfix) with ESMTPS id 19DD23858D3C for ; Fri, 18 Mar 2022 15:11:20 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 19DD23858D3C Received: from [2001:470:142:3::e] (port=49816 helo=fencepost.gnu.org) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nVEG6-0003dg-Qx; Fri, 18 Mar 2022 11:11:18 -0400 Received: from [87.69.77.57] (port=4622 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nVEG5-0002I7-O7; Fri, 18 Mar 2022 11:11:18 -0400 Date: Fri, 18 Mar 2022 17:11:16 +0200 Message-Id: <83v8wbfg8b.fsf@gnu.org> From: Eli Zaretskii To: Lancelot SIX Cc: gdb-patches@sourceware.org, lsix@lancelotsix.com In-Reply-To: <20220318142733.1097657-3-lancelot.six@amd.com> (message from Lancelot SIX via Gdb-patches on Fri, 18 Mar 2022 14:27:33 +0000) Subject: Re: [PATCH 2/2] gdb: Add support for DW_LNS_set_prologue_end in line-table References: <20220318142733.1097657-1-lancelot.six@amd.com> <20220318142733.1097657-3-lancelot.six@amd.com> X-Spam-Status: No, score=-8.5 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_BARRACUDACENTRAL, SPF_HELO_PASS, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 18 Mar 2022 15:11:22 -0000 > Date: Fri, 18 Mar 2022 14:27:33 +0000 > From: Lancelot SIX via Gdb-patches > Cc: lsix@lancelotsix.com, Lancelot SIX > > diff --git a/gdb/NEWS b/gdb/NEWS > index c609da7e6cf..89811219f59 100644 > --- a/gdb/NEWS > +++ b/gdb/NEWS > @@ -3,6 +3,10 @@ > > *** Changes since GDB 11 > > +* GDB now honours the DWARF prologue_end line-table entry flag the compiler can > + emit to indicate where a breakpoint should be placed to break in a function > + past its prologue. Should we tell what user-visible effects will this have? > diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo > index 729f9d79a93..568ac86f6fd 100644 > --- a/gdb/doc/gdb.texinfo > +++ b/gdb/doc/gdb.texinfo > @@ -19794,6 +19794,33 @@ line 1574. > List the @code{struct linetable} from all @code{struct symtab} > instances whose name matches @var{regexp}. If @var{regexp} is not > given, list the @code{struct linetable} from all @code{struct symtab}. > +For example: > + > +@smallexample > +(@value{GDBP}) maint info line-table > +objfile: /home/gnu/build/a.out ((struct objfile *) 0x6120000e0d40) > +compunit_symtab: simple.cpp ((struct compunit_symtab *) 0x6210000ff450) > +symtab: /home/gnu/src/simple.cpp ((struct symtab *) 0x6210000ff4d0) > +linetable: ((struct linetable *) 0x62100012b760): > +INDEX LINE ADDRESS IS-STMT PROLOGUE-END > +0 3 0x0000000000401110 Y > +1 4 0x0000000000401114 Y Y > +2 9 0x0000000000401120 Y > +3 10 0x0000000000401124 Y Y > +4 10 0x0000000000401129 > +5 15 0x0000000000401130 Y > +6 16 0x0000000000401134 Y Y > +7 16 0x0000000000401139 > +8 21 0x0000000000401140 Y > +9 22 0x000000000040114f Y Y > +10 22 0x0000000000401154 > +11 END 0x000000000040115a Y > +@end smallexample > +@noindent > +The @var{IS-STMT} column indicates if the address is a recommended breakpoint > +location to represent a line or a statement. The @var{PROLOGUE-END} column > +indicates that a given address is an adequate to place a breakpoint at the > +first instruction following a function prologue. IS-STMT and PROLOGUE-END should be in @samp, not @var. Those are literal headings of the columns, so @var is inappropriate for them. Thanks.