From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 2416 invoked by alias); 23 Jul 2012 16:07:49 -0000 Received: (qmail 2398 invoked by uid 22791); 23 Jul 2012 16:07:46 -0000 X-SWARE-Spam-Status: No, hits=-4.3 required=5.0 tests=AWL,BAYES_00,KHOP_RCVD_UNTRUST,KHOP_THREADED,RCVD_IN_HOSTKARMA_W,RCVD_IN_HOSTKARMA_WL X-Spam-Check-By: sourceware.org Received: from relay1.mentorg.com (HELO relay1.mentorg.com) (192.94.38.131) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Mon, 23 Jul 2012 16:07:30 +0000 Received: from svr-orw-exc-10.mgc.mentorg.com ([147.34.98.58]) by relay1.mentorg.com with esmtp id 1StLAO-0003hG-VN from Yao_Qi@mentor.com ; Mon, 23 Jul 2012 09:07:28 -0700 Received: from SVR-ORW-FEM-03.mgc.mentorg.com ([147.34.97.39]) by SVR-ORW-EXC-10.mgc.mentorg.com with Microsoft SMTPSVC(6.0.3790.4675); Mon, 23 Jul 2012 09:07:31 -0700 Received: from qiyao.dyndns.org (147.34.91.1) by svr-orw-fem-03.mgc.mentorg.com (147.34.97.39) with Microsoft SMTP Server id 14.1.289.1; Mon, 23 Jul 2012 09:07:27 -0700 From: Yao Qi To: CC: Subject: Re: [RFC] remove set_tfile_traceframe and cur_traceframe_number Date: Mon, 23 Jul 2012 16:07:00 -0000 Message-ID: <3284947.P03SIJ4rnz@qiyao.dyndns.org> User-Agent: KMail/4.8.3 (Linux/3.3.7-1.fc16.i686; KDE/4.8.3; i686; ; ) In-Reply-To: <1340804875-23979-1-git-send-email-yao@codesourcery.com> References: <1340804875-23979-1-git-send-email-yao@codesourcery.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2012-07/txt/msg00454.txt.bz2 On Wednesday, June 27, 2012 09:47:55 PM Yao Qi wrote: > I can't see the necessity to use function set_tfile_traceframe and > variable cur_traceframe_number. IIUC, both set_tfile_traceframe > and cur_traceframe_number are equivalent to remote.c:set_remote_traceframe > and remote.c:remote_traceframe_number. set_remote_traceframe > and remote_traceframe_number are used to switch between traceframe > and live inferior in a lazy mode. However, this requirement doesn't > exists in tfile, because GDB only reads from trace file. This is > the reason I propose to remove them. Regression tested on native > and gdbserver on x86_64-linux. OK to apply? The code this patch tries to remove was added by Pedro in this patch, [unavailable values part 1, 05/17] move traceframe memory reading fallbac= k=20 to read-only sections to GDB side http://sourceware.org/ml/gdb-patches/2011-02/msg00136.html in order to make GDB to read read-only memory from the live target. Pedro'= s=20 patch did something similar to both remote target and tfile target. It mak= es=20 sense to remote target, because there is a live inferior that GDB can acces= s.=20=20 However, it is not necessary for tfile target, because there is no live=20 inferior at all. IMO, it is correct to remove them in this patch. --=20 Yao (=E9=BD=90=E5=B0=A7)