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 3E9423858292 for ; Fri, 17 Jun 2022 11:18:48 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 3E9423858292 Received: from fencepost.gnu.org ([2001:470:142:3::e]:47288) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1o29xt-0004UK-PG; Fri, 17 Jun 2022 07:16:37 -0400 Received: from [87.69.77.57] (port=1757 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 1o29xs-0000Pf-Du; Fri, 17 Jun 2022 07:16:37 -0400 Date: Fri, 17 Jun 2022 14:16:32 +0300 Message-Id: <835ykzpmjz.fsf@gnu.org> From: Eli Zaretskii To: Andrew Burgess Cc: gdb-patches@sourceware.org In-Reply-To: (message from Andrew Burgess via Gdb-patches on Fri, 17 Jun 2022 11:36:02 +0100) Subject: Re: [PATCH 2/2] gdb: add support for disassembler styling using libopcodes References: X-Spam-Status: No, score=1.4 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, RCVD_IN_BARRACUDACENTRAL, SPF_HELO_PASS, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Level: * X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) 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, 17 Jun 2022 11:18:49 -0000 > Date: Fri, 17 Jun 2022 11:36:02 +0100 > From: Andrew Burgess via Gdb-patches > Cc: Andrew Burgess > > gdb/NEWS | 28 +++++++ > gdb/cli/cli-style.c | 107 +++++++++++++++++++++++--- > gdb/cli/cli-style.h | 28 +++++-- > gdb/disasm.c | 184 ++++++++++++++++++++++++++++++++++++++++++-- > gdb/disasm.h | 16 ++++ > gdb/doc/gdb.texinfo | 100 +++++++++++++++++++++++- > 6 files changed, 437 insertions(+), 26 deletions(-) Thanks, the documentation parts are approved, with these minor nits: > @@ -26485,13 +26486,30 @@ > general is enabled (with @code{set style enabled on}), and if a source > highlighting library is available to @value{GDBN}. > > -To highlight disassembler output, @value{GDBN} must be compiled with > -Python support, and the Python Pygments package must be available. If > -these requirements are not met then @value{GDBN} will not highlight > -disassembler output, even when this option is @samp{on}. > +The two source highlighting libraries that @value{GDBN} could use are; > +@value{GDBN}'s builtin disassembler, or the Python Pygments package. The original text explicitly talked about styling disassembler output, whereas the new text omits that qualification, and sounds as if it is talking about styling in general. Although this is in a section about disassembly, I'd prefer to keep the original qualification. > +If neither of these options are available then @value{GDBN} will > +produce unstyled output, even when this setting is @samp{on}. Same here. > +@item disassembler immediate > +Control the styling of numeric operands in the disassembler output. > +These are managed with the @code{set style disassembler immediate} > +family of commands. This style is not used for instruction operands > +that represent addresses, in that case the @samp{disassembler address} > +style is used. This style is only used when @value{GDBN} is styling ^^ Two spaces between sentences. > +@anchor{maint_libopcodes_styling} > +@kindex maint set libopcodes-styling enabled > +@kindex maint show libopcodes-styling enabled > +@item maint set libopcodes-styling enabled @r{[}on|off@r{]} > +@itemx maint show libopcodes-styling enabled > +Control whether @value{GDBN} should use its builtin disassembler > +(libopcodes) to style disassembler output (@pxref{Output Styling}). ^^^^^^^^^^ "libopcodes" should have the @file markup.