RFR 8014133: Spliterator.OfPrimitive

2013-05-14 Thread Paul Sandoz
Hi, Please review: http://cr.openjdk.java.net/~psandoz/lambda/spliterator/jdk-8014133/webrev/ http://cr.openjdk.java.net/~psandoz/lambda/spliterator/jdk-8014133/specdiff/overview-summary.html This enables more sharing of primitive-based spliterator code and should also reduce the bloat of

bug 8014477 Race in String.contentEquals

2013-05-14 Thread Peter Levart
Ok, here's the corrected fix: http://cr.openjdk.java.net/~plevart/jdk8-tl/String.contentEquals/webrev.03/ I also added a reproducer for the bug. Regards, peter On 05/14/2013 07:53 AM, Peter Levart wrote: Right, sb.length() should be used. I will correct that as soon as I get to the

Re: bug 8014477 Race in String.contentEquals

2013-05-14 Thread David Holmes
Thanks Peter this looks good to me. One minor thing please set the correct copyright year in the test, it should just be Copyright (c) 2013, Oracle ... I couldn't get the test to actually fail, but I can see that it could. David On 14/05/2013 9:04 PM, Peter Levart wrote: Ok, here's the

Re: RFR: 7038105 - File.isHidden() should return true for pagefile.sys and hiberfil.sys

2013-05-14 Thread Alan Bateman
On 14/05/2013 02:59, Rob McKenna wrote: Hi folks, Looking for a review of this suggested fix from Fujitsu. GetFileAttributesExW() returns ERROR_SHARING_VIOLATION for pagefile.sys and hiberfi.sys so we're falling back to FindFirstFile instead:

Re: bug 8014477 Race in String.contentEquals

2013-05-14 Thread Peter Levart
On 05/14/2013 01:17 PM, David Holmes wrote: Thanks Peter this looks good to me. One minor thing please set the correct copyright year in the test, it should just be Copyright (c) 2013, Oracle ... Ok, fixed: http://cr.openjdk.java.net/~plevart/jdk8-tl/String.contentEquals/webrev.04/ I

8014500: bootcycle-images fails after upgrade to JAXP 1.5

2013-05-14 Thread Alan Bateman
The bootcycle-images target is currently broken in jdk8/tl. Jon has taken 8014461 to fix genstubs but once you get past that then the CLDRConverter fails parsing LDML due to DTD references that aren't allowed by the default policy in jdk8 (since the update to JAXP 1.5). This policy is due to

Re: 8014500: bootcycle-images fails after upgrade to JAXP 1.5

2013-05-14 Thread Lance Andersen - Oracle
+1 On May 14, 2013, at 8:16 AM, Alan Bateman wrote: The bootcycle-images target is currently broken in jdk8/tl. Jon has taken 8014461 to fix genstubs but once you get past that then the CLDRConverter fails parsing LDML due to DTD references that aren't allowed by the default policy in

Re: Code review request for JDK-8014365 Restore Objects.requireNonNull(T, SupplierString)

2013-05-14 Thread Alan Bateman
On 10/05/2013 22:01, Joe Darcy wrote: Hello, Please (re)review this change to introduce Objects.requireNonNull(T, SupplierString): http://cr.openjdk.java.net/~darcy/8014365.0/ The original change had to be pulled out because of a build issue (8012343:

hg: jdk8/tl/jdk: 8014500: bootcycle-images fails after upgrade to JAXP 1.5

2013-05-14 Thread alan . bateman
Changeset: b315cb9a7544 Author:alanb Date: 2013-05-14 14:32 +0100 URL: http://hg.openjdk.java.net/jdk8/tl/jdk/rev/b315cb9a7544 8014500: bootcycle-images fails after upgrade to JAXP 1.5 Reviewed-by: lancea ! make/tools/src/build/tools/cldrconverter/CLDRConverter.java

Time to put a stop to Thread.stop?

2013-05-14 Thread Alan Bateman
I would like to broach the subject of pulling out the implementation of Thread.stop(Throwable), maybe suspend/resume later. By pulling out I mean changing it to unconditionally throw UnsupportedOperationException. As we all know, these methods have been deprecated since 1998 so that's 15

Re: 8014500: bootcycle-images fails after upgrade to JAXP 1.5

2013-05-14 Thread Erik Joelsson
Looks good from the build side. /Erik On 2013-05-14 14:16, Alan Bateman wrote: The bootcycle-images target is currently broken in jdk8/tl. Jon has taken 8014461 to fix genstubs but once you get past that then the CLDRConverter fails parsing LDML due to DTD references that aren't allowed by

Re: Time to put a stop to Thread.stop?

2013-05-14 Thread Brian Goetz
If we can't deprecate this, we might as well deprecate @Deprecated. On May 14, 2013, at 10:25 AM, Alan Bateman wrote: I would like to broach the subject of pulling out the implementation of Thread.stop(Throwable), maybe suspend/resume later. By pulling out I mean changing it to

RE: Time to put a stop to Thread.stop?

2013-05-14 Thread Jeroen Frijters
IMO Thread.currentThread().stop(new Throwable()) should continue to work. It is not unsafe and it is probably used in a lot of code to workaround the madness that is checked exceptions. -Original Message- From: core-libs-dev-boun...@openjdk.java.net [mailto:core-libs-dev-

Re: Time to put a stop to Thread.stop?

2013-05-14 Thread Remi Forax
On 05/14/2013 04:45 PM, Jeroen Frijters wrote: IMO Thread.currentThread().stop(new Throwable()) should continue to work. It is not unsafe and it is probably used in a lot of code to workaround the madness that is checked exceptions. This hack doesn't work well because Thread.stop(Throwable)

Re: RFR: 8013395 StringBuffer.toString performance regression impacting embedded benchmarks

2013-05-14 Thread Mike Duigou
Looks good David. Mike On May 13 2013, at 22:10 , David Holmes wrote: On 14/05/2013 5:05 AM, Alan Bateman wrote: On 13/05/2013 08:12, David Holmes wrote: Thanks for all the feedback and discussion. I've rewritten the patch to use Peter's suggestion of caching the char[] instead of the

Re: bug 8014477 Race in String.contentEquals

2013-05-14 Thread Mike Duigou
Good to see the test added. I was also unable to reproduce the failure on my Core 2 Duo Mac laptop but the test and fix match up. Mike On May 14 2013, at 04:34 , Peter Levart wrote: On 05/14/2013 01:17 PM, David Holmes wrote: Thanks Peter this looks good to me. One minor thing please set

Re: RFR 8014133: Spliterator.OfPrimitive

2013-05-14 Thread Mike Duigou
Nice cleanup. Looks good. Mike On May 14 2013, at 00:17 , Paul Sandoz wrote: Hi, Please review: http://cr.openjdk.java.net/~psandoz/lambda/spliterator/jdk-8014133/webrev/ http://cr.openjdk.java.net/~psandoz/lambda/spliterator/jdk-8014133/specdiff/overview-summary.html This

RE: Time to put a stop to Thread.stop?

2013-05-14 Thread Jeroen Frijters
I agree that (ab)using generics is the better way, but that doesn't matter, this trick is much older so it is probably used somewhere and there is no good reason to break it. I'm fully in favor of removing the ability to throw arbitrary exceptions on other threads. IKVM doesn't support this

hg: jdk8/tl/jdk: 8012453: (process) Runtime.exec(String) fails if command contains spaces [win]

2013-05-14 Thread alexey . utkin
Changeset: 5ea5f5dfb96a Author:uta Date: 2013-05-14 20:16 +0400 URL: http://hg.openjdk.java.net/jdk8/tl/jdk/rev/5ea5f5dfb96a 8012453: (process) Runtime.exec(String) fails if command contains spaces [win] Reviewed-by: alanb ! src/share/classes/java/lang/ProcessBuilder.java !

Re: Time to put a stop to Thread.stop?

2013-05-14 Thread Martin Buchholz
On Tue, May 14, 2013 at 7:45 AM, Jeroen Frijters jer...@sumatra.nl wrote: IMO Thread.currentThread().stop(new Throwable()) should continue to work. It is not unsafe and it is probably used in a lot of code to workaround the madness that is checked exceptions. There are existing JDK tests

Re: Time to put a stop to Thread.stop?

2013-05-14 Thread David DeHaven
@Deprecated: never -DrD- If we can't deprecate this, we might as well deprecate @Deprecated. On May 14, 2013, at 10:25 AM, Alan Bateman wrote: I would like to broach the subject of pulling out the implementation of Thread.stop(Throwable), maybe suspend/resume later. By pulling out I

hg: jdk8/tl/langtools: 8012556: Implement lambda methods on interfaces as static; ...

2013-05-14 Thread robert . field
Changeset: c09b7234cded Author:rfield Date: 2013-05-14 11:11 -0700 URL: http://hg.openjdk.java.net/jdk8/tl/langtools/rev/c09b7234cded 8012556: Implement lambda methods on interfaces as static 8006140: Javac NPE compiling Lambda expression on initialization expression of static

Re: Time to put a stop to Thread.stop?

2013-05-14 Thread Alan Bateman
On 14/05/2013 17:57, Martin Buchholz wrote: : There are existing JDK tests that use currentThread().stop to implement the occasionally necessary sneakyThrow. Yes, there are 4 j.u.c. tests, I haven't come across others. -Alan

RFR 8014217: Base64.getXDecoder().wrap(...).read() doesn't throw exception for an incorrect number of padding chars in the final unit

2013-05-14 Thread Xueming Shen
Hi, Please help review the change for handling a malformed base64 stream corner case. The latest spec has been updated/clarified as If there is padding character present in the final unit, the correct number of padding character(s) must be present, otherwise IllegalArgumentException is thrown

hg: jdk8/tl/jdk: 6328537: Improve javadocs for Socket class by adding references to SocketOptions

2013-05-14 Thread kurchi . subhra . hazra
Changeset: 790d292ee761 Author:khazra Date: 2013-05-14 12:01 -0700 URL: http://hg.openjdk.java.net/jdk8/tl/jdk/rev/790d292ee761 6328537: Improve javadocs for Socket class by adding references to SocketOptions Summary: Insert references to SocketOptions.java where applicable

Re: RFR 8014133: Spliterator.OfPrimitive

2013-05-14 Thread Remi Forax
On 05/14/2013 05:41 PM, Mike Duigou wrote: Nice cleanup. Looks good. Mike looks good. RĂ©mi On May 14 2013, at 00:17 , Paul Sandoz wrote: Hi, Please review: http://cr.openjdk.java.net/~psandoz/lambda/spliterator/jdk-8014133/webrev/

Re: RFR 8014217: Base64.getXDecoder().wrap(...).read() doesn't throw exception for an incorrect number of padding chars in the final unit

2013-05-14 Thread Chris Hegarty
Is there a conflict between the spec and implement? IOE versus IAE? -Chris On 14 May 2013, at 19:50, Xueming Shen xueming.s...@oracle.com wrote: Hi, Please help review the change for handling a malformed base64 stream corner case. The latest spec has been updated/clarified as If there

Re: RFR 8014217: Base64.getXDecoder().wrap(...).read() doesn't throw exception for an incorrect number of padding chars in the final unit

2013-05-14 Thread Xueming Shen
It has been discussed before that the IOE is preferred in case of the wrapped decoding stream. The spec of wrap() does mention that IOE when reading bytes that can not be decoded. So personally I feel it has been covered, but if preferred, it can go further as If there is padding character

Re: RFR 8014217: Base64.getXDecoder().wrap(...).read() doesn't throw exception for an incorrect number of padding chars in the final unit

2013-05-14 Thread Alan Bateman
On 14/05/2013 20:32, Xueming Shen wrote: It has been discussed before that the IOE is preferred in case of the wrapped decoding stream. The spec of wrap() does mention that IOE when reading bytes that can not be decoded. So personally I feel it has been covered, but if preferred, it can go

Re: RFR 8014217: Base64.getXDecoder().wrap(...).read() doesn't throw exception for an incorrect number of padding chars in the final unit

2013-05-14 Thread Chris Hegarty
Thanks for the explanation Sherman. No further changes required. What you have is fine. My question was provoked because the details in the email seemed at odds with the changes. -Chris On 14 May 2013, at 20:32, Xueming Shen xueming.s...@oracle.com wrote: It has been discussed before that

Re: RFR 8012326: Deadlock occurs when Charset.availableCharsets() is called by several threads at the same time

2013-05-14 Thread Xueming Shen
Thanks Mandy! Webrev has been updated to put the final back as suggested. http://cr.openjdk.java.net/~sherman/8012326/webrev/ https://jbs.oracle.com/bugs/browse/JDK-8014565 has been filed for future enhancement of ExtededCharsets class. -Sherman On 05/14/2013 12:29 PM, Mandy Chung wrote: On

hg: jdk8/tl/langtools: 8014461: genstubs creates default native methods

2013-05-14 Thread jonathan . gibbons
Changeset: 46b9c25f7024 Author:jjg Date: 2013-05-14 12:55 -0700 URL: http://hg.openjdk.java.net/jdk8/tl/langtools/rev/46b9c25f7024 8014461: genstubs creates default native methods Reviewed-by: alanb ! make/tools/genstubs/GenStubs.java

RFR: 4837946 - Faster multiplication and exponentiation of large integers

2013-05-14 Thread Brian Burkhalter
This is the first of an eventual four phases of performance improvement of BigInteger for large integers. Issue: http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=4837946 Webrev: http://cr.openjdk.java.net/~bpb/4837946/ This contains Alan Eliasen's implementation of Karatsuba and 3-way

Re: RFR 8012326: Deadlock occurs when Charset.availableCharsets() is called by several threads at the same time

2013-05-14 Thread Mandy Chung
Thanks. Looks good. Mandy On 5/14/13 12:51 PM, Xueming Shen wrote: Thanks Mandy! Webrev has been updated to put the final back as suggested. http://cr.openjdk.java.net/~sherman/8012326/webrev/ https://jbs.oracle.com/bugs/browse/JDK-8014565 has been filed for future enhancement of

Re: RFR 8014217: Base64.getXDecoder().wrap(...).read() doesn't throw exception for an incorrect number of padding chars in the final unit

2013-05-14 Thread Xueming Shen
Thanks Chris, I updated the wording as Alan suggest to just make sure there is no doubt on the behavior :-) http://cr.openjdk.java.net/~sherman/8014217/webrev/ -Sherman On 05/14/2013 12:46 PM, Chris Hegarty wrote: Thanks for the explanation Sherman. No further changes required. What you have

Re: RFR 8012326: Deadlock occurs when Charset.availableCharsets() is called by several threads at the same time

2013-05-14 Thread Alan Bateman
On 14/05/2013 20:51, Xueming Shen wrote: Thanks Mandy! Webrev has been updated to put the final back as suggested. http://cr.openjdk.java.net/~sherman/8012326/webrev/ https://jbs.oracle.com/bugs/browse/JDK-8014565 has been filed for future enhancement of ExtededCharsets class. -Sherman The

hg: jdk8/tl/langtools: 8014557: Mutable static field in HtmlDocletWriter

2013-05-14 Thread jonathan . gibbons
Changeset: 0384683c64be Author:jjg Date: 2013-05-14 13:55 -0700 URL: http://hg.openjdk.java.net/jdk8/tl/langtools/rev/0384683c64be 8014557: Mutable static field in HtmlDocletWriter Reviewed-by: ksrini ! src/share/classes/com/sun/tools/doclets/formats/html/HtmlDocletWriter.java

hg: jdk8/tl/jdk: 8012326: Deadlock occurs when Charset.availableCharsets() is called by several threads at the same time

2013-05-14 Thread xueming . shen
Changeset: 08ef70f60e0d Author:sherman Date: 2013-05-14 14:09 -0700 URL: http://hg.openjdk.java.net/jdk8/tl/jdk/rev/08ef70f60e0d 8012326: Deadlock occurs when Charset.availableCharsets() is called by several threads at the same time Summary: removed the race condition risk from

hg: jdk8/tl/jdk: 8014217: Base64.getXDecoder().wrap(...).read() doesn't throw exception for an incorrect number of padding chars in the final unit

2013-05-14 Thread xueming . shen
Changeset: c70fff3db913 Author:sherman Date: 2013-05-14 14:20 -0700 URL: http://hg.openjdk.java.net/jdk8/tl/jdk/rev/c70fff3db913 8014217: Base64.getXDecoder().wrap(...).read() doesn't throw exception for an incorrect number of padding chars in the final unit Summary: to throw IOE

hg: jdk8/tl/langtools: 8013852: update reference impl for type-annotations

2013-05-14 Thread jonathan . gibbons
Changeset: ddb4a2bfcd82 Author:jjg Date: 2013-05-14 15:04 -0700 URL: http://hg.openjdk.java.net/jdk8/tl/langtools/rev/ddb4a2bfcd82 8013852: update reference impl for type-annotations Reviewed-by: jjg Contributed-by: wdi...@gmail.com, steve.si...@oracle.com, joel.fra...@oracle.com,

RFR : 7129185 : (M) Add Collections.{checked|empty|unmodifiable}Navigable{Map|Set}

2013-05-14 Thread Mike Duigou
Hello all; I've continued to refine the previously posted patch and think it's now quite close to complete. I am going to scour the tests looking for additional conditions that need to be checked but this seems to be very nearly finished.

hg: jdk8/tl/langtools: 8013163: Convert 4 tools multicatch tests to jtreg format

2013-05-14 Thread jonathan . gibbons
Changeset: 53b389eb39c1 Author:sogoel Date: 2013-05-14 18:02 -0700 URL: http://hg.openjdk.java.net/jdk8/tl/langtools/rev/53b389eb39c1 8013163: Convert 4 tools multicatch tests to jtreg format Reviewed-by: jjg + test/tools/javac/multicatch/Pos11.java +

4646474 : BigInteger.pow() algorithm slow in 1.4.0

2013-05-14 Thread Brian Burkhalter
The test in this issue report http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=4646474 is pretty much useless for comparative purposes after applying 4837946 as the computed value is just a power of two which will be handled very quickly by the new algorithm. As a single alternate data

Re: Time to put a stop to Thread.stop?

2013-05-14 Thread David Holmes
On 15/05/2013 2:57 AM, Martin Buchholz wrote: On Tue, May 14, 2013 at 7:45 AM, Jeroen Frijters jer...@sumatra.nl wrote: IMO Thread.currentThread().stop(new Throwable()) should continue to work. It is not unsafe and it is probably used in a lot of code to workaround the madness that is checked

hg: jdk8/tl/langtools: 8014323: Add VariableTree.getNameExpression

2013-05-14 Thread jonathan . gibbons
Changeset: 529fb3ed5d2a Author:jjg Date: 2013-05-14 21:08 -0700 URL: http://hg.openjdk.java.net/jdk8/tl/langtools/rev/529fb3ed5d2a 8014323: Add VariableTree.getNameExpression Reviewed-by: darcy ! src/share/classes/com/sun/source/tree/VariableTree.java !

Re: bug 8014477 Race in String.contentEquals

2013-05-14 Thread David Holmes
On 14/05/2013 9:34 PM, Peter Levart wrote: On 05/14/2013 01:17 PM, David Holmes wrote: Thanks Peter this looks good to me. One minor thing please set the correct copyright year in the test, it should just be Copyright (c) 2013, Oracle ... Ok, fixed:

RFR : 8004015 : (S) Additional Functional Interface instance and static methods

2013-05-14 Thread Mike Duigou
Hello all; This a fairly small set of additional methods for the existing Java 8 functional interfaces. These methods have been held back until now awaiting support for static interface methods. http://cr.openjdk.java.net/~mduigou/JDK-8004015/0/webrev/ Mike

Re: Time to put a stop to Thread.stop?

2013-05-14 Thread Martin Buchholz
On Tue, May 14, 2013 at 8:17 PM, David Holmes david.hol...@oracle.comwrote: On 15/05/2013 2:57 AM, Martin Buchholz wrote: On Tue, May 14, 2013 at 7:45 AM, Jeroen Frijters jer...@sumatra.nl wrote: IMO Thread.currentThread().stop(**new Throwable()) should continue to work. It is not unsafe