From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 31684 invoked by alias); 11 Sep 2012 18:09:13 -0000 Received: (qmail 31667 invoked by uid 22791); 11 Sep 2012 18:09:11 -0000 X-SWARE-Spam-Status: No, hits=-7.7 required=5.0 tests=AWL,BAYES_00,KHOP_RCVD_UNTRUST,KHOP_THREADED,RCVD_IN_DNSWL_HI,RCVD_IN_HOSTKARMA_W,RP_MATCHES_RCVD,SPF_HELO_PASS,TW_DB 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; Tue, 11 Sep 2012 18:08:54 +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.14.4/8.14.4) with ESMTP id q8BI8p1m025600 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Tue, 11 Sep 2012 14:08:51 -0400 Received: from [127.0.0.1] (ovpn01.gateway.prod.ext.ams2.redhat.com [10.39.146.11]) by int-mx02.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id q8BI8nm7008548; Tue, 11 Sep 2012 14:08:50 -0400 Message-ID: <504F7E31.10306@redhat.com> Date: Tue, 11 Sep 2012 18:09:00 -0000 From: Pedro Alves User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:15.0) Gecko/20120828 Thunderbird/15.0 MIME-Version: 1.0 To: LRN CC: Eli Zaretskii , gdb-patches@sourceware.org Subject: Re: [Bug win32/14529] Make gdb capable of JIT-debugging on W32 References: <503E575D.1000608@gmail.com> <83y5kvp0za.fsf@gnu.org> <5040DA38.2070802@gmail.com> In-Reply-To: <5040DA38.2070802@gmail.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit 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-09/txt/msg00166.txt.bz2 On 08/31/2012 04:37 PM, LRN wrote: >>> >> @@ -1055,6 +1065,7 @@ Options:\n\n\ --dbx DBX >>> >> compatibility mode.\n\ --directory=DIR Search for source files >>> >> in DIR.\n\ --epoch Output information used by epoch >>> >> emacs-GDB interface.\n\ + --event=EVENT Signal the EVENT >>> >> when attached to a process. W32 only.\n\ >> > >> > And also this part. > They were, initially. However, gdb contribution documentation said > that gdb devs frown upon extra #ifdefs in files that are not > platform-specific. > The code is mostly platform independent, it's the two W32API functions > that only work on W32 (and you can write non-W32 equivalent, if you > figure out how to make it work). Thus, i removed extra #ifdefs in > main.c and other files. Please consider also cross builds. IOW, a gdb hosted on Windows, but that is built to target something else. In that case, as is, you will end up with the option compiled in. But if you remove any mention that this is for Windows only, it'll be confusing. I'd maybe go as far as renaming the option to --w32-jit-event or --aedebug-event, or some such. Alternatively, and perhaps it really is a better option, get rid of the --event option, but make this a real command, implemented in windows-nat.c, so that the user has better control of when to signal the event, like: gdb -ex "foo" -ex "bar" -ex "attach PID" -ex "signal-aedebug-event FOO" -- Pedro Alves