From owner-freebsd-java Mon Nov 9 09:42:09 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id JAA28235 for freebsd-java-outgoing; Mon, 9 Nov 1998 09:42:09 -0800 (PST) (envelope-from owner-freebsd-java@FreeBSD.ORG) Received: from ns.mt.sri.com (sri-gw.MT.net [206.127.105.141]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id JAA28229; Mon, 9 Nov 1998 09:42:01 -0800 (PST) (envelope-from nate@mt.sri.com) Received: from mt.sri.com (rocky.mt.sri.com [206.127.76.100]) by ns.mt.sri.com (8.8.8/8.8.8) with SMTP id KAA06046; Mon, 9 Nov 1998 10:41:46 -0700 (MST) (envelope-from nate@rocky.mt.sri.com) Received: by mt.sri.com (SMI-8.6/SMI-SVR4) id KAA04801; Mon, 9 Nov 1998 10:41:45 -0700 Date: Mon, 9 Nov 1998 10:41:45 -0700 Message-Id: <199811091741.KAA04801@mt.sri.com> From: Nate Williams MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit To: Mahadevan Iyer Cc: java-port@FreeBSD.ORG, freebsd-java@FreeBSD.ORG, saurabh@internetdevices.com, namit@internetdevices.com Subject: Re: Possible Bug in JVM socket code on FreeBSD, java.net.Socket In-Reply-To: <36381ADB.DCCDAB3D@internetdevices.com> References: <36381ADB.DCCDAB3D@internetdevices.com> X-Mailer: VM 6.34 under 19.16 "Lille" XEmacs Lucid Sender: owner-freebsd-java@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org > I have a simple Server and Client pair > Server listens for connections on fixed port > Clients connect to the server on the port > > The Client opens N connections to the server and keeps them open > The Server sends data on each of these connections > The Client listens for data on each of these connections in a single > thread > > N > 250 causes the Client to dump core For what it's worth, I have tracked down this 'bug' and now know what the problem is. It's related to the select code used in FreeBSD limiting the JVM to 255 *total* file descriptors. Unfortunately, I don't (yet) have a way to increase the number of descriptors arbitrarily, so until we come up with a solution the limit is 250. In other news, I've got JDK1.1.7 built, and am wait on my testers to give me some feedback on it. The only testing I've done on it has been to make sure it compiles itself and actually 'run' the bug-report programs. Hopefully others will get a chance to run it through some Swing and/or AWT applications before it goes public. Nate ps. Again, *THANKS* for the great bug report which included the test application. This made tracking down the bug much easier. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-java" in the body of the message From owner-freebsd-java Mon Nov 9 09:54:21 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id JAA29440 for freebsd-java-outgoing; Mon, 9 Nov 1998 09:54:21 -0800 (PST) (envelope-from owner-freebsd-java@FreeBSD.ORG) Received: from internetdevices.com (idi-fk-gw.abhiweb.com [205.138.236.250]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id JAA29433; Mon, 9 Nov 1998 09:54:18 -0800 (PST) (envelope-from iyer@internetdevices.com) Received: from internetdevices.com (localhost [127.0.0.1]) by internetdevices.com (8.8.7/8.8.7) with ESMTP id JAA02824; Mon, 9 Nov 1998 09:50:12 -0800 (PST) Message-ID: <36472A9A.A1661625@internetdevices.com> Date: Mon, 09 Nov 1998 09:47:06 -0800 From: Mahadevan Iyer Organization: Internet Devices X-Mailer: Mozilla 4.05 [en] (Win95; U) MIME-Version: 1.0 To: Nate Williams CC: java-port@FreeBSD.ORG, freebsd-java@FreeBSD.ORG, saurabh@internetdevices.com, namit@internetdevices.com, iyer@internetdevices.com Subject: Re: Possible Bug in JVM socket code on FreeBSD, java.net.Socket References: <36381ADB.DCCDAB3D@internetdevices.com> <199811091741.KAA04801@mt.sri.com> Content-Type: multipart/alternative; boundary="------------2B26B08D439ED335EC740E05" Sender: owner-freebsd-java@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org --------------2B26B08D439ED335EC740E05 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Hello Nate, thanks for the feedback > For what it's worth, I have tracked down this 'bug' and now know what > the problem is. It's related to the select code used in FreeBSD > limiting the JVM to 255 *total* file descriptors. Unfortunately, I > don't (yet) have a way to increase the number of descriptors > arbitrarily, so until we come up with a solution the limit is 250. > Just to confirm that I understand the problem The select code used in the JVM limits the *total* file descriptors This is not a problem with the FreeBSD socket lib This is not a OS limit that can be tweaked. --------------2B26B08D439ED335EC740E05 Content-Type: text/html; charset=us-ascii Content-Transfer-Encoding: 7bit Hello Nate,

thanks for the feedback
 

For what it's worth, I have tracked down this 'bug' and now know what
the problem is.  It's related to the select code used in FreeBSD
limiting the JVM to 255 *total* file descriptors.  Unfortunately, I
don't (yet) have a way to increase the number of descriptors
arbitrarily, so until we come up with a solution the limit is 250.
 
Just to confirm that I understand the problem
The select code used in the JVM limits the *total* file descriptors
This is not a problem with the FreeBSD socket lib
This is not a OS limit that can be tweaked.
  --------------2B26B08D439ED335EC740E05-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-java" in the body of the message From owner-freebsd-java Mon Nov 9 09:59:23 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id JAA00389 for freebsd-java-outgoing; Mon, 9 Nov 1998 09:59:23 -0800 (PST) (envelope-from owner-freebsd-java@FreeBSD.ORG) Received: from ns.mt.sri.com (sri-gw.MT.net [206.127.105.141]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id JAA00380; Mon, 9 Nov 1998 09:59:19 -0800 (PST) (envelope-from nate@mt.sri.com) Received: from mt.sri.com (rocky.mt.sri.com [206.127.76.100]) by ns.mt.sri.com (8.8.8/8.8.8) with SMTP id KAA06210; Mon, 9 Nov 1998 10:59:03 -0700 (MST) (envelope-from nate@rocky.mt.sri.com) Received: by mt.sri.com (SMI-8.6/SMI-SVR4) id KAA04986; Mon, 9 Nov 1998 10:59:02 -0700 Date: Mon, 9 Nov 1998 10:59:02 -0700 Message-Id: <199811091759.KAA04986@mt.sri.com> From: Nate Williams MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit To: Mahadevan Iyer Cc: Nate Williams , java-port@FreeBSD.ORG, freebsd-java@FreeBSD.ORG, saurabh@internetdevices.com, namit@internetdevices.com Subject: Re: Possible Bug in JVM socket code on FreeBSD, java.net.Socket In-Reply-To: <36472A9A.A1661625@internetdevices.com> References: <36381ADB.DCCDAB3D@internetdevices.com> <199811091741.KAA04801@mt.sri.com> <36472A9A.A1661625@internetdevices.com> X-Mailer: VM 6.34 under 19.16 "Lille" XEmacs Lucid Sender: owner-freebsd-java@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org > > For what it's worth, I have tracked down this 'bug' and now know what > > the problem is. It's related to the select code used in FreeBSD > > limiting the JVM to 255 *total* file descriptors. Unfortunately, I > > don't (yet) have a way to increase the number of descriptors > > arbitrarily, so until we come up with a solution the limit is 250. > > > > Just to confirm that I understand the problem > > The select code used in the JVM limits the *total* file > descriptors > This is not a problem with the FreeBSD socket lib > > This is not a OS limit that can be tweaked. It is, but I don't know how to workaround the 'basic 255' limit in the JDK *code*. The OS is fully capable of handling thousands of FD's, but I do not (yet) know how to make the JDK source code take advantage of this. Hopefully I'll know soon though.... :) Nate To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-java" in the body of the message From owner-freebsd-java Mon Nov 9 11:26:15 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id LAA10494 for freebsd-java-outgoing; Mon, 9 Nov 1998 11:26:15 -0800 (PST) (envelope-from owner-freebsd-java@FreeBSD.ORG) Received: from iglou.com (iglou1.iglou.com [192.107.41.3]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id LAA10486; Mon, 9 Nov 1998 11:26:11 -0800 (PST) (envelope-from patrick@cre8tivegroup.com) Received: from [204.255.227.117] (helo=gateway.cre8tivegroup.com) by iglou.com with esmtp (8.9.1/8.9.1) id 0zcwvx-0002nA-00; Mon, 9 Nov 1998 14:25:06 -0500 Message-ID: X-Mailer: XFMail 1.3 [p0] on FreeBSD X-Priority: 3 (Normal) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 8bit MIME-Version: 1.0 In-Reply-To: <199811091741.KAA04801@mt.sri.com> Date: Mon, 09 Nov 1998 14:23:51 -0500 (EST) From: Patrick Gardella To: Nate Williams Subject: Testing of FreeBSD JDK 1.1.7 Cc: freebsd-java@FreeBSD.ORG, java-port@FreeBSD.ORG Sender: owner-freebsd-java@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org On 09-Nov-98 Nate Williams wrote: > In other news, I've got JDK1.1.7 built, and am wait on my testers to > give me some feedback on it. The only testing I've done on it has been > to make sure it compiles itself and actually 'run' the bug-report > programs. Nate, I'm testing your JDK 1.1.7 and it seems to run fine. I've tested it on all my standard apps. Not a problem yet! Swing, AWT, JDBC, all without a problem. This is just initial testing, no hard core stress tests. --- Patrick S. Gardella Director of Web Development The Creative Group 1-800-804-0783 ext 29 606-858-8029 (fax) http://www.cre8tivegroup.com PGP Key ID 0xEE2D47A9 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-java" in the body of the message From owner-freebsd-java Mon Nov 9 11:26:19 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id LAA10510 for freebsd-java-outgoing; Mon, 9 Nov 1998 11:26:19 -0800 (PST) (envelope-from owner-freebsd-java@FreeBSD.ORG) Received: from iglou.com (iglou3.iglou.com [192.107.41.6]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id LAA10487; Mon, 9 Nov 1998 11:26:12 -0800 (PST) (envelope-from patrick@cre8tivegroup.com) Received: from [204.255.227.117] (helo=gateway.cre8tivegroup.com) by iglou.com with esmtp (8.9.1/8.9.1) id 0zcwwg-0003PR-00; Mon, 9 Nov 1998 14:25:50 -0500 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 8bit MIME-Version: 1.0 Message-ID: X-Mailer: XFMail 1.3 [p0] on FreeBSD X-Priority: 3 (Normal) In-Reply-To: <199811091741.KAA04801@mt.sri.com> Date: Mon, 09 Nov 1998 14:24:38 -0500 (EST) From: Patrick Gardella To: Nate Williams Subject: Testing of FreeBSD JDK 1.1.7 Cc: freebsd-java@FreeBSD.ORG, java-port@FreeBSD.ORG Sender: owner-freebsd-java@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org On 09-Nov-98 Nate Williams wrote: > In other news, I've got JDK1.1.7 built, and am wait on my testers to > give me some feedback on it. The only testing I've done on it has been > to make sure it compiles itself and actually 'run' the bug-report > programs. Nate, I'm testing your JDK 1.1.7 and it seems to run fine. I've tested it on all my standard apps. Not a problem yet! Swing, AWT, JDBC, all without a problem. This is just initial testing, no hard core stress tests. And on this release, only some of the apps have the blue background. Most flash the blue, then reset to the normal color. --- Patrick S. Gardella Director of Web Development The Creative Group 1-800-804-0783 ext 29 606-858-8029 (fax) http://www.cre8tivegroup.com PGP Key ID 0xEE2D47A9 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-java" in the body of the message From owner-freebsd-java Mon Nov 9 11:35:30 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id LAA11773 for freebsd-java-outgoing; Mon, 9 Nov 1998 11:35:30 -0800 (PST) (envelope-from owner-freebsd-java@FreeBSD.ORG) Received: from ns.mt.sri.com (sri-gw.MT.net [206.127.105.141]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id LAA11765; Mon, 9 Nov 1998 11:35:27 -0800 (PST) (envelope-from nate@mt.sri.com) Received: from mt.sri.com (rocky.mt.sri.com [206.127.76.100]) by ns.mt.sri.com (8.8.8/8.8.8) with SMTP id MAA07075; Mon, 9 Nov 1998 12:35:11 -0700 (MST) (envelope-from nate@rocky.mt.sri.com) Received: by mt.sri.com (SMI-8.6/SMI-SVR4) id MAA05828; Mon, 9 Nov 1998 12:35:11 -0700 Date: Mon, 9 Nov 1998 12:35:11 -0700 Message-Id: <199811091935.MAA05828@mt.sri.com> From: Nate Williams MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit To: Patrick Gardella Cc: Nate Williams , freebsd-java@FreeBSD.ORG, java-port@FreeBSD.ORG Subject: Re: Testing of FreeBSD JDK 1.1.7 In-Reply-To: References: <199811091741.KAA04801@mt.sri.com> X-Mailer: VM 6.34 under 19.16 "Lille" XEmacs Lucid Sender: owner-freebsd-java@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org > > In other news, I've got JDK1.1.7 built, and am wait on my testers to > > give me some feedback on it. The only testing I've done on it has been > > to make sure it compiles itself and actually 'run' the bug-report > > programs. > > Nate, > > I'm testing your JDK 1.1.7 and it seems to run fine. I've tested it on > all my standard apps. Not a problem yet! Swing, AWT, JDBC, all without a > problem. Great, glad to hear it! > This is just initial testing, no hard core stress tests. I'd like *someone* to test it against all of the 'demo' applets in the JDK, and then I'll be testing it against my application. If it passes, I'll release it and work on a 'bug-fix' release. Nate To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-java" in the body of the message From owner-freebsd-java Mon Nov 9 12:45:35 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id MAA19277 for freebsd-java-outgoing; Mon, 9 Nov 1998 12:45:35 -0800 (PST) (envelope-from owner-freebsd-java@FreeBSD.ORG) Received: from iglou.com (iglou3.iglou.com [192.107.41.6]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id MAA19267; Mon, 9 Nov 1998 12:45:29 -0800 (PST) (envelope-from patrick@cre8tivegroup.com) Received: from [204.255.227.117] (helo=gateway.cre8tivegroup.com) by iglou.com with esmtp (8.9.1/8.9.1) id 0zcyAg-0007fj-00; Mon, 9 Nov 1998 15:44:22 -0500 Message-ID: X-Mailer: XFMail 1.3 [p0] on FreeBSD X-Priority: 3 (Normal) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 8bit MIME-Version: 1.0 In-Reply-To: <199811091935.MAA05828@mt.sri.com> Date: Mon, 09 Nov 1998 15:43:09 -0500 (EST) From: Patrick Gardella To: Nate Williams Subject: Re: Testing of FreeBSD JDK 1.1.7 Cc: java-port@FreeBSD.ORG, freebsd-java@FreeBSD.ORG Sender: owner-freebsd-java@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org On 09-Nov-98 Nate Williams wrote: > I'd like *someone* to test it against all of the 'demo' applets in the > JDK, and then I'll be testing it against my application. If it passes, > I'll release it and work on a 'bug-fix' release. I've tested them all. Aside from the "java_X in free(): warning: chunk is already free" error, they all work fine. Patrick --- Patrick S. Gardella Director of Web Development The Creative Group 1-800-804-0783 ext 29 606-858-8029 (fax) http://www.cre8tivegroup.com PGP Key ID 0xEE2D47A9 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-java" in the body of the message From owner-freebsd-java Mon Nov 9 12:47:14 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id MAA19481 for freebsd-java-outgoing; Mon, 9 Nov 1998 12:47:14 -0800 (PST) (envelope-from owner-freebsd-java@FreeBSD.ORG) Received: from ns.mt.sri.com (sri-gw.MT.net [206.127.105.141]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id MAA19468; Mon, 9 Nov 1998 12:47:11 -0800 (PST) (envelope-from nate@mt.sri.com) Received: from mt.sri.com (rocky.mt.sri.com [206.127.76.100]) by ns.mt.sri.com (8.8.8/8.8.8) with SMTP id NAA07658; Mon, 9 Nov 1998 13:46:55 -0700 (MST) (envelope-from nate@rocky.mt.sri.com) Received: by mt.sri.com (SMI-8.6/SMI-SVR4) id NAA06659; Mon, 9 Nov 1998 13:46:54 -0700 Date: Mon, 9 Nov 1998 13:46:54 -0700 Message-Id: <199811092046.NAA06659@mt.sri.com> From: Nate Williams MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit To: Patrick Gardella Cc: Nate Williams , java-port@FreeBSD.ORG, freebsd-java@FreeBSD.ORG Subject: Re: Testing of FreeBSD JDK 1.1.7 In-Reply-To: References: <199811091935.MAA05828@mt.sri.com> X-Mailer: VM 6.34 under 19.16 "Lille" XEmacs Lucid Sender: owner-freebsd-java@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org > > I'd like *someone* to test it against all of the 'demo' applets in the > > JDK, and then I'll be testing it against my application. If it passes, > > I'll release it and work on a 'bug-fix' release. > > I've tested them all. Aside from the "java_X in free(): warning: chunk is > already free" error, they all work fine. Cool. I'll test out my application, and if it works I'll update the WWW page and make the release available to the public. Thanks! Nate To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-java" in the body of the message From owner-freebsd-java Mon Nov 9 23:39:15 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id XAA22261 for freebsd-java-outgoing; Mon, 9 Nov 1998 23:39:15 -0800 (PST) (envelope-from owner-freebsd-java@FreeBSD.ORG) Received: from PraetorianGuard.lbl.gov (mh1.lbl.gov [128.3.7.48]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id XAA22255 for ; Mon, 9 Nov 1998 23:39:14 -0800 (PST) (envelope-from tao@hmbrt.lbl.gov) Received: from hmbrt.lbl.gov (hmbrt.lbl.gov [128.3.21.168]) by PraetorianGuard.lbl.gov (LBLPSB/SpamKiller) with SMTP id XAA01764 for ; Mon, 9 Nov 1998 23:38:59 -0800 (PST) Received: by hmbrt.lbl.gov (SMI-8.6/SMI-SVR4) id XAA09337; Mon, 9 Nov 1998 23:38:57 -0800 Date: Mon, 9 Nov 1998 23:38:57 -0800 From: tao@hmbrt.lbl.gov (Tao Zhen) Message-Id: <199811100738.XAA09337@hmbrt.lbl.gov> To: java@FreeBSD.ORG Sender: owner-freebsd-java@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org Hi, there, I was playing with the java native method example on the java tutorial web page (http://java.sun.com/docs/books/tutorial/native1.1/stepbystep/index.html) I couldn't get this simple example work. I am using FreeBSD 3.0 and jdk1.1.6. Here's how I created the shared library: cc -shared -I/usr/local/java/include -I/usr/local/java/include/freebsd HelloWorldImp.c -o libhello.so I've also tried ar and ranlib to create the library. However, when I run the program, it gives me the following error message: bad magic number in "./libhello.so" (libhello.so) Can't find class HelloWorld. Please help. BTW, my compiler is gcc2.7.2.1. Thanks. Tao To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-java" in the body of the message From owner-freebsd-java Tue Nov 10 09:05:32 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id JAA17606 for freebsd-java-outgoing; Tue, 10 Nov 1998 09:05:32 -0800 (PST) (envelope-from owner-freebsd-java@FreeBSD.ORG) Received: from ns.mt.sri.com (sri-gw.MT.net [206.127.105.141]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id JAA17599 for ; Tue, 10 Nov 1998 09:05:31 -0800 (PST) (envelope-from nate@mt.sri.com) Received: from mt.sri.com (rocky.mt.sri.com [206.127.76.100]) by ns.mt.sri.com (8.8.8/8.8.8) with SMTP id KAA15837; Tue, 10 Nov 1998 10:05:09 -0700 (MST) (envelope-from nate@rocky.mt.sri.com) Received: by mt.sri.com (SMI-8.6/SMI-SVR4) id KAA11762; Tue, 10 Nov 1998 10:05:09 -0700 Date: Tue, 10 Nov 1998 10:05:09 -0700 Message-Id: <199811101705.KAA11762@mt.sri.com> From: Nate Williams MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit To: tao@hmbrt.lbl.gov (Tao Zhen) Cc: java@FreeBSD.ORG In-Reply-To: <199811100738.XAA09337@hmbrt.lbl.gov> References: <199811100738.XAA09337@hmbrt.lbl.gov> X-Mailer: VM 6.34 under 19.16 "Lille" XEmacs Lucid Sender: owner-freebsd-java@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org > I was playing with the java native method example on the java tutorial > web page (http://java.sun.com/docs/books/tutorial/native1.1/stepbystep/index.html) > I couldn't get this simple example work. I am using FreeBSD 3.0 and jdk1.1.6. > Here's how I created the shared library: > cc -shared -I/usr/local/java/include -I/usr/local/java/include/freebsd > HelloWorldImp.c -o libhello.so The JDK is an a.out binary, so you must use an a.out library to link against it. FreeBSD 3.0 uses ELF, so you must force it to create an a.out library (I don't know how) if you want to use JNI on FreeBSD 3.0. Nate To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-java" in the body of the message From owner-freebsd-java Tue Nov 10 12:47:14 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id MAA12574 for freebsd-java-outgoing; Tue, 10 Nov 1998 12:47:14 -0800 (PST) (envelope-from owner-freebsd-java@FreeBSD.ORG) Received: from alpo.whistle.com (alpo.whistle.com [207.76.204.38]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id MAA12569 for ; Tue, 10 Nov 1998 12:47:13 -0800 (PST) (envelope-from julian@whistle.com) Received: (from daemon@localhost) by alpo.whistle.com (8.8.5/8.8.5) id MAA10442 for ; Tue, 10 Nov 1998 12:44:57 -0800 (PST) Received: from current1.whistle.com(207.76.205.22) via SMTP by alpo.whistle.com, id smtpdx10439; Tue Nov 10 20:44:53 1998 Date: Tue, 10 Nov 1998 12:44:20 -0800 (PST) From: Julian Elischer To: java@FreeBSD.ORG Subject: Re: Special OOP Seminar (fwd) 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 ---------- Forwarded message ---------- Date: Tue, 10 Nov 1998 09:49:39 -0800 (PST) From: Maggie McLoughlin To: colloq@cs.stanford.edu Subject: Re: Special OOP Seminar > Special Seminar: ***TODAY!!!*** November 10, 1998, 1:15 pm ***Gates B08*** Jinsight: Object-oriented Program Visualization > Wim De Pauw > IBM Watson Research Center > >Jinsight is a tool that displays a Java program's behavior at execution. It >displays object population, messages, garbage collection, bottlenecks for >CPU time and memory, thread interactions, deadlocks, and memory >leaks. Jinsight can also take repetitive execution behavior and boil it >down >to its essentials, eliminating redundancy and uncovering the highlights of >an execution. By displaying program behavior and hot spots from several >perspectives, Jinsight strengthens your ability to understand, debug, and >fine-tune your program. Jinsight works with traces from a modified VM (JDK >1.1.5 or 1.1.6) and visualizes these traces on a 100% Pure Java visualizer. > >Jinsight advances the analysis of dynamic, object-oriented (OO) programs in >three ways: > > It is fully object-oriented. Most performance-tuning tools for OO > languages do little more than profile methods as they do procedures in > non-OO languages. Some go as far as showing the total number of objects > per class. But the OO programming model is fundamentally different from > the procedural model, and much of the power of OO is lost on > conventional tools. Jinsight's views of program execution use metaphors > that are both natural and consistent with the OO model. These views let > you visualize both objects and messages explicitly. The Histogram view > lets you see calling > and reference relationships among objects. The Execution, Invocation > Browser, and Execution Pattern views show sequences of messages among > objects as a function of time.. The Reference Pattern view displays > patterns of references among objects. These views work together > seamlessly to reveal the inner workings of your program. > > Jinsight has powerful pattern extraction capabilities that let you deal > with large, real-world traces. It presents recurring patterns of > run-time behavior in a single, compact view. Pattern extraction takes > what isoften an overwhelming and highly redundant mass of execution > information and reduces it to its fundamental interactions. It lets you > peruse vast areas of the execution space without sifting through it > message by > message, object by object. Pattern extraction greatly simplifies > run-time analysis. > > Jinsight has a unique memory leak finder. Where other tools claim to > find memory leaks by "displaying an abnormal volume of instances," > Jinsight can reveal the causes of the memory leaks with far greater > precision. Its Reference Pattern view shows which objects are holding > references that are hampering garbage collection, thereby drawing > attention to the code responsible for those references. > > > > +----------------------------------------------------------------------------+ | This message was sent via the Stanford Computer Science Department | | colloquium mailing list. To be added to this list send an arbitrary | | message to colloq-subscribe@cs.stanford.edu. To be removed from this list,| | send a message to colloq-unsubscribe@cs.stanford.edu. For more information,| | send an arbitrary message to colloq-request@cs.stanford.edu. For directions| | to Stanford, check out http://www-forum.stanford.edu | +-------------------------------------------------------------------------xcl+ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-java" in the body of the message From owner-freebsd-java Tue Nov 10 12:59:00 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id MAA14046 for freebsd-java-outgoing; Tue, 10 Nov 1998 12:59:00 -0800 (PST) (envelope-from owner-freebsd-java@FreeBSD.ORG) Received: from iglou.com (iglou1.iglou.com [192.107.41.3]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id MAA14041 for ; Tue, 10 Nov 1998 12:58:58 -0800 (PST) (envelope-from patrick@cre8tivegroup.com) Received: from [204.255.227.60] (helo=gateway.cre8tivegroup.com) by iglou.com with esmtp (8.9.1/8.9.1) id 0zdKrl-0005yN-00; Tue, 10 Nov 1998 15:58:28 -0500 Message-ID: X-Mailer: XFMail 1.3 [p0] on FreeBSD X-Priority: 3 (Normal) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 8bit MIME-Version: 1.0 Date: Tue, 10 Nov 1998 15:57:36 -0500 (EST) From: Patrick Gardella To: freebsd-java@FreeBSD.ORG Subject: Java Plug-In for FreeBSD Sender: owner-freebsd-java@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org Has anyone started working on a FreeBSD version of the Java Plug-In? Linux has a version that requires higher library versions than what our Linux emulation has (our latest is linux_lib-2.6) even with the libc5 version. (No, I haven't downloaded it yet; I'm doing so now :) --- Patrick S. Gardella Director of Web Development The Creative Group 1-800-804-0783 ext 29 606-858-8029 (fax) http://www.cre8tivegroup.com PGP Key ID 0xEE2D47A9 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-java" in the body of the message From owner-freebsd-java Tue Nov 10 14:23:05 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id OAA25916 for freebsd-java-outgoing; Tue, 10 Nov 1998 14:23:05 -0800 (PST) (envelope-from owner-freebsd-java@FreeBSD.ORG) Received: from WEBBSD1.turnaround.com.au (webbsd1.turnaround.com.au [203.39.138.49]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id OAA25909 for ; Tue, 10 Nov 1998 14:23:03 -0800 (PST) (envelope-from J_Shevland@TurnAround.com.au) Received: from TurnAround.com.au (dhcp110.turnaround.com.au [192.168.1.110] (may be forged)) by WEBBSD1.turnaround.com.au (8.8.7/8.8.7) with ESMTP id JAA27136; Wed, 11 Nov 1998 09:25:39 +1100 (EST) (envelope-from J_Shevland@TurnAround.com.au) Message-ID: <3648BC83.3CCCEADD@TurnAround.com.au> Date: Wed, 11 Nov 1998 09:21:55 +1100 From: Joe Shevland Organization: TurnAround Solutions Pty. Ltd. X-Mailer: Mozilla 4.5 [en] (WinNT; I) X-Accept-Language: en MIME-Version: 1.0 To: Patrick Gardella CC: freebsd-java@FreeBSD.ORG Subject: Re: Java Plug-In for FreeBSD References: Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-java@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org No, but I would absolutely go berserk with joy if we could have ongoing support for this. If I can help, let me know. Patrick Gardella wrote: > > Has anyone started working on a FreeBSD version of the Java Plug-In? > > Linux has a version that requires higher library versions than what our Linux > emulation has (our latest is linux_lib-2.6) even with the libc5 version. (No, I > haven't downloaded it yet; I'm doing so now :) > > --- > Patrick S. Gardella Director of Web Development > The Creative Group 1-800-804-0783 ext 29 606-858-8029 (fax) > http://www.cre8tivegroup.com PGP Key ID 0xEE2D47A9 > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-java" in the body of the message -- ---------------------|============================= Joe Shevland | TurnAround Solutions Senior Consultant | Hobart, Australia No unsolicited email | Voice (03) 6224 9146 | http://www.TurnAround.com.au ---------------------|============================= To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-java" in the body of the message From owner-freebsd-java Tue Nov 10 16:33:07 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id QAA13182 for freebsd-java-outgoing; Tue, 10 Nov 1998 16:33:07 -0800 (PST) (envelope-from owner-freebsd-java@FreeBSD.ORG) Received: from wrath.cs.utah.edu (wrath.cs.utah.edu [155.99.198.100]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id QAA13177 for ; Tue, 10 Nov 1998 16:33:06 -0800 (PST) (envelope-from gback@cs.utah.edu) Received: from sal.cs.utah.edu (sal.cs.utah.edu [155.99.192.111]) by wrath.cs.utah.edu (8.8.8/8.8.8) with ESMTP id RAA22987; Tue, 10 Nov 1998 17:32:49 -0700 (MST) From: Godmar Back Received: (from gback@localhost) by sal.cs.utah.edu (8.8.8/8.8.8) id RAA28512; Tue, 10 Nov 1998 17:33:05 -0700 (MST) Message-Id: <199811110033.RAA28512@sal.cs.utah.edu> Subject: Re: Java Plug-In for FreeBSD To: J_Shevland@TurnAround.com.au (Joe Shevland) Date: Tue, 10 Nov 1998 17:33:05 -0700 (MST) Cc: patrick@cre8tivegroup.com, freebsd-java@FreeBSD.ORG In-Reply-To: <3648BC83.3CCCEADD@TurnAround.com.au> from "Joe Shevland" at Nov 11, 98 09:21:55 am X-Mailer: ELM [version 2.4 PL25] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-freebsd-java@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org The local FreeBSD experts here have told me that all you need to do is to grab the library from a Linux distribution and stick it wherever BSD keeps the emulation tree, I think in /compat. You could try that and see whether that works. - Godmar > > No, but I would absolutely go berserk with joy if we could have > ongoing support for this. If I can help, let me know. > > Patrick Gardella wrote: > > > > Has anyone started working on a FreeBSD version of the Java Plug-In? > > > > Linux has a version that requires higher library versions than what our Linux > > emulation has (our latest is linux_lib-2.6) even with the libc5 version. (No, I > > haven't downloaded it yet; I'm doing so now :) > > > > --- > > Patrick S. Gardella Director of Web Development > > The Creative Group 1-800-804-0783 ext 29 606-858-8029 (fax) > > http://www.cre8tivegroup.com PGP Key ID 0xEE2D47A9 > > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > > with "unsubscribe freebsd-java" in the body of the message > > -- > ---------------------|============================= > Joe Shevland | TurnAround Solutions > Senior Consultant | Hobart, Australia > No unsolicited email | Voice (03) 6224 9146 > | http://www.TurnAround.com.au > ---------------------|============================= > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-java" in the body of the message > To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-java" in the body of the message From owner-freebsd-java Tue Nov 10 18:08:20 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id SAA21932 for freebsd-java-outgoing; Tue, 10 Nov 1998 18:08:20 -0800 (PST) (envelope-from owner-freebsd-java@FreeBSD.ORG) Received: from WEBBSD1.turnaround.com.au (webbsd1.turnaround.com.au [203.39.138.49]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id SAA21923 for ; Tue, 10 Nov 1998 18:08:18 -0800 (PST) (envelope-from J_Shevland@TurnAround.com.au) Received: from TurnAround.com.au (dhcp110.turnaround.com.au [192.168.1.110] (may be forged)) by WEBBSD1.turnaround.com.au (8.8.7/8.8.7) with ESMTP id NAA28820; Wed, 11 Nov 1998 13:10:56 +1100 (EST) (envelope-from J_Shevland@TurnAround.com.au) Message-ID: <3648F150.220C9029@TurnAround.com.au> Date: Wed, 11 Nov 1998 13:07:12 +1100 From: Joe Shevland Organization: TurnAround Solutions Pty. Ltd. X-Mailer: Mozilla 4.5 [en] (WinNT; I) X-Accept-Language: en MIME-Version: 1.0 To: Godmar Back CC: patrick@cre8tivegroup.com, freebsd-java@FreeBSD.ORG Subject: Re: Java Plug-In for FreeBSD References: <199811110033.RAA28512@sal.cs.utah.edu> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-java@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org OK, I've had a look at Blackdown's FTP site; sorry for a bit of a newbie question, but will I need the glibc one or the libc5 one? I guess it depends on my FBSD installation, but if someone could point me in the right direction I'll try and get it working tonight when I get home. Cheers, Joe. Godmar Back wrote: > > The local FreeBSD experts here have told me that all you need > to do is to grab the library from a Linux distribution and stick it > wherever BSD keeps the emulation tree, I think in /compat. > > You could try that and see whether that works. > > - Godmar > > > > > No, but I would absolutely go berserk with joy if we could have > > ongoing support for this. If I can help, let me know. > > > > Patrick Gardella wrote: > > > > > > Has anyone started working on a FreeBSD version of the Java Plug-In? > > > > > > Linux has a version that requires higher library versions than what our Linux > > > emulation has (our latest is linux_lib-2.6) even with the libc5 version. (No, I > > > haven't downloaded it yet; I'm doing so now :) > > > > > > --- > > > Patrick S. Gardella Director of Web Development [...] > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-java" in the body of the message -- ---------------------|============================= Joe Shevland | TurnAround Solutions Senior Consultant | Hobart, Australia No unsolicited email | Voice (03) 6224 9146 | http://www.TurnAround.com.au ---------------------|============================= To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-java" in the body of the message From owner-freebsd-java Tue Nov 10 23:33:07 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id XAA14780 for freebsd-java-outgoing; Tue, 10 Nov 1998 23:33:07 -0800 (PST) (envelope-from owner-freebsd-java@FreeBSD.ORG) Received: from quackerjack.cc.vt.edu (quackerjack.cc.vt.edu [198.82.160.250]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id XAA14775 for ; Tue, 10 Nov 1998 23:33:04 -0800 (PST) (envelope-from jobaldwi@vt.edu) Received: from sable.cc.vt.edu (sable.cc.vt.edu [128.173.16.30]) by quackerjack.cc.vt.edu (8.8.8/8.8.8) with ESMTP id WAA04664; Tue, 10 Nov 1998 22:04:57 -0500 (EST) Received: from john.baldwinfamily.org (jobaldwi.campus.vt.edu [198.82.67.63]) by sable.cc.vt.edu (8.8.8/8.8.8) with ESMTP id WAA24045; Tue, 10 Nov 1998 22:04:56 -0500 (EST) Message-ID: X-Mailer: XFMail 1.3 [p0] on FreeBSD X-Priority: 3 (Normal) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 8bit MIME-Version: 1.0 In-Reply-To: <3648F150.220C9029@TurnAround.com.au> Date: Tue, 10 Nov 1998 22:04:55 -0500 (EST) Reply-To: jobaldwi@vt.edu Organization: Virginia Tech From: John Baldwin To: Joe Shevland Subject: Re: Java Plug-In for FreeBSD Cc: freebsd-java@FreeBSD.ORG, patrick@cre8tivegroup.com, Godmar Back Sender: owner-freebsd-java@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org -----BEGIN PGP SIGNED MESSAGE----- On 11-Nov-98 Joe Shevland wrote: > OK, I've had a look at Blackdown's FTP site; sorry for a bit of a newbie > question, but will I need the glibc one or the libc5 one? I guess it > depends on my FBSD installation, but if someone could point me in the > right direction I'll try and get it working tonight when I get home. > > Cheers, > Joe. You want the libc5 version, and you will want to run /compat/linux/sbin/ldconfig afterwards to update /compat/linux/etc/ld.so.cache so that ld.so knows that the new library is there. - --- John Baldwin -- http://members.freedomnet.com/~jbaldwin/ PGP Key: http://members.freedomnet.com/~jbaldwin/pgpkey.asc 2 + 2 = 5 ; with suitably large values of 2. -----BEGIN PGP SIGNATURE----- Version: 2.6.2 iQB1AwUBNkj+sIjYza302vYpAQEqBQL/Tq9MT7S6orNahoSj1raweewV9nrh9gkP OrwGCxZbhT6950ZtpQlAoQYwwJcg3clyqX4bcq40tiAWH666cXO7X11KQT93b1Hw jTrobGqzo0Uid/PrNekQbRTn7OF7GCNS =JCJh -----END PGP SIGNATURE----- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-java" in the body of the message From owner-freebsd-java Wed Nov 11 12:39:55 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id MAA00227 for freebsd-java-outgoing; Wed, 11 Nov 1998 12:39:55 -0800 (PST) (envelope-from owner-freebsd-java@FreeBSD.ORG) Received: from iglou.com (iglou3.iglou.com [192.107.41.6]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id MAA00222 for ; Wed, 11 Nov 1998 12:39:53 -0800 (PST) (envelope-from patrick@cre8tivegroup.com) Received: from [204.255.227.105] (helo=gateway.cre8tivegroup.com) by iglou.com with esmtp (8.9.1/8.9.1) id 0zdh2J-0002wU-00; Wed, 11 Nov 1998 15:38:45 -0500 Message-ID: X-Mailer: XFMail 1.3 [p0] on FreeBSD X-Priority: 3 (Normal) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 8bit MIME-Version: 1.0 In-Reply-To: <199811110033.RAA28512@sal.cs.utah.edu> Date: Wed, 11 Nov 1998 15:37:53 -0500 (EST) From: Patrick Gardella To: Godmar Back Subject: Re: Java Plug-In for FreeBSD Cc: freebsd-java@FreeBSD.ORG, (Joe Shevland) Sender: owner-freebsd-java@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org No Joy on this method (yet). The ControlPanel app (used to configure the plug in) crashes with a sig 11 when used with the FreeBSD jre. It's a java app, so it doesn't use the linux stuff, AFAIK. I'll be looking into this more as the days go on, but for right now, it's not that easy. Patrick On 11-Nov-98 Godmar Back wrote: > > The local FreeBSD experts here have told me that all you need > to do is to grab the library from a Linux distribution and stick it > wherever BSD keeps the emulation tree, I think in /compat. > > You could try that and see whether that works. > > - Godmar > >> >> No, but I would absolutely go berserk with joy if we could have >> ongoing support for this. If I can help, let me know. >> >> Patrick Gardella wrote: >> > >> > Has anyone started working on a FreeBSD version of the Java Plug-In? >> > >> > Linux has a version that requires higher library versions than what our >> > Linux >> > emulation has (our latest is linux_lib-2.6) even with the libc5 version. >> > (No, I >> > haven't downloaded it yet; I'm doing so now :) >> > >> > --- >> > Patrick S. Gardella Director of Web Development >> > The Creative Group 1-800-804-0783 ext 29 606-858-8029 (fax) >> > http://www.cre8tivegroup.com PGP Key ID 0xEE2D47A9 >> > >> > To Unsubscribe: send mail to majordomo@FreeBSD.org >> > with "unsubscribe freebsd-java" in the body of the message >> >> -- >> ---------------------|============================= >> Joe Shevland | TurnAround Solutions >> Senior Consultant | Hobart, Australia >> No unsolicited email | Voice (03) 6224 9146 >> | http://www.TurnAround.com.au >> ---------------------|============================= >> >> To Unsubscribe: send mail to majordomo@FreeBSD.org >> with "unsubscribe freebsd-java" in the body of the message >> > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-java" in the body of the message --- Patrick S. Gardella Director of Web Development The Creative Group 1-800-804-0783 ext 29 606-858-8029 (fax) http://www.cre8tivegroup.com PGP Key ID 0xEE2D47A9 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-java" in the body of the message From owner-freebsd-java Wed Nov 11 16:37:00 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id QAA27624 for freebsd-java-outgoing; Wed, 11 Nov 1998 16:37:00 -0800 (PST) (envelope-from owner-freebsd-java@FreeBSD.ORG) Received: from sv01.cet.co.jp (sv01.cet.co.jp [210.171.56.2]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id QAA27615 for ; Wed, 11 Nov 1998 16:36:56 -0800 (PST) (envelope-from michaelh@cet.co.jp) Received: from localhost (michaelh@localhost) by sv01.cet.co.jp (8.8.8/8.8.8) with SMTP id AAA07852 for ; Thu, 12 Nov 1998 00:36:32 GMT (envelope-from michaelh@cet.co.jp) Date: Thu, 12 Nov 1998 09:36:32 +0900 (JST) From: Michael Hancock To: java@FreeBSD.ORG Subject: Java chip 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 Sorry a little of topic but interesting. I was reading an article on storage system and found this link on a chip ideal for executing Java. http://www.ptsc.com/psc1000/java_psc1000.html To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-java" in the body of the message From owner-freebsd-java Fri Nov 13 14:44:07 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id OAA13690 for freebsd-java-outgoing; Fri, 13 Nov 1998 14:44:07 -0800 (PST) (envelope-from owner-freebsd-java@FreeBSD.ORG) Received: from aurora.rg.iupui.edu (aurora.rg.iupui.edu [134.68.31.122]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id OAA13680 for ; Fri, 13 Nov 1998 14:44:04 -0800 (PST) (envelope-from gunther@aurora.rg.iupui.edu) Received: (from gunther@localhost) by aurora.rg.iupui.edu (8.8.7/8.8.7) id RAA14641 for freebsd-java@FreeBSD.ORG; Fri, 13 Nov 1998 17:44:59 -0500 (EST) (envelope-from gunther) Date: Fri, 13 Nov 1998 17:44:59 -0500 (EST) From: Gunther Schadow Message-Id: <199811132244.RAA14641@aurora.rg.iupui.edu> To: freebsd-java@FreeBSD.ORG Subject: green threads vs. native threads ... Sender: owner-freebsd-java@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org Hi, I just wrote my first threadded Java application, and I am diappointed about the way it behaves. I am wondering whether or not the reason for the problem I am going to explain is that I am using green threads rather than native threads. Here goes: I have a simple database server (non JDBC, my own protocol, very simple) on a VAX VMS written in VAX BASIC (urgh.) The rest of my application I develop on FreeBSD in Java. It's simple: the client sends a request for data over TCP to the server and gets the data as a response. This data retrieval is a performance problem. It turned out that both client and server spend most of their time waiting for each other while the data is in transit over the network. Here is what I did: to receive big amounts of data from a single query, I created a "receiver" thread, that collects incomming data messages as they arrive and puts them into a buffer. The main thread takes messages from the receiver's buffer as needed. The main thread has a lot of work to do with the messages which should give the receiver thread enough time to read from the network. So, ideally, both receiver and main thread should be quite busy working in parallel, where receiver spends most of the time waiting in java.net.SocketInputStream.read, and the main thread should be busy processing the data. Collisions at the buffer access (which is properly protected by a monitor) should occur not frequently. However, as it turned out, both threads are still waiting on each other and, most of the time, the threads seem to execute sequentially rather than parallel. In the folloing "trace" you see a period "." wherever the main thread gets a meessage from the receiver and an asterisk "*" when the receiver puts a new message on the buffer. If the buffer runs empty, the main thread suspends itself (indicated by "w"). The receiver thread wakes the main thread up again when it deposits a new message in the buffer. Conversely, if the buffer is full (128 messages in this case) the receiver thread suspends itself (indicated by "r") and is waked up again by the main thread when a message is withdrawn from the buffer. Here is what happens: w**********.*..*..*..*..*..*..*..*..*..w The main thread is suspended right upfront, because the buffer is empty at the start. Then the receiver places a couple of messages into the buffer "*********". One is taken out ".", one in "*", two out "..", one in, two out, one in ... until the buffer is empty again and the main thread suspended "w". This looks kind of as expected. But look at the rest: ****************************** *********************................................................. ..w**************************...************************************** .*.*.***************************************************************** ***r.................................********************************* r..................................................................... ...........................................................w********** ********************************************************************** ***********************************************r...................... ...................................................................... ..................................w*********************************** ********************************************************************** **********************r............................................... ...................................................................... ..........w********************************************............... ............................. It seems like the two threads do no longer run in parallel. A whole bunch of messages is deposited and then a whole bunch is taken out: bunch in, bunch out, bunch in, bunch out. What you can not see is that these dots and stars appear one by one, so that you would expect both threads to execute during any period between two dots and stars. So, the pattern should be ".*..**...***..*..*.*..**.***.***.***.*..**", but what I get is bunch in, bunch out, bunch in, bunch out. This bunch-in-bunch-out is definitely not the behavior that I see when I run two spearate PROCESSES on FreeBSD (as you know, it always seems like all processes run simultaneously). Sometimes the whole thing stops at a dot for a few seconds (indication that the main thread does some heavy stuff) without the receiver thread taking over. Note also, that the little "r"s indicate that the buffer actually is about to overflow several times after 128 messages received. This "w*************r.............w*************r" indicates that each thread is running until it is suspended due to buffer over- or underflow! Now isn't there something seriously wrong with the scheduling of green threads? I am wondering whether native thread will do better? What version of FreeBSD do I have to upgrade to to get Java with native threads? Do green threads properly suspend a thread that is waiting for a device, just like the OS does it with processes? Or is the green thread sheduler just a time slice weel turning at an equal speed? Seems like old Windows 3.11 scheduler to me. Any Idea? In order for you to see what I do, or to try it out, I append the simple Receiver class at the end here: class Overflow extends Throwable { }; public class Receiver extends Thread { // THE RINGBUFFER // 1. capacity static final int capacity = 128; // 2. the buffer array Message[] buffer = new Message[capacity]; // 3. the writer's (receiver's) pointer int wpointer = 0; // 4. the reader's (client's, main thread's) pointer int rpointer = capacity; // STUFF THAT HANDLES SUSPENSION FOR UNDER- OR OVERFLOW // this is raised (locally) for under and overflow. Overflow overflow = new Overflow(); // if buffer underflow occured boolean client_waits = false; // if buffer overflow occured boolean receiver_waits = false; // a handle for the receiver to wake up a suspended client Thread client; // VARIABLES PERTAINING TO THE MESSAGE STREAM // this is the source of incomming messages Connection conn; // the end of the message stream is indicated in this flag boolean end = false; // THE MONITOR // used by receiver thread to deposit incoming message private synchronized void padd(Message dat) throws Overflow { if(wpointer == rpointer) { receiver_waits = true; throw overflow; } buffer[wpointer++] = dat; if(wpointer >= capacity) wpointer = 0; if(client_waits) { client_waits = false; client.resume(); } } // used by receiver thread to mark the end of the message stream private synchronized void pend() { end = true; } // used by client (main) thread to withdraw message private synchronized Message pget() throws Overflow { int npointer = rpointer + 1; if(npointer >= capacity) npointer = 0; if(npointer == wpointer) if(end) return null; else { client_waits = true; throw overflow; } rpointer = npointer; Message r = buffer[rpointer]; if(receiver_waits) { receiver_waits = false; this.resume(); } return r; } // end of monitor // THE PUBLIC INTERFACE TO THE CLIENT THREAD: public boolean hasMoreMessages() { return ! end; } public Row nextMessage() { while(true) { try { return pget(); } catch(Overflow x) { System.out.print("w"); client.suspend(); } } } public Receiver(Connection conn) { super("receiver"); this.conn = conn; this.client = currentThread(); } // THE RECEIVER THREAD LOOP public void run() { while(true) { // receive a data message Message msg = conn.receive(); switch(msg.getType()) { case Message.DAT: // save message while(true) { try { padd(msg); System.out.print("*"); break; } catch(Overflow o) { } System.out.print("r"); this.suspend(); } break; case Message.END: end = true; this.stop(); } } } } thanks and sorry for the long posting ... -Gunther Gunther Schadow ----------------------------------- http://aurora.rg.iupui.edu Regenstrief Institute for Health Care 1001 W 10th Street RG5, Indianapolis IN 46202, Phone: (317) 630 7960 schadow@aurora.rg.iupui.edu ---------------------- #include To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-java" in the body of the message From owner-freebsd-java Sat Nov 14 00:04:44 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id AAA23583 for freebsd-java-outgoing; Sat, 14 Nov 1998 00:04:44 -0800 (PST) (envelope-from owner-freebsd-java@FreeBSD.ORG) Received: from swan.prod.itd.earthlink.net (swan.prod.itd.earthlink.net [207.217.120.123]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id AAA23578 for ; Sat, 14 Nov 1998 00:04:43 -0800 (PST) (envelope-from rakeshv@geocities.com) Received: from geocities.com (sdn-ar-001ohcincP054.dialsprint.net [168.191.24.38]) by swan.prod.itd.earthlink.net (8.8.7/8.8.5) with ESMTP id AAA27063 for ; Sat, 14 Nov 1998 00:04:14 -0800 (PST) Message-ID: <364D3A03.3FE987B1@geocities.com> Date: Sat, 14 Nov 1998 03:06:27 -0500 From: Rakesh Vidyadharan Organization: IMI Systems Inc. X-Mailer: Mozilla 4.5 [en] (X11; I; FreeBSD 2.2.7-RELEASE i386) X-Accept-Language: en MIME-Version: 1.0 To: freebsd-java@FreeBSD.ORG Subject: Swing incompatibility? Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-java@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org I was trying to compile a Swing application that I am developing at work, and the java source files do not compile. I keep getting errors saying "package com.sun.java.swing.* not found" or "package javax.swing.*" not found, depending on which version of Swing I am trying to use. I have exported by CLASSPATH to the proper locations. I copied the downloaded swing tar file to my Linux partition, and installed it, and all the source files compiled and ran. I do not remember whether I was using jdk1.1.5 previously when I was running 2.2.6, but I had no problems running my swing application when I was still on 2.2.6 (I currently run 2.2.7). Thanks -- Rakesh To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-java" in the body of the message From owner-freebsd-java Sat Nov 14 17:00:54 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id RAA04686 for freebsd-java-outgoing; Sat, 14 Nov 1998 17:00:54 -0800 (PST) (envelope-from owner-freebsd-java@FreeBSD.ORG) Received: from WEBBSD1.turnaround.com.au (webbsd1.turnaround.com.au [203.39.138.49]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id RAA04680 for ; Sat, 14 Nov 1998 17:00:52 -0800 (PST) (envelope-from J_Shevland@TurnAround.com.au) Received: from TurnAround.com.au (ras4.turnaround.com.au [192.168.1.115]) by WEBBSD1.turnaround.com.au (8.8.7/8.8.7) with ESMTP id MAA18245; Sun, 15 Nov 1998 12:03:57 +1100 (EST) (envelope-from J_Shevland@TurnAround.com.au) Message-ID: <364E2626.390616C6@TurnAround.com.au> Date: Sun, 15 Nov 1998 11:53:58 +1100 From: Joe Shevland Organization: Turnaround Solutions Pty. Ltd. X-Mailer: Mozilla 4.06 [en] (Win95; I) MIME-Version: 1.0 To: Rakesh Vidyadharan CC: freebsd-java@FreeBSD.ORG Subject: Re: Swing incompatibility? References: <364D3A03.3FE987B1@geocities.com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-java@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org Rakesh Vidyadharan wrote: > > I was trying to compile a Swing application that I am > developing at work, and the java source files do not > compile. I keep getting errors saying "package > com.sun.java.swing.* not found" or "package javax.swing.*" > not found, depending on which version of Swing I am trying > to use. I have exported by CLASSPATH to the proper > locations. I copied the downloaded swing tar file to my > Linux partition, and installed it, and all the source files > compiled and ran. > > I do not remember whether I was using jdk1.1.5 previously > when I was running 2.2.6, but I had no problems running my > swing application when I was still on 2.2.6 (I currently run > 2.2.7). So, does your CLASSPATH reference the Jar file by name, not just the directory? Like, CLASSPATH = .:/u1/jdk116/lib:/u1/swing/swingall.jar I'd be interested to see yours. > Thanks > -- > > Rakesh > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-java" in the body of the message -- Joe To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-java" in the body of the message From owner-freebsd-java Sat Nov 14 23:53:52 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id XAA02112 for freebsd-java-outgoing; Sat, 14 Nov 1998 23:53:52 -0800 (PST) (envelope-from owner-freebsd-java@FreeBSD.ORG) Received: from acacia.cts.ucla.edu (acacia.cts.ucla.edu [164.67.62.44]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id XAA02105; Sat, 14 Nov 1998 23:53:49 -0800 (PST) (envelope-from denis@acacia.cts.ucla.edu) Received: from localhost (denis@localhost) by acacia.cts.ucla.edu (8.8.8/8.8.8) with ESMTP id XAA15740; Sat, 14 Nov 1998 23:54:36 -0800 (PST) (envelope-from denis@acacia.cts.ucla.edu) Date: Sat, 14 Nov 1998 23:54:36 -0800 (PST) From: Denis DeLaRoca To: freebsd-java@FreeBSD.ORG cc: java-port@FreeBSD.ORG Subject: Visual Bug: (blue) window without data! 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 I have a java app run under FreeBSD that when displayed on a remote X-server on a Macintosh (either Exodus v7 or MacX 2.0) ends up displaying a (blue) window without data... the problem occurs only with this combination of remote X-server and the ported FreeBSD 1.1.x. Running the same app from a Solaris Sparc 2.6 system with java 1.1.6 works fine. The problem comes down apparently to wether I am running rooted or rootless windows on my MAC X-server. And the problem only shows in this situation, displaying to a remote X-server on another FreeBSD box or even a Solaris box works fine because those servers are running a rooted window manager. Is this a known bug of the FreeBSD port of the JDK? Is there any workaround that can be implemented on the app side? -- Denis To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-java" in the body of the message