From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 916 invoked by alias); 5 Jan 2011 20:23:19 -0000 Received: (qmail 907 invoked by uid 22791); 5 Jan 2011 20:23:18 -0000 X-SWARE-Spam-Status: No, hits=-5.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; Wed, 05 Jan 2011 20:23:13 +0000 Received: from int-mx02.intmail.prod.int.phx2.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id p05KN9Bi028571 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Wed, 5 Jan 2011 15:23:09 -0500 Received: from localhost.localdomain (ovpn01.gateway.prod.ext.phx2.redhat.com [10.5.9.1]) by int-mx02.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id p05KN7qo002327; Wed, 5 Jan 2011 15:23:08 -0500 From: Phil Muldoon To: Tom Tromey Cc: Doug Evans , gdb-patches@sourceware.org Subject: Re: [patch] Add an evaluation function hook to Python breakpoints. References: Reply-to: pmuldoon@redhat.com X-URL: http://www.redhat.com Date: Wed, 05 Jan 2011 20:23:00 -0000 In-Reply-To: (Tom Tromey's message of "Wed, 05 Jan 2011 11:35:12 -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 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: 2011-01/txt/msg00085.txt.bz2 Tom Tromey writes: >>>>>> "Doug" == Doug Evans writes: I just came back from Christmas vacation today, so apologies for this thread time-gap. > Doug> The user will see the normal breakpoint output, and then be expected > Doug> to know that the breakpoint is special (e.g., a rule was violated and > Doug> that s/he needs to pay attention to what the rule was). Is there a > Doug> plan to have something more? [Or am I missing something?] > > Yeah, we want to expose some of the breakpoint_ops stuff to python. Yeah ultimately this was going to be series of patches (the first being this, the ability to write conditions entirely within Python), but the whole-story (from these threads) has probably shown we need to think about the solution in totality, not incrementally. > Doug> Sorry, maybe I was too subtle. > Doug> If one is using this facility to implement a rule checker that stops > Doug> when the rule is violated, and one sets another breakpoint at the same > Doug> location, when the program stops how does one know whether the rule > Doug> was violated or not? > > One does not. This is a pre-existing problem in gdb. > > > Phil, let's withdraw this patch until some later time when we have > worked out the issues. We can continue to discuss on the archer list. > > I think we should at least deal with exposing to Python the bits needed > to customize breakpoint notifications. > > Also we should write a couple real-life uses of this to make sure it is > working ok. That's ok, no worries. On that note, I keep a separate branch of my Python breakpoints improvements patches over on archer within the archer-pmuldoon-python-breakpoints branch. That is always open for folks to pull and comment on. We need to determine a concrete API plan though. What do we need these improvements to do? The only concrete action I saw was the ability to override breakpoint operations. (And probably a callback into the python api to return the appropriate message). What else? Cheers Phil