Re: Codereview needed for #6929479

2010-02-27 Thread Martin Buchholz
I think some documentation of the problem, and a practical description of how users can deal with it, is the most important thing. Old unix-isms, like cp test/foo.jar production/foo.jar jar cf production/foo.jar ... some...unix..command > production/foo.jar rsync -a test/ production/ need to be e

Re: Codereview needed for #6929479

2010-02-27 Thread Christos Zoulas
On Feb 27, 5:49pm, marti...@google.com (Martin Buchholz) wrote: -- Subject: Re: Codereview needed for #6929479 | On Thu, Feb 25, 2010 at 12:09, Lance J. Andersen wrote: | > Going forward, should we be using sun or oracle in the property names? | | It is impractical to stamp out the "sun" in th

Re: Codereview needed for #6929479

2010-02-27 Thread Martin Buchholz
On Thu, Feb 25, 2010 at 12:09, Lance J. Andersen wrote: > Going forward, should we be using sun or oracle in the property names? It is impractical to stamp out the "sun" in the API, even though it's "private". There are too many references to sun.* in third party code to consider a massive renam

Re: Need reviewer for forward port of 6815768 (File.getXXXSpace) and 6815768 (String.hashCode)

2010-02-27 Thread Ulf Zibis
Am 26.02.2010 20:32, schrieb Alan Bateman: Ulf Zibis wrote: For these other suggestions it would be great to create micro-benchmarks and try our your changes. For now though, as I said, I'm just fixing the method to avoid the store for the empty string case. I've added benchmark for "same" str

RE: Need reviewer for forward port of 6815768 (File.getXXXSpace) and 6815768 (String.hashCode)

2010-02-27 Thread Jason Mehrens
Javap shows different byte code for hashCode7 vs hashCode1 when I compiled and compared them. I'll have not tried jclasslib. I agree with you on version 7 should be faster than version 6. However, in version 6 count is only loaded twice when running the path rarely chosen. I think that

hg: jdk7/tl/jdk: 6929259: Remove double spaces from Dual-pivot quicksort

2010-02-27 Thread alan . bateman
Changeset: b77e94f5a601 Author:alanb Date: 2010-02-27 19:15 + URL: http://hg.openjdk.java.net/jdk7/tl/jdk/rev/b77e94f5a601 6929259: Remove double spaces from Dual-pivot quicksort Reviewed-by: alanb Contributed-by: vladimir.yaroslavs...@sun.com ! src/share/classes/java/util/Dual

Re: Need reviewer for forward port of 6815768 (File.getXXXSpace) and 6815768 (String.hashCode)

2010-02-27 Thread Ulf Zibis
Am 26.02.2010 16:27, schrieb Dmitry Nadezhin: On Fri, Feb 26, 2010 at 6:19 PM, Ulf Zibis > wrote: Am 26.02.2010 12:52, schrieb Dmitry Nadezhin: I found two alternatives in the link http://mail.openjdk.java.net/pipermail/coin-dev/2009-December/002

hg: jdk7/tl/jdk: 6929532: (file) WatchService should avoid queuing new modify events when lots of files are changing

2010-02-27 Thread alan . bateman
Changeset: 77beb60b39c6 Author:alanb Date: 2010-02-27 18:18 + URL: http://hg.openjdk.java.net/jdk7/tl/jdk/rev/77beb60b39c6 6929532: (file) WatchService should avoid queuing new modify events when lots of files are changing Reviewed-by: alanb Contributed-by: sebastian.sickelm...

Re: Need reviewer for forward port of 6815768 (File.getXXXSpace) and 6815768 (String.hashCode)

2010-02-27 Thread Ulf Zibis
Hm, hashCode7() has exactly the same program logic than hashCode1(), but by different syntax. hashCode8() should be worse than hashCode7(), because it loads the count variable twice. If you compare the byte code by javah or jclasslib bytecode viewer (very nice tool), you will see that, am I wr

RE: Need reviewer for forward port of 6815768 (File.getXXXSpace) and 6815768 (String.hashCode)

2010-02-27 Thread Jason Mehrens
Here are two more variants you might want to throw into the benchmark. public int hashCode6() { int h = hash; if (h == 0 && count > 0) { int off = offset; char val[] = value; int len = count; for (int i = 0; i < len; i++) {

Re: Need reviewer for forward port of 6815768 (File.getXXXSpace) and 6815768 (String.hashCode)

2010-02-27 Thread Ulf Zibis
Dmitry, thanks for the interesting results. Your results are not as promising as mine. I guess, referring to the HotSpot's dissassembler dump would give more hints. Additionally different string lengths, repeat factors, -Xbatch, and GC settings would help. Good trick to use substring(1) for

Re: Need reviewer for forward port of 6815768 (File.getXXXSpace) and 6815768 (String.hashCode)

2010-02-27 Thread Dmitry Nadezhin
Ulf, I ran Caliper benchmarks on different variants of hashCode(). http://code.google.com/p/caliper/ The results and the Caliper code are below: -Dima - -d32 -clien 0% Scenario{vm=java -d32 -client, benchmark=HashCodeEmpty} 8,85ns; σ=0,06ns @ 3 trials 8% Scenario{vm=java -d32 -client