From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 26327 invoked by alias); 1 Nov 2012 00:34:26 -0000 Received: (qmail 26221 invoked by uid 22791); 1 Nov 2012 00:34:25 -0000 X-SWARE-Spam-Status: No, hits=-4.5 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; Thu, 01 Nov 2012 00:34:22 +0000 Received: from svr-orw-fem-01.mgc.mentorg.com ([147.34.98.93]) by relay1.mentorg.com with esmtp id 1TTijk-0005JN-Vn from Yao_Qi@mentor.com ; Wed, 31 Oct 2012 17:34:21 -0700 Received: from SVR-ORW-FEM-02.mgc.mentorg.com ([147.34.96.206]) by svr-orw-fem-01.mgc.mentorg.com over TLS secured channel with Microsoft SMTPSVC(6.0.3790.4675); Wed, 31 Oct 2012 17:34:20 -0700 Received: from qiyao.dyndns.org (147.34.91.1) by svr-orw-fem-02.mgc.mentorg.com (147.34.96.168) with Microsoft SMTP Server id 14.1.289.1; Wed, 31 Oct 2012 17:34:19 -0700 Message-ID: <5091C383.1080705@codesourcery.com> Date: Thu, 01 Nov 2012 00:34:00 -0000 From: Yao Qi User-Agent: Mozilla/5.0 (X11; Linux i686; rv:15.0) Gecko/20120911 Thunderbird/15.0.1 MIME-Version: 1.0 To: Pedro Alves CC: Subject: Re: [PATCH 2/2] new tracepoint downloaded MI notification. References: <1348793347-12556-1-git-send-email-yao@codesourcery.com> <1348793347-12556-3-git-send-email-yao@codesourcery.com> <5065E1E9.5040204@redhat.com> <5065E292.4000606@redhat.com> <506701EC.7040703@codesourcery.com> <509166FD.3050805@redhat.com> In-Reply-To: <509166FD.3050805@redhat.com> Content-Type: text/plain; charset="ISO-8859-1"; format=flowed Content-Transfer-Encoding: 7bit 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-11/txt/msg00001.txt.bz2 On 11/01/2012 01:59 AM, Pedro Alves wrote: >> From the frontend's point of view, {number, location number} is better, and the schema "number.location_number" has been used in "=breakpoint-modified" notification. However, if we want to use {number, location number} here, we have to guarantee that the location number is an attribute of bp_location, because: > This is not a particular issue of tracepoint locations, so, if it was a problem, it > would be a problem for the existing notifications and MI commands as well. > > IOW, this would need to be fixed for all those other cases that expose location > numbers, not just come up with an ad hoc solution. > I agree. > IOW, there's no good justification for deviating this notification from > existing practice. > What do you mean by "existing practice"? Is {number, location number} the "existing practise"? >> >In short, if we can make location number persistent (unchanged for a given bp_location object), then {number, location number} is fine, otherwise, I'd prefer {number, address}. > {number, address} may looks stabler, but not even that is completely stable. > Change the program's code a little, recompile, reload symbols, and you'll see the > address change. Whatever smarts you'd want the frontend to have to track > locations, GDB could do instead, once for all frontends, and better, because ^^^^^^^^^ IIUC, "locations" here mean location address instead of location number. > it may use properties other than the address to decided whether a new instance > of a location is logically the same as the old one (think of stap probes or static > tracepoints, where the address is really a very low target side detail; or just > consider line number instead of address). I think all this goes hand in hand with > redesigning how GDB handles breakpoint re-setting (or rather, get rid of re-setting as is), > which will make this whole stabler locations issue better. Keith will be going to > work on that very soon, IIUC. FAOD, we should continue to use {number, location number}, and it requires improvement of breakpoint re-setting, correct? -- Yao