public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "tromey at gcc dot gnu dot org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug libgcj/23682] gnu.java.nio.SelectorImpl.select(long) throws ArrayIndexOutOfBoundsException Date: Fri, 28 Jul 2006 22:06:00 -0000 [thread overview] Message-ID: <20060728220621.11980.qmail@sourceware.org> (raw) In-Reply-To: <bug-23682-11287@http.gcc.gnu.org/bugzilla/> ------- Comment #5 from tromey at gcc dot gnu dot org 2006-07-28 22:06 ------- I have a patch I'm testing. This code in classpath looks quite bad :( I fixed this problem by adding synchronization. However, really very little synchronization should be needed. Instead we could be doing something like building a data structure for poll() ahead of time and tracking changes to the selection keys more directly; I think this would yield better performance. Right now we do multiple allocations for every select operation. Also I suspect that using select(2) instead of poll(2) is bad for applications making large numbers of connections. select has built-in limits on the the number of file descriptors it can use. Finally. our code to select without waiting actually will wait for up to 1ms. This is fixable as well, it looks like the original author just did it the "simple" way for convenience of writing a single native method. -- tromey at gcc dot gnu dot org changed: What |Removed |Added ---------------------------------------------------------------------------- AssignedTo|unassigned at gcc dot gnu |tromey at gcc dot gnu dot |dot org |org Status|NEW |ASSIGNED Last reconfirmed|2006-04-05 21:38:39 |2006-07-28 22:06:20 date| | http://gcc.gnu.org/bugzilla/show_bug.cgi?id=23682
next prev parent reply other threads:[~2006-07-28 22:06 UTC|newest] Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top [not found] <bug-23682-11287@http.gcc.gnu.org/bugzilla/> 2006-04-03 13:02 ` green at redhat dot com 2006-04-05 21:38 ` tromey at gcc dot gnu dot org 2006-07-28 22:06 ` tromey at gcc dot gnu dot org [this message] 2006-07-31 21:58 ` tromey at gcc dot gnu dot org 2006-07-31 22:09 ` cvs-commit at developer dot classpath dot org 2006-08-07 22:24 ` cvs-commit at developer dot classpath dot org 2006-08-07 22:24 ` cvs-commit at developer dot classpath dot org 2007-03-30 21:53 ` tromey at gcc dot gnu dot org 2005-09-01 17:58 [Bug libgcj/23682] New: " gcc-bugzilla at future dot shiny dot co dot il 2005-09-01 18:53 ` [Bug libgcj/23682] " pinskia at gcc dot gnu dot org 2005-09-01 19:11 ` gcc-bugzilla at future dot shiny dot co dot il
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20060728220621.11980.qmail@sourceware.org \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).