Possible HashMap update

2013-07-03 Thread Doug Lea
A few weeks ago, in the course of doing a (hopefully-last) reworking of JDK8 ConcurrentHashMap (CHM) internals based on experience with preview versions, I noticed that the balanced tree scheme now in place as a fallback in the case of usages with many keys all with the same hashCode could also b

Re: Possible HashMap update

2013-07-05 Thread Paul Sandoz
I played with these in the lambda repo. I needed to make the following additional change for things to compile: --- a/src/share/classes/java/io/ExpiringCache.java Fri Jul 05 10:04:00 2013 +0200 +++ b/src/share/classes/java/io/ExpiringCache.java Fri Jul 05 10:45:10 2013 +0200 @@ -64,8

Re: Possible HashMap update

2013-07-08 Thread Doug Lea
On 07/05/13 04:55, Paul Sandoz wrote: I played with these in the lambda repo. I needed to make the following additional change for things to compile: --- a/src/share/classes/java/io/ExpiringCache.javaFri Jul 05 10:04:00 2013 +0200 +++ b/src/share/classes/java/io/ExpiringCache.javaFri

Re: Possible HashMap update

2013-07-25 Thread Paul Sandoz
On Jul 8, 2013, at 4:24 PM, Doug Lea wrote: > > On 07/05/13 04:55, Paul Sandoz wrote: >>> I played with these in the lambda repo. >>> >>> I needed to make the following additional change for things to compile: >>> >>> --- a/src/share/classes/java/io/ExpiringCache.javaFri Jul 05 10:04:00 >>

Re: Possible HashMap update

2013-08-07 Thread Brent Christian
Hi, Doug I like this approach. The subclassing used for nodes/entries and trees looks good, given the constraints. The before/after references that HashMap.TreeNode inherits from LinkedHashMap.Entry are superfluous when trees are used by a HashMap, but IMO we can live with that as trees in g

Re: Possible HashMap update

2013-08-12 Thread Mike Duigou
Hi Doug; Several minor recent cleanups and proposed cleanups in HashMap made me wonder how things are progressing on this work. Do you feel it's nearly ready to integrate into the jdk8 repos? What additional work remains? Are you tracking changes going in to the jdk8 repos? Mike On Jul 8 2013

Re: Possible HashMap update

2013-08-13 Thread Doug Lea
On 08/12/13 16:30, Mike Duigou wrote: Hi Doug; Several minor recent cleanups and proposed cleanups in HashMap made me wonder how things are progressing on this work. Do you feel it's nearly ready to integrate into the jdk8 repos? What additional work remains? Are you tracking changes going in

Re: Possible HashMap update

2013-08-13 Thread Remi Forax
On 08/13/2013 09:54 PM, Doug Lea wrote: On 08/12/13 16:30, Mike Duigou wrote: Hi Doug; Several minor recent cleanups and proposed cleanups in HashMap made me wonder how things are progressing on this work. Do you feel it's nearly ready to integrate into the jdk8 repos? What additional work r

Re: Possible HashMap update

2013-08-13 Thread Joe Darcy
Hi Doug, On 08/13/2013 12:54 PM, Doug Lea wrote: On 08/12/13 16:30, Mike Duigou wrote: Hi Doug; Several minor recent cleanups and proposed cleanups in HashMap made me wonder how things are progressing on this work. Do you feel it's nearly ready to integrate into the jdk8 repos? What addition

Re: Possible HashMap update

2013-08-14 Thread Alan Bateman
On 13/08/2013 22:18, Joe Darcy wrote: Have you seen the patch from Dan Smith which would revolve all the javac lint warnings in HashMap? http://mail.openjdk.java.net/pipermail/core-libs-dev/2013-August/019618.html My preference would be to get Doug's update in as soon as we can, mostly bec

Re: Possible HashMap update

2013-08-14 Thread Paul Sandoz
On Aug 14, 2013, at 12:18 PM, Alan Bateman wrote: > On 13/08/2013 22:18, Joe Darcy wrote: >> >> Have you seen the patch from Dan Smith which would revolve all the javac >> lint warnings in HashMap? >> >> http://mail.openjdk.java.net/pipermail/core-libs-dev/2013-August/019618.html > My preferen

Re: Possible HashMap update

2013-08-14 Thread Doug Lea
On 08/13/13 17:18, Joe Darcy wrote: While I haven't touched it lately (I've been distracted with a lot of other things), last I left it, it seemed integratable. I haven't seen any list traffic that seems applicable, except for Remi's, that I ought to reply to... Have you seen the patch from Da

Re: Possible HashMap update

2013-08-14 Thread Doug Lea
On 08/13/13 16:56, Remi Forax wrote: And that the iterators on entrySet, keySet and values doesn't have their method forEachRemaining overriden (unlike java.util.ArrayList). Are you saying that all iterators should define forEachRemaining? Seems excessive. All iterators for ArrayList, HashMa

Re: Possible HashMap update

2013-08-14 Thread Alan Bateman
On 14/08/2013 12:02, Doug Lea wrote: : Aside: What's up with doclint complaining about no comments on package declarations? Who puts doc comments on package declarations? [javac] /home/dl/concurrent/src/main/java/util/HashMap.java:26: warning: no comment [javac] package java.util; I

Re: Possible HashMap update

2013-08-14 Thread Remi Forax
On 08/14/2013 01:16 PM, Doug Lea wrote: On 08/13/13 16:56, Remi Forax wrote: And that the iterators on entrySet, keySet and values doesn't have their method forEachRemaining overriden (unlike java.util.ArrayList). Are you saying that all iterators should define forEachRemaining? Seems exces

Re: Possible HashMap update

2013-08-15 Thread Doug Lea
On 08/14/13 09:23, Remi Forax wrote: On 08/14/2013 01:16 PM, Doug Lea wrote: On 08/13/13 16:56, Remi Forax wrote: And that the iterators on entrySet, keySet and values doesn't have their method forEachRemaining overriden (unlike java.util.ArrayList). Could you explain exactly when these tri

Re: Possible HashMap update

2013-08-15 Thread Remi Forax
On 08/15/2013 04:33 PM, Doug Lea wrote: On 08/14/13 09:23, Remi Forax wrote: On 08/14/2013 01:16 PM, Doug Lea wrote: On 08/13/13 16:56, Remi Forax wrote: And that the iterators on entrySet, keySet and values doesn't have their method forEachRemaining overriden (unlike java.util.ArrayList).

Re: Possible HashMap update

2013-08-16 Thread Brent Christian
On 8/14/13 3:34 AM, Paul Sandoz wrote: If no one else volunteers i can try and sort this out and sync up stuff from the current HashMap/LinkedHashMap (e.g. forEachRem. as reported by Remi) and the lint warnings in one go, and submit for review. That would be great, Paul. One thing on my mind