Date: Thu, 23 Aug 2007 11:25:48 -0700 (PDT) From: Nick Johnson <freebsd@spatula.net> To: freebsd-java@freebsd.org Subject: making nio use kevent/kqueue Message-ID: <20070823111051.N82369@turing>
next in thread | raw e-mail | index | archive | help
I think there could be a considerable performance gain if java.nio were tweaked to use kevent/kqueue(2) as opposed to poll(2). It looks like the files that would need to be touched for this are: j2se/src/solaris/native/sun/nio/ch/ DevPollArrayWrapper.c (not sure about this one actually since FreeBSD doesn't use /dev/poll) PollArrayWrapper.c SocketChannelImpl.c Does that sound about right? I see select(2) and poll(2) used in other places as well, though outside of nio where they're likely to show the greatest benefit. Are there any caveats or "gotchas" I should be aware if should I decide to take some free time to try to come up with a kevent patch for nio? Also, is there a quicker way to build a JVM when just changing a file or two like this? It would be lousy to have to wait 2 hours to build after every minor change... Nick -- "Courage isn't just a matter of not being frightened, you know. It's being afraid and doing what you have to do anyway." Doctor Who - Planet of the Daleks This message has been brought to you by Nick Johnson 2.3b1 and the number 6. http://healerNick.com/ http://morons.org/ http://spatula.net/
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20070823111051.N82369>