From owner-freebsd-arch Mon Jan 7 9: 8:57 2002 Delivered-To: freebsd-arch@freebsd.org Received: from k6.locore.ca (k6.locore.ca [198.96.117.170]) by hub.freebsd.org (Postfix) with ESMTP id 97A0C37B402 for ; Mon, 7 Jan 2002 09:08:50 -0800 (PST) Received: (from jake@localhost) by k6.locore.ca (8.11.6/8.11.6) id g07HDId61730; Mon, 7 Jan 2002 12:13:18 -0500 (EST) (envelope-from jake) Date: Mon, 7 Jan 2002 12:13:18 -0500 From: Jake Burkholder To: Terry Lambert Cc: Bernd Walter , Alfred Perlstein , Dan Eischen , arch@FreeBSD.ORG Subject: Re: Request for review: getcontext, setcontext, etc Message-ID: <20020107121318.G39321@locore.ca> References: <3C37E559.B011DF29@vigrid.com> <20020106032709.A82406@elvis.mu.org> <3C381B48.AADDCA2B@mindspring.com> <20020106113847.A15885@cicely8.cicely.de> <20020107015228.E39321@locore.ca> <3C396554.9B6A9053@mindspring.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <3C396554.9B6A9053@mindspring.com>; from tlambert2@mindspring.com on Mon, Jan 07, 2002 at 01:07:32AM -0800 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 Apparently, On Mon, Jan 07, 2002 at 01:07:32AM -0800, Terry Lambert said words to the effect of; > Jake Burkholder wrote: > > > > > > Is there a reason that getcontext and setcontext need to be > > > > > > system calls? > > > > > Atomicity? > > > > To flush register windows on setcontext() on SPARC. > > > wflush isn't a priviledged instruction and usualy emulated on < sparcv9. > > > mit-pthreads use it from userland. > > > > Yes, this (flushw) is the best way to flush the windows on v9 at least. > > > > > > > > Are there any performance reasons to flush windows in kernel? > > > > No, doing so is actually more complicated (slightly) due to having > > to use copyout and due potentialy having to deal with 32bit applications > > running on 64bit kernels. It is easier if the spills look like normal > > spills. > > The "flushw" is not enough. Actually it is. > > The following paper discusses the original implementation of the > "liblwp" code on SunOS 4.x: > > http://www.cs.washington.edu/research/compiler/papers.d/thread-regwin.html I've read this paper. v9 is quite different than v8. I don't think we'll ever support v8. We do support v9. Have a nice day. Jake To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message