From owner-freebsd-java Wed Mar 7 9:32:49 2001 Delivered-To: freebsd-java@freebsd.org Received: from pcnet1.pcnet.com (pcnet1.pcnet.com [204.213.232.3]) by hub.freebsd.org (Postfix) with ESMTP id 09CB537B71A for ; Wed, 7 Mar 2001 09:32:44 -0800 (PST) (envelope-from eischen@vigrid.com) Received: (from eischen@localhost) by pcnet1.pcnet.com (8.8.7/PCNet) id MAA16070; Wed, 7 Mar 2001 12:31:58 -0500 (EST) Date: Wed, 7 Mar 2001 12:31:57 -0500 (EST) From: Daniel Eischen To: Greg Lewis Cc: "Daniel M. Eischen" , java@FreeBSD.ORG Subject: Re: Java and libc/libpthread In-Reply-To: <20010308015558.B43890@misty.eyesbeyond.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-java@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org On Thu, 8 Mar 2001, Greg Lewis wrote: > On Tue, Mar 06, 2001 at 01:02:10PM -0500, Daniel M. Eischen wrote: > > I'm currently working on an NxN libpthread implementation as > > an interim solution until we get KSEs. The goal is to get > > this done before 5.0. > > Great. However, we'll need a solution thats relevant for 4.x for quite > a while to come I imagine. There should be little or no kernel changes necessary, so whatever I do in -current can be ported to 4.x/-stable. rfork_thread(3) already exists in -stable. The libc/libc_r restructuring in -current can be ported to -stable with a library version bump. > > Unfortunately I don't have the time to help the Java porting > > effort, but I would like to hear about any problems the porters > > are having with our current libc and any expected problems from > > a libpthread that will act very similar to linuxthreads. > > Ok. Currently the patchsets only support green threads, which means > we're not using any native threading models at all. However, this > will need to change for for 1.3 (it would also be nice to get them > into the 1.2.2 patchset). We have some options on this front, and > I'd appreciate any thoughts you have on them. > > 1. Fuyuhiko Maruyama posted some patches to the list at one point to > get 1.2.2 working with our current libc_r pthreads. However, they > were somewhat experimental and I don't believe anyone has addressed > the issues Fuyuhiko noted regarding them. I'd like to see if they're relevent after the -current libc/libc_r restructuring. > 2. One of the porting team has implemented a kernel module for 4.x > that provides kernel threads via a Solaris-like thread interface. > This is also experimental, but simple programs certainly work. I don't see needing a kernel module for what I'm doing, but perhaps this can expose some limitations that we currently have. > 3. As I've been tinkering with the the 1.3 code I've so far been > using the linuxthreads port to try and get native threads running > as that means our code stays very very similar to the code for > native threads under Linux. I haven't succeeded with this yet, > but I don't believe thats because it can't work (its just lack of > time to debug things so far). This is probably the best bet. Our NxN threading implementation should act and behave similar to Linuxthreads. If you can get it to work with Linuxthreads, it should be relatively painless (hopefully) to work with our eventual libpthread. Just try to let me know if there are any hacks needed, non-portable interfaces used, etc. > I guess to add to this, Bill Huey's port of 1.3 for BSDi uses their > libc_r equivalent as I understand it, so this may help our efforts > on that front. This sounds good too. -- Dan Eischen To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-java" in the body of the message