From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 23902 invoked by alias); 25 Feb 2013 23:02:04 -0000 Received: (qmail 23887 invoked by uid 22791); 25 Feb 2013 23:02:02 -0000 X-SWARE-Spam-Status: No, hits=-5.9 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,KHOP_RCVD_TRUST,KHOP_THREADED,RCVD_IN_DNSWL_LOW,RCVD_IN_HOSTKARMA_YE,RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mail-ee0-f42.google.com (HELO mail-ee0-f42.google.com) (74.125.83.42) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Mon, 25 Feb 2013 23:01:53 +0000 Received: by mail-ee0-f42.google.com with SMTP id b47so1742963eek.15 for ; Mon, 25 Feb 2013 15:01:52 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:content-type:x-gm-message-state; bh=utBwHrgklZBlJorGfmkFHU5pGwmgQs2WgLHdhdc2FP8=; b=bqlrbWNynnIFywMhghQqEUF5VDrzM+1PK7DaNu2acrU3HSwoSsiFSwSU693mJ54OtQ 7InqFuiklB4fJm89tsWLuf7TBth1t7UUITT749E+YWZwtcMVFoyBj0/aIme1JNFKXXh2 l30cEiCbk9pKlcNlaZph1g/S/cQ9Z7GKWkwcjyKvGCPALTvwduEkJta5kzBr8u7rElk0 AxjYklyWpblNtGAte9PGzbNWFyydXEm/NXD4f7+5LXj52dhxqv5iqZzupu6i4mph0ug7 XyD+ZiS9ivLH4S8kVrHwNKD7IL0bw4jO+BcbfxvPzQchGUsVvFZ66VaFdQhHJAkqKdqg k6Aw== MIME-Version: 1.0 X-Received: by 10.14.175.129 with SMTP id z1mr43924624eel.7.1361833311714; Mon, 25 Feb 2013 15:01:51 -0800 (PST) Received: by 10.14.96.74 with HTTP; Mon, 25 Feb 2013 15:01:51 -0800 (PST) In-Reply-To: References: Date: Mon, 25 Feb 2013 23:02:00 -0000 Message-ID: Subject: Re: [RFC] Debug Methods in GDB Python From: Siva Chandra To: gdb-patches@sourceware.org Content-Type: text/plain; charset=ISO-8859-1 X-Gm-Message-State: ALoCoQljN4NdV9FYEloFpLnc3YA+Ox8SBCWEjr62UdsM5/eNihAIBNAi66zrHpFEuX85WCG/2NelAruV/snezUGZ+0ik54CEU4KBICagavnGv4cmIZNghOtkIK4HZb4gJs497RCKtGDKXM9D7SLgdi4KVYFVnm+Ej+00fAkOHNA5mzYzEpibSa3h6oWYd5L4BT1+q25iEL5i4mm4OS44SbuOkJF1Xqi8gw== 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: 2013-02/txt/msg00636.txt.bz2 Friendly ping: Is there any feedback on the patch? I do not want to get into tests and docs without first clearing the basics of the patch. On Mon, Jan 28, 2013 at 5:49 PM, Siva Chandra wrote: > Attached is a new version of the patch which I have now regression > tested. Except for tests and docs, I think it is complete wrt the > feature set I have in mind. Hence, the caveats from the previous mail > still apply. > > 2013-01-01 Siva Chandra Reddy > > * Makefile.in: Add entries for new files > * data-directory/Makefile.in: Add entery for new Python file > * eval.c: Use new 'find_overload_match' signature. > * ext-function.c: Support for working with functions/methods > defined in an extension language. > * ext-function.h: Support for working with functions/methods > defined in an extension language. > * python/lib/gdb/debugmethods.py: Python side of the support > for debug methods in Python. > * python/py-debugmethods.c: C side of the support for debug > methods in Python. > * python/py-objfile.c: Add 'debug_methods' attribute to > gdb.Objfile. > * python/python-internal.h: Add new function > gdb.enable_debug_methods to the Python module 'gdb'. > * python/python.c: Add new function gdb.enable_debug_methods to > the Python module 'gdb'. > * python/python.h: Add declarations of new functions. > * valarith.c: Use methods defined in extension languages. > * valops.c: Use methods defined in extension languages. > * value.h: New signature for 'find_overload_match'. > > On Mon, Jan 7, 2013 at 1:21 PM, Siva Chandra wrote: >> 1. The patch is incomplete in the sense that tests and documentation >> are missing. Also, ways to enable and disable single or group of debug >> methods is missing. At this point, I am looking for feedback on my >> direction and the way I am intercepting the normal GDB flow to lookup >> methods defined in Python. I will work on completing the patch once >> there is an agreement on these basics. >> >> 2. I did not intend to provide a way for the user to define new or >> override static methods via Python. >> >> 3. I did not intend to provide a way for the user to define new >> virtual methods in Python. The user can however override existing >> virtual and non-virtual methods. The user can also define new >> non-virtual methods in Python. >> >> 4. Doug suggested that I use the C++ infrastructure in GDB as much as >> possible. I feel I have done so.