From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 22225 invoked by alias); 5 May 2011 20:50:03 -0000 Received: (qmail 22087 invoked by uid 22791); 5 May 2011 20:50:00 -0000 X-SWARE-Spam-Status: No, hits=-6.9 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_HI,SPF_HELO_PASS,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 05 May 2011 20:49:39 +0000 Received: from int-mx10.intmail.prod.int.phx2.redhat.com (int-mx10.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id p45KnGgk029357 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Thu, 5 May 2011 16:49:16 -0400 Received: from ns3.rdu.redhat.com (ns3.rdu.redhat.com [10.11.255.199]) by int-mx10.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id p45KnGbl007524; Thu, 5 May 2011 16:49:16 -0400 Received: from opsy.redhat.com (ovpn01.gateway.prod.ext.phx2.redhat.com [10.5.9.1]) by ns3.rdu.redhat.com (8.13.8/8.13.8) with ESMTP id p45KnFsD001000; Thu, 5 May 2011 16:49:15 -0400 Received: by opsy.redhat.com (Postfix, from userid 500) id D353B3784C3; Thu, 5 May 2011 14:49:14 -0600 (MDT) From: Tom Tromey To: Joel Brobecker Cc: gdb-patches@sourceware.org Subject: Re: [RFC] canonical linespec and multiple breakpoints ... References: <20110505162855.GA2546@adacore.com> Date: Thu, 05 May 2011 20:50:00 -0000 In-Reply-To: <20110505162855.GA2546@adacore.com> (Joel Brobecker's message of "Thu, 5 May 2011 09:28:55 -0700") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii 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: 2011-05/txt/msg00158.txt.bz2 >>>>> "Joel" == Joel Brobecker writes: Joel> If we agree that a breakpoint expression (linespec) that gets resolved Joel> into multiple source locations (slocs) should result in one breakpoint Joel> per sloc, then we can start working on that. I am not sure about this plan. I think it relies on being able to differentiate breakpoints based on canonical linespecs, but I don't think it is always possible to construct these. E.g., consider the case where a linespec resolves to two locations, one of which does not have debuginfo. What is the canonical linespec for the debuginfo-less location? What if there are three locations and two of them don't have debuginfo? I.e., are those two consolidated into a single breakpoint? What would its canonical linespec be? Or if not consolidated, etc. Joel> We would rather let the C++ bits to someone else, as we still have Joel> limited experience with C++ itself. Sounds good to me. Joel> We think that this will handle most situations, except the situation Joel> where new symbols cause extra slocs to appear (typically, a shared Joel> library gets mapped in memory). We are planing on plugging that hole Joel> as a followup, which can be made independently, for instance using Joel> Pedro's idea of introducing an extra level of breakpoint. The exact Joel> details on how this is going to be done need to be discussed, but, Joel> in the meantime, our experience with Ada show that the approach Joel> we are proposing as a first step has been working well for our users. I would rather start with a comprehensive plan. My concern about approaching this piecemeal is that I think dealing with changes in the inferior will necessitate changes in the basic approach. Also, I think to get the SystemTap patch set in, I have to solve the bigger problem anyhow. That is, I have to start there, at least as I understand the current situation. I keep coming back to the "simple" approach I sketched here: http://sourceware.org/ml/gdb-patches/2011-04/msg00567.html I can try to write this up into a fuller proposal if you want. While looking into this area I made a list of difficulties and considerations that I know of. I can write that up in a readable form if you think that would help. Tom