From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 18786 invoked by alias); 8 Oct 2003 00:19:59 -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 18779 invoked from network); 8 Oct 2003 00:19:58 -0000 Received: from unknown (HELO mx1.redhat.com) (66.187.233.31) by sources.redhat.com with SMTP; 8 Oct 2003 00:19:58 -0000 Received: from int-mx2.corp.redhat.com (nat-pool-rdu-dmz.redhat.com [172.16.52.200] (may be forged)) by mx1.redhat.com (8.11.6/8.11.6) with ESMTP id h980Jv115504 for ; Tue, 7 Oct 2003 20:19:57 -0400 Received: from potter.sfbay.redhat.com (potter.sfbay.redhat.com [172.16.27.15]) by int-mx2.corp.redhat.com (8.11.6/8.11.6) with ESMTP id h980JuD15889; Tue, 7 Oct 2003 20:19:56 -0400 Received: from redhat.com (reddwarf.sfbay.redhat.com [172.16.24.50]) by potter.sfbay.redhat.com (8.11.6/8.11.6) with ESMTP id h980Jtw12513; Tue, 7 Oct 2003 17:19:55 -0700 Message-ID: <3F83582B.1060408@redhat.com> Date: Wed, 08 Oct 2003 00:19:00 -0000 From: Michael Snyder Organization: Red Hat, Inc. User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.4) Gecko/20030624 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Daniel Jacobowitz CC: gdb-patches@sources.redhat.com, kettenis@gnu.org Subject: Re: RFC: patch to lin-lwp.c References: <3F303C1E.7040304@redhat.com> <3F3136AD.4010300@redhat.com> <20031004214120.GA24856@nevyn.them.org> In-Reply-To: <20031004214120.GA24856@nevyn.them.org> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-SW-Source: 2003-10/txt/msg00191.txt.bz2 Daniel Jacobowitz wrote: > This patch was never reviewed as far as I can see. I just got a bug > report that I think it would fix... > > Mark, you've said that you don't feel comfortable maintaining the > Linux-specific threading layer, is that recollection right? Michael, > do you? Barely. I felt about 50% able to grok it when I last worked on it, and it's changed a lot since then. > If not, I'd like to clearly indicate who can approve patches > to lin-lwp.c. It's more who ought to than who can. I think any of you, me, Mark, or Jim Blandy (and maybe we ought to add Jeff Johnston) are qualified to approve them, but I don't know which one or two persons understand it fully enough to be called on as a maintainer. Jim and I, for instance, worked on it a long time ago. Part of the problem, I think, is that nobody really wants it. It's complicated, difficult, and fragile. > > On Wed, Aug 06, 2003 at 01:11:09PM -0400, J. Johnston wrote: > >>Sorry, forgot to attach patch. >> >>J. Johnston wrote: >> >>>The attached patch is created to deal with the problem as discussed on: >>> >>> http://sources.redhat.com/ml/gdb/2003-08/msg00043.html >>> >>>The fix does two things: >>> >>> 1. it sets the resumed flag for threads we stopped when the main thread >>> exited and then resumed >>> 2. changes the running_callback to include threads that have events >>> pending on them that will be caught on the next wait >>> >>>Ok to commit? >>> >>>-- Jeff J. >>> >>>2003-08-05 Jeff Johnston >>> >>> * lin-lwp-wait.c (stop_and_resume_callback): Set the resumed flag >>> for any lwp we resume. >>> (running_callback): Add lwps that have pending status events >>> against them to be considered running. >>> >>> >>> >> > >>Index: lin-lwp.c >>=================================================================== >>RCS file: /cvs/src/src/gdb/lin-lwp.c,v >>retrieving revision 1.47 >>diff -u -r1.47 lin-lwp.c >>--- lin-lwp.c 19 Jun 2003 22:52:03 -0000 1.47 >>+++ lin-lwp.c 5 Aug 2003 23:09:55 -0000 >>@@ -839,7 +839,7 @@ >> static int >> running_callback (struct lwp_info *lp, void *data) >> { >>- return (lp->stopped == 0); >>+ return (lp->stopped == 0 || (lp->status != 0 && lp->resumed)); >> } >> >> /* Count the LWP's that have had events. */ >>@@ -1087,7 +1087,10 @@ >> /* Resume if the lwp still exists. */ >> for (ptr = lwp_list; ptr; ptr = ptr->next) >> if (lp == ptr) >>- resume_callback (lp, NULL); >>+ { >>+ resume_callback (lp, NULL); >>+ resume_set_callback (lp, NULL); >>+ } >> } >> return 0; >> } > > >