Message ID | 20221206135729.3937767-12-simon.marchi@efficios.com |
---|---|
State | Committed |
Commit | 8b588f42120f1a39d32116c2bf3e53981d906a02 |
Headers |
Return-Path: <gdb-patches-bounces+patchwork=sourceware.org@sourceware.org> X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 054C2384231B for <patchwork@sourceware.org>; Tue, 6 Dec 2022 14:00:17 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 054C2384231B DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1670335217; bh=8T37WLmRrUg37gS0zwAO0PU29P7FzJ18XksJLuZk1k0=; h=To:Cc:Subject:Date:In-Reply-To:References:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From:Reply-To:From; b=oU9C026uisd9rjzTRRXBXgu7p5RlV5PzjTxa39pAiOEeZUy0dcxqppsPTqCqYnver V5A7nTx6kYSwdlRG5j3ILDQT7YHgG/eOhc1OvHyrEHN7SXhE9zd6Xq/oAeSkgM7i9q 0oQvOalJmgvwD+C4YusaU9NqgRenQsjFjbkcjA9c= X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from barracuda.ebox.ca (barracuda.ebox.ca [96.127.255.19]) by sourceware.org (Postfix) with ESMTPS id B9A6938469BA for <gdb-patches@sourceware.org>; Tue, 6 Dec 2022 13:58:34 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org B9A6938469BA X-ASG-Debug-ID: 1670335113-0c856e762b1bc40001-fS2M51 Received: from smtp.ebox.ca (smtp.ebox.ca [96.127.255.82]) by barracuda.ebox.ca with ESMTP id RacmOdscdx3Gj9Z6 (version=TLSv1 cipher=AES128-SHA bits=128 verify=NO); Tue, 06 Dec 2022 08:58:33 -0500 (EST) X-Barracuda-Envelope-From: simon.marchi@efficios.com X-Barracuda-RBL-Trusted-Forwarder: 96.127.255.82 Received: from epycamd.internal.efficios.com (192-222-180-24.qc.cable.ebox.net [192.222.180.24]) by smtp.ebox.ca (Postfix) with ESMTP id 4AFE2441D64; Tue, 6 Dec 2022 08:58:33 -0500 (EST) X-Barracuda-RBL-IP: 192.222.180.24 X-Barracuda-Effective-Source-IP: 192-222-180-24.qc.cable.ebox.net[192.222.180.24] X-Barracuda-Apparent-Source-IP: 192.222.180.24 To: gdb-patches@sourceware.org Cc: Simon Marchi <simon.marchi@efficios.com> Subject: [PATCH 11/12] gdb: make gdb_printing_disassembler::stream public Date: Tue, 6 Dec 2022 08:57:28 -0500 X-ASG-Orig-Subj: [PATCH 11/12] gdb: make gdb_printing_disassembler::stream public Message-Id: <20221206135729.3937767-12-simon.marchi@efficios.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221206135729.3937767-1-simon.marchi@efficios.com> References: <20221206135729.3937767-1-simon.marchi@efficios.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Barracuda-Connect: smtp.ebox.ca[96.127.255.82] X-Barracuda-Start-Time: 1670335113 X-Barracuda-Encrypted: AES128-SHA X-Barracuda-URL: https://96.127.255.19:443/cgi-mod/mark.cgi X-Virus-Scanned: by bsmtpd at ebox.ca X-Barracuda-Scan-Msg-Size: 1093 X-Barracuda-BRTS-Status: 1 X-Barracuda-Spam-Score: 0.00 X-Barracuda-Spam-Status: No, SCORE=0.00 using global scores of TAG_LEVEL=1000.0 QUARANTINE_LEVEL=1000.0 KILL_LEVEL=5.0 tests= X-Barracuda-Spam-Report: Code version 3.2, rules version 3.2.3.102645 Rule breakdown below pts rule name description ---- ---------------------- -------------------------------------------------- X-Spam-Status: No, score=-3498.3 required=5.0 tests=BAYES_00, GIT_PATCH_0, KAM_DMARC_NONE, KAM_DMARC_STATUS, RCVD_IN_DNSWL_LOW, SPF_HELO_NONE, SPF_SOFTFAIL, TXREP autolearn=ham autolearn_force=no version=3.4.6 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 <gdb-patches.sourceware.org> List-Unsubscribe: <https://sourceware.org/mailman/options/gdb-patches>, <mailto:gdb-patches-request@sourceware.org?subject=unsubscribe> List-Archive: <https://sourceware.org/pipermail/gdb-patches/> List-Post: <mailto:gdb-patches@sourceware.org> List-Help: <mailto:gdb-patches-request@sourceware.org?subject=help> List-Subscribe: <https://sourceware.org/mailman/listinfo/gdb-patches>, <mailto:gdb-patches-request@sourceware.org?subject=subscribe> From: Simon Marchi via Gdb-patches <gdb-patches@sourceware.org> Reply-To: Simon Marchi <simon.marchi@efficios.com> Errors-To: gdb-patches-bounces+patchwork=sourceware.org@sourceware.org Sender: "Gdb-patches" <gdb-patches-bounces+patchwork=sourceware.org@sourceware.org> |
Series |
Initial support for ROCm platform (AMDGPU) debugging
|
|
Commit Message
Simon Marchi
Dec. 6, 2022, 1:57 p.m. UTC
In the ROCm port, we need to access the underlying stream of a gdb_printing_disassembler, so make it public. The reason we need to access it is to know whether it supports style escape code. We then pass that information to a temporary string_file we use while symbolizing addresses. Change-Id: Ib95755a4a45b8f6478787993e9f904df60dd8dc1 --- gdb/disasm.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
Comments
Simon Marchi via Gdb-patches <gdb-patches@sourceware.org> writes: > In the ROCm port, we need to access the underlying stream of a > gdb_printing_disassembler, so make it public. The reason we need to > access it is to know whether it supports style escape code. We then > pass that information to a temporary string_file we use while > symbolizing addresses. *sigh* I can't see a better way, so LGTM. Thanks, Andrew > > Change-Id: Ib95755a4a45b8f6478787993e9f904df60dd8dc1 > --- > gdb/disasm.h | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/gdb/disasm.h b/gdb/disasm.h > index d6aec9a4705..b78374dd63f 100644 > --- a/gdb/disasm.h > +++ b/gdb/disasm.h > @@ -123,12 +123,12 @@ struct gdb_printing_disassembler : public gdb_disassemble_info > { > DISABLE_COPY_AND_ASSIGN (gdb_printing_disassembler); > > -protected: > - > /* The stream that disassembler output is being written too. */ > struct ui_file *stream () > { return m_stream; } > > +protected: > + > /* Constructor. All the arguments are just passed to the parent class. > We also add the two print functions to the arguments passed to the > parent. See gdb_disassemble_info for a description of how the > -- > 2.38.1
diff --git a/gdb/disasm.h b/gdb/disasm.h index d6aec9a4705..b78374dd63f 100644 --- a/gdb/disasm.h +++ b/gdb/disasm.h @@ -123,12 +123,12 @@ struct gdb_printing_disassembler : public gdb_disassemble_info { DISABLE_COPY_AND_ASSIGN (gdb_printing_disassembler); -protected: - /* The stream that disassembler output is being written too. */ struct ui_file *stream () { return m_stream; } +protected: + /* Constructor. All the arguments are just passed to the parent class. We also add the two print functions to the arguments passed to the parent. See gdb_disassemble_info for a description of how the