[129] in java-interest

home help back first fref pref prev next nref lref last post

real threads in java?

daemon@ATHENA.MIT.EDU (Dan.Oscarsson@malmo.trab.se)
Sat May 27 18:09:39 1995

From: Dan.Oscarsson@malmo.trab.se
Date: Sat, 27 May 95 11:53:03 +0200
To: java-interest@java.Eng.Sun.COM

Java today is using their own implementation of threads instead of the
"real" threads of the OS. This is because of difficulties with the
garbage collector, if I rember correctely.

Is any work going on to use the "real" threads?

Today io is handled by setting it to non-blocking and using SIGIO.
With "real" Solaris threads io could be blocking and there would be no
need of SIGIO as each thread will block until data becomes available.
It you cannot solve the problem with garbage collection, maybe you could
use one "real" thread for the java interpretator and separate io-threads
for handling the io?

   Dan

--
Dan Oscarsson
Telia Research AB                       Email: Dan.Oscarsson@malmo.trab.se
Box 85
201 20  Malmo, Sweden

[Moderator: We will be revisiting the issue of native threads on Solaris
in the future.  Of course, the issues that came up with Solaris threads
are quite independent of any other threads package, and in general we
endorse using native threads whenever feasible.  We use Win32 threads
in our Win32 Java/HotJava, and they work fine for us.

In addition to the garbage collection problem, for which a workaround
has been proposed, we are also concerned that the two-level priority
model of Solaris threads, which ultimately depends on lwp scheduling
and not user thread scheduling, may not support the sort of things we
want to do in a WWW browser.  Whether or not this turns out to be true,
it is not thought to be a problem for doing servers, where what you
really want is the throughput and parallelism that Solaris' libthread
provides.  So a libthread-based Java for servers should be great if
we can make GC work.]

-
Note to Sun employees: this is an EXTERNAL mailing list!
Info: send 'help' to java-interest-request@java.sun.com

home help back first fref pref prev next nref lref last post