On Tue, 26 Oct 1999 10:42:07 +0800, Feng-Cheng Chang wrote: >Hello, > My friend asked me about the implementation of threads in linux JVM. > > He is interested in porting PersonalJava to linux. > Could somebody give me comments about that? > Which kind of thread implementation is easier? > If we decide to implement both green and native threads, > which one should be done first, and what are the pros and cons? Both forms have their own difficulties. Green threads provide you with a "more controlled" environment and may make debugging easier. However, this may require some rather nasty code to do your own thread switching and ASYNC I/O wrapping to make it all work well. Native threads save you that effort but then you need to build the correct thread control constructs for things like the ASYNC GC and thread death synchronization (for thread.join() types of things) There are also some signalling issues that are "fun". If you look at the diffs that Blackdown has for the JDK ports (either the 1.1.7 or the 1.2) you will see a few of the things that are needed. Note that both 1.1.7 and 1.2pre2 are not 100% working in native threads and, some may claim, not 100% in green either... -- Michael Sinz ---- Technology and Engineering Director/Consultant "Starting Startups" mailto:[EMAIL PROTECTED] My place on the web ---> http://www.users.fast.net/~michael_sinz ---------------------------------------------------------------------- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]