From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 32036 invoked by alias); 29 Apr 2004 16:43:37 -0000 Mailing-List: contact libc-hacker-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-hacker-owner@sources.redhat.com Received: (qmail 31993 invoked from network); 29 Apr 2004 16:43:37 -0000 Received: from unknown (HELO sunsite.ms.mff.cuni.cz) (195.113.15.26) by sources.redhat.com with SMTP; 29 Apr 2004 16:43:37 -0000 Received: from sunsite.ms.mff.cuni.cz (sunsite.mff.cuni.cz [127.0.0.1]) by sunsite.ms.mff.cuni.cz (8.12.8/8.12.8) with ESMTP id i3TEVV3j028256; Thu, 29 Apr 2004 16:31:31 +0200 Received: (from jakub@localhost) by sunsite.ms.mff.cuni.cz (8.12.8/8.12.8/Submit) id i3TEVU03028248; Thu, 29 Apr 2004 16:31:30 +0200 Date: Thu, 29 Apr 2004 16:43:00 -0000 From: Jakub Jelinek To: Ulrich Drepper Cc: Glibc hackers , hjl@lucon.org Subject: Re: [PATCH] Fix linuxthreads with pthread_attr_setstack{,addr} Message-ID: <20040429143129.GS5191@sunsite.ms.mff.cuni.cz> Reply-To: Jakub Jelinek References: <20040429141901.GR5191@sunsite.ms.mff.cuni.cz> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20040429141901.GR5191@sunsite.ms.mff.cuni.cz> User-Agent: Mutt/1.4i X-SW-Source: 2004-04/txt/msg00094.txt.bz2 On Thu, Apr 29, 2004 at 04:19:02PM +0200, Jakub Jelinek wrote: > Hi! > > Despite what the bugzilla says, I believe the problem is not related > to TLS. After pthread_join successfully returns, the user thread stack > may be still in use (both by the thread manager (thread descriptor, > i.e. !TLS only) and by the actual thread being joined (both the thread > descriptor and stack being in use)). > The following patch for p_userstack threads waits in pthread_join > till thread manager tells it will not use the thread stack any longer. POSIX says on pthread_join: "For instance, after pthread_join() returns, any application-provided stack storage could be reclaimed." so I guess we need to support that. Jakub