From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29449 invoked by alias); 6 Mar 2003 01:04:33 -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 29435 invoked from network); 6 Mar 2003 01:04:32 -0000 Received: from unknown (HELO crack.them.org) (65.125.64.184) by 172.16.49.205 with SMTP; 6 Mar 2003 01:04:32 -0000 Received: from nevyn.them.org ([66.93.61.169] ident=mail) by crack.them.org with asmtp (Exim 3.12 #1 (Debian)) id 18qlhY-0004bm-00; Wed, 05 Mar 2003 21:05:44 -0600 Received: from drow by nevyn.them.org with local (Exim 3.36 #1 (Debian)) id 18qjoC-0004fO-00; Wed, 05 Mar 2003 20:04:28 -0500 Date: Thu, 06 Mar 2003 01:04:00 -0000 From: Daniel Jacobowitz To: Andrew Cagney Cc: "J. Johnston" , gdb@sources.redhat.com Subject: Re: gcore and nptl threads on linux Message-ID: <20030306010428.GA17878@nevyn.them.org> Mail-Followup-To: Andrew Cagney , "J. Johnston" , gdb@sources.redhat.com References: <3E653983.8010005@redhat.com> <20030305005218.GA9222@nevyn.them.org> <3E662E68.7010205@redhat.com> <20030305172511.GB4425@nevyn.them.org> <3E669CA1.2010201@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <3E669CA1.2010201@redhat.com> User-Agent: Mutt/1.5.1i X-SW-Source: 2003-03/txt/msg00111.txt.bz2 On Wed, Mar 05, 2003 at 07:56:01PM -0500, Andrew Cagney wrote: > > >>I would think the null_ptid would serve in such a case. > > > > > >I guess the issue is that we should be dumping the set of LWPs to the > >generated core file, not the set of threads. It seems to me like GDB > >should be aware of the list of LWPs, and it shouldn't be hidden in each > >individual thread package. > > You mean add them to the `struct thread_info' list? Why not (ignoring > technical realities for the moment :-)? Well, I wouldn't do it that way. I haven't really designed this, so bear with me if it has some squishy spots. I think there should be two lists: all threads all lwps Should the data structures be the same? I don't know. The mapping between them would be defined by the thread stratum; its role would be to take thread requests, convert them to LWP requests, and pass them on. The process stratum would be responsible for managing all of the LWPs. This has some advantages, I think. Here's one: we would have a logical interface for reporting an event from an LWP that doesn't currently have a thread. This happens in LinuxThreads, as I've mentioned recently. The thread stratum could see that the inferior ptid was just an LWP id and pass the request along no questions asked. Hmm, definitely some loose edges in that one. Should both an LWP and a thread have a regcache? Might work. -- Daniel Jacobowitz MontaVista Software Debian GNU/Linux Developer