From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 17549 invoked by alias); 6 Mar 2004 17:11:14 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 17539 invoked from network); 6 Mar 2004 17:11:14 -0000 Received: from unknown (HELO nevyn.them.org) (66.93.172.17) by sources.redhat.com with SMTP; 6 Mar 2004 17:11:14 -0000 Received: from drow by nevyn.them.org with local (Exim 4.30 #1 (Debian)) id 1AzfKT-000628-Ac; Sat, 06 Mar 2004 12:11:13 -0500 Date: Fri, 19 Mar 2004 00:09:00 -0000 From: Daniel Jacobowitz To: Atsushi Nemoto Cc: gdb-patches@sources.redhat.com Subject: Re: remote debugging a multi-threaded program with signal Message-ID: <20040306171112.GA23154@nevyn.them.org> Mail-Followup-To: Atsushi Nemoto , gdb-patches@sources.redhat.com References: <20040305.112722.74754522.nemoto@toshiba-tops.co.jp> <20040306.014343.74756819.anemo@mba.ocn.ne.jp> <20040305163854.GA23778@nevyn.them.org> <20040306.215001.74755311.anemo@mba.ocn.ne.jp> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20040306.215001.74755311.anemo@mba.ocn.ne.jp> User-Agent: Mutt/1.5.1i X-SW-Source: 2004-03/txt/msg00126.txt.bz2 On Sat, Mar 06, 2004 at 09:50:01PM +0900, Atsushi Nemoto wrote: > >>>>> On Fri, 5 Mar 2004 11:38:54 -0500, Daniel Jacobowitz said: > > >> For gdb without verbose-resume, how about this patch? With this > >> patch, gdbserver uses general_thread instead of all_threads.head if > >> 'CNN' packet was sent without preceding 'HcNN'. > > drow> For one thing, I'm not sure it will work. But for another, why > drow> is this case important to you? > > It solves at least my program case, and I believe it breaks nothing. > > I'm still sometimes using (slightly patched) gdb 5.3. If I can solve > the problem with verbose-resume disabled in current gdb, I suppose the > fixes can be backported to gdb 5.3 easily. I already tried your fix of > infrun.c with gdb 5.3 and found it solves a part of problem. > > drow> Without vCont the problem is fundamentally insoluble; there will > drow> always be a case in which gdbserver mis-guesses which thread it > drow> should continue. That's why I had to come up with a protocol > drow> change. > > Hmm... then it might be better to backport all vCont stuff? Of course > upgrading to upcoming gdb 6.1 will be the best solution, but I can not > for now by some internal reason ... :-\ Yes, I would rather you backport vCont than we add hacks to gdbserver to guess :) I can tell you that the only changes to support vCont (as far as I remember, anyway) were in remote.c. It was pretty simple client-side. -- Daniel Jacobowitz MontaVista Software Debian GNU/Linux Developer From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 17549 invoked by alias); 6 Mar 2004 17:11:14 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 17539 invoked from network); 6 Mar 2004 17:11:14 -0000 Received: from unknown (HELO nevyn.them.org) (66.93.172.17) by sources.redhat.com with SMTP; 6 Mar 2004 17:11:14 -0000 Received: from drow by nevyn.them.org with local (Exim 4.30 #1 (Debian)) id 1AzfKT-000628-Ac; Sat, 06 Mar 2004 12:11:13 -0500 Date: Sat, 06 Mar 2004 17:11:00 -0000 From: Daniel Jacobowitz To: Atsushi Nemoto Cc: gdb-patches@sources.redhat.com Subject: Re: remote debugging a multi-threaded program with signal Message-ID: <20040306171112.GA23154@nevyn.them.org> Mail-Followup-To: Atsushi Nemoto , gdb-patches@sources.redhat.com References: <20040305.112722.74754522.nemoto@toshiba-tops.co.jp> <20040306.014343.74756819.anemo@mba.ocn.ne.jp> <20040305163854.GA23778@nevyn.them.org> <20040306.215001.74755311.anemo@mba.ocn.ne.jp> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20040306.215001.74755311.anemo@mba.ocn.ne.jp> User-Agent: Mutt/1.5.1i X-SW-Source: 2004-03.o/txt/msg00126.txt Message-ID: <20040306171100.Bv2JA4jsQagE-YIC7fY_YQAZWpNAioarPcGuAR81uJA@z> On Sat, Mar 06, 2004 at 09:50:01PM +0900, Atsushi Nemoto wrote: > >>>>> On Fri, 5 Mar 2004 11:38:54 -0500, Daniel Jacobowitz said: > > >> For gdb without verbose-resume, how about this patch? With this > >> patch, gdbserver uses general_thread instead of all_threads.head if > >> 'CNN' packet was sent without preceding 'HcNN'. > > drow> For one thing, I'm not sure it will work. But for another, why > drow> is this case important to you? > > It solves at least my program case, and I believe it breaks nothing. > > I'm still sometimes using (slightly patched) gdb 5.3. If I can solve > the problem with verbose-resume disabled in current gdb, I suppose the > fixes can be backported to gdb 5.3 easily. I already tried your fix of > infrun.c with gdb 5.3 and found it solves a part of problem. > > drow> Without vCont the problem is fundamentally insoluble; there will > drow> always be a case in which gdbserver mis-guesses which thread it > drow> should continue. That's why I had to come up with a protocol > drow> change. > > Hmm... then it might be better to backport all vCont stuff? Of course > upgrading to upcoming gdb 6.1 will be the best solution, but I can not > for now by some internal reason ... :-\ Yes, I would rather you backport vCont than we add hacks to gdbserver to guess :) I can tell you that the only changes to support vCont (as far as I remember, anyway) were in remote.c. It was pretty simple client-side. -- Daniel Jacobowitz MontaVista Software Debian GNU/Linux Developer