From owner-freebsd-arch Sun Jan 6 3: 0:18 2002 Delivered-To: freebsd-arch@freebsd.org Received: from rwcrmhc51.attbi.com (rwcrmhc51.attbi.com [204.127.198.38]) by hub.freebsd.org (Postfix) with ESMTP id C3D5737B402; Sun, 6 Jan 2002 03:00:13 -0800 (PST) Received: from InterJet.elischer.org ([12.232.206.8]) by rwcrmhc51.attbi.com (InterMail vM.4.01.03.27 201-229-121-127-20010626) with ESMTP id <20020106110013.FIGM288.rwcrmhc51.attbi.com@InterJet.elischer.org>; Sun, 6 Jan 2002 11:00:13 +0000 Received: from localhost (localhost.elischer.org [127.0.0.1]) by InterJet.elischer.org (8.9.1a/8.9.1) with ESMTP id CAA36978; Sun, 6 Jan 2002 02:45:14 -0800 (PST) Date: Sun, 6 Jan 2002 02:45:13 -0800 (PST) From: Julian Elischer To: Terry Lambert Cc: Robert Watson , Alfred Perlstein , arch@freebsd.org Subject: Re: freeing thread structures. In-Reply-To: <3C3819C6.C74B8DDD@mindspring.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Sun, 6 Jan 2002, Terry Lambert wrote: > Robert Watson wrote: > > I used to think that idea was cool, and now I just think it's evil. The > > reason to have per-thread credentials in kernel is to reduce the > > requirement for locking and to allow consistent use of credentials while > > in kernel. > > As Julian notes, having per thread credentials means locking > in thread_exit(), when it would not otherwise be necessary. NOT having it means needing locking at every access.. take your pick.. I prefer having a reference per thread. > > [ ... other argument about the evils of threads with different > credentials in the same process ... ] > > I agree: it's evil. > > So the question becomes: can we get rid of the locking in the > thread_exit() function if we didn't have per thread credentials? > > -- Terry > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-arch" in the body of the message > To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message