From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 17835 invoked by alias); 18 Nov 2003 05:33:09 -0000 Mailing-List: contact gdb-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 17794 invoked from network); 18 Nov 2003 05:33:08 -0000 Received: from unknown (HELO web13804.mail.yahoo.com) (216.136.175.14) by sources.redhat.com with SMTP; 18 Nov 2003 05:33:08 -0000 Message-ID: <20031118053305.43584.qmail@web13804.mail.yahoo.com> Received: from [24.59.142.117] by web13804.mail.yahoo.com via HTTP; Mon, 17 Nov 2003 21:33:05 PST Date: Tue, 18 Nov 2003 05:33:00 -0000 From: Mark Newman Subject: Re: async operation To: Andrew Cagney , "Newman, Mark \(N-Superior Technical Resource Inc\)" Cc: gdb@sources.redhat.com In-Reply-To: <3FB9986F.2030405@gnu.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-SW-Source: 2003-11/txt/msg00138.txt.bz2 --- Andrew Cagney wrote: > > No response on this - so I am going to change GDB > so that it will correctly handle an "interrupt" > command to stop the inferior when in async mode. > > Well you did post on a Saturday ;-) Sorry - contract is coming to an end - again. > > > I tried using the "stop" command which makes it > through the async filtering in top.c - however stop > simply says it is not a valid command. There is > logic in here for cleanly stopping when a break > occurs (?) but I can't find any to allow the > operator to stop the target? > > I think the description for "stop" explains why that > does nothing: > > if (!dbx_commands) > stop_command = > add_cmd ("stop", class_obscure, > not_just_help_class_command, > "There is no > `stop' command, but you can set a hook on `stop'.\n\ > This allows you to set a list of commands to be run > each time execution\n\ > of the program stops.", &cmdlist); > I don't mean to sound dumb but could you clarify what "you can set a hook on `stop'" means? I want to allow an engineer to (for example) be able to stop a running async process and set additional tracepoints. The engineer would then be able to "cont &" to continue the process. > > I add'ed "interrupt" to the filtering but it does > not clear the target_executing flag. > > You should see "fetch_inferior_event" clear that > flag after it's > received notification that the target really has > stopped. > I see that and am working it now in conjunction with the interrupt command - unless the stop command(?) will do what I am looking for. GDBserver does not properly respond when in async and an "interrupt" is issued. > Andrew > >