Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 12 Dec 2001 16:44:47 +1030
From:      Greg Lewis <glewis@eyesbeyond.com>
To:        shudo@computer.org
Cc:        freebsd-java@FreeBSD.ORG
Subject:   Re: Native, kernel and user-space threads
Message-ID:  <20011212164447.A87498@misty.eyesbeyond.com>
In-Reply-To: <20011212095914G.shudoh@aist.go.jp>; from shudo@computer.org on Wed, Dec 12, 2001 at 09:59:14AM %2B0900
References:  <20011212095914G.shudoh@aist.go.jp>

next in thread | previous in thread | raw e-mail | index | archive | help
On Wed, Dec 12, 2001 at 09:59:14AM +0900, shudo@computer.org wrote:
> I wanna be convinced of the meaning of `native' threads.
> 
> Currently, FreeBSD (release and stable) does not have a
> threading mechanism implemented in kernel space. I
> suppose native threads you refer is a threads library
> which have POSIX threads API and implemented in user
> space. Is this true?

This is exactly the case.  There is a userland threads library which
implements the POSIX threads API (libc_r).

> If so, the present difference between native threads and
> green threads seems to be their own APIs. Both of them
> are user-space threading libraries. Migration to the
> POSIX interface is worth much to support forthcoming
> Java 2 SDK 1.4. But, what are real present merits of
> native threads without kernel threading for JDK users?

There has already been a small flamefest on that topic today and I'm
not about to join in :).  However, as you mention, JDK 1.4 will no
longer support green threads.  We believe at this time, without having
seen the 1.4 code, that a native threads implementation for JDK 1.3
will be useful both in getting a JDK 1.4 port going and in getting
HotSpot and the Java Plugin to work in JDK 1.3.

> I have been satisfied by green threads implementations
> on Linux and FreeBSD while developing a JIT compiler for
> them over three years. It performs faster than Linux
> (kernel) threads with many applications because it is
> implemented in user space. I do not have SMP machines :)

I think many people have used green threads without any major problems
both for their own use and in production systems.  I know I have.

Personally I would have preferred Sun kept green threads around, if only
because it meant the underlying threading system behaved similarly across
all platforms.  But thats just my opinion :).

-- 
Greg Lewis                            Email : glewis@eyesbeyond.com
Eyes Beyond                           Phone : (801) 796 6999
Information Technology                Web   : http://www.eyesbeyond.com


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-java" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20011212164447.A87498>