EPollArrayWrapper.release should be O(N), not O(N^2)
Joseph D. Darcy
Joe.Darcy at Sun.COM
Thu Nov 5 21:54:12 PST 2009
Martin Buchholz wrote:
> I believe this fix is important enough to
> do the (trivial and low-risk) backport to openjdk6,
> and am offering to do so.
Fine by me; approved to go back once the security fixes hit the repository.
I'm checking into what the holdup is...
> On Wed, Nov 4, 2009 at 13:57, Alan Bateman <Alan.Bateman at sun.com> wrote:
>> Martin Buchholz wrote:
>>> OK, I've renamed ExpensiveCancel to LotsOfCancels and regenerated the
>> Looks fine.
>>> I'll also look to replace the list in milestone 6 as the
>>> close/cancel shouldn't be O(N).
>>> We were thinking along those lines as well.
>>> Perhaps a concurrent data structure could be used here as well?
>>> I think Google engineers will help review.
>> I haven't seen any contention on the updateList but clearly the change to
>> flush pending registrations will change that (that one is embarrassing and
>> I'm glad that you/Igor caught this). We just need to replace it with
>> something that is directly addressable and supports iteration. The original
>> need to preserve ordering can also go away if we are careful to convert the
>> pending ops. Also, we can use two registratrions lists/whatever so that
>> updateRegistrations can process the pending updates concurrently with any
>> threads that are registering channels or changing interest ops.
More information about the nio-dev