Re: RFR: 6543126: Level.known can leak memory

2016-08-16 Thread Mandy Chung
> On Aug 16, 2016, at 5:42 AM, Daniel Fuchs wrote: > > Hi Mandy, > > I added an additional selector parameter to the find methods. > This made it possible to return Optional instead of > KnownLevel - and it does simply the parse() method. > > http://cr.openjdk.java.net/~dfuchs/webrev_6543126/w

Re: RFR 9 7180225 : SecurityExceptions not defined in some class loader methods

2016-08-16 Thread Mandy Chung
> On Aug 16, 2016, at 1:54 PM, Brent Christian > wrote: > > Hi, > > Please review this change which does some cleanup around documenting > conditions for throwing SecurityExceptions. > > It adds a missing @throws tag to Class.forName(String, boolean, ClassLoader), > and consolidates specifi

Re: Collectors.toSet() small performance improvement

2016-08-16 Thread Tagir F. Valeev
Hello, Paul! Thank you. Here's issue: https://bugs.openjdk.java.net/browse/JDK-8164189 And webrev: http://cr.openjdk.java.net/~tvaleev/webrev/8164189/r1/ With best regards, Tagir Valeev. PS> Hi Tagir, PS> I like it. Please open an issue and i will sponsor the fix for you. PS> Thanks, PS> Paul.

Re: RFR: JDK-8161230 - Create java.util.stream.Stream from Iterator / Enumeration

2016-08-16 Thread Paul Sandoz
> On 8 Aug 2016, at 12:14, Patrick Reinhart wrote: > > >> Am 08.08.2016 um 18:55 schrieb Alan Bateman : >> >> On 08/08/2016 17:29, Patrick Reinhart wrote: >> >>> : >>> I tried to integrate your suggested changes here: >>> http://cr.openjdk.java.net/~reinhapa/reviews/8161230/ClassLoader_Stream

[9] RFR: 8164159: java/nio/file/WatchService/UpdateInterference.java test leaves daemon threads

2016-08-16 Thread Artem Smotrakov
Hello, Please review the following patch for java/nio/file/WatchService/UpdateInterference.java test. The test creates a couple of daemon threads which have an infinite loop inside. When the test finishes, those daemon still keep running as long as jtreg use this instance of JVM to run other

Re: Collectors.toSet() small performance improvement

2016-08-16 Thread Paul Sandoz
Hi Tagir, I like it. Please open an issue and i will sponsor the fix for you. Thanks, Paul. > On 8 Aug 2016, at 22:31, Tagir F. Valeev wrote: > > Hello! > > I'd like to propose a simple performance patch for Collectors.toSet(): > > --- a/src/java.base/share/classes/java/util/stream/Collector

Re: RFR (JAXP) 6211561: XPath.evaluate(String, Object, QName) throws exception if context node is null

2016-08-16 Thread Lance Andersen
+1 > On Aug 16, 2016, at 2:59 PM, Joe Wang wrote: > > Hi, > > Please review a javadoc fix for XPath, and the same for XPathExpression. > Error message is improved to be more relevant. > > Please ignore the Lic header for XPATHErrorResources.java, they will be > handled in the future. > > JBS

Re: RFR of JDK9 8162519: Remove ParallelPrefix.java from ProblemList.txt

2016-08-16 Thread Paul Sandoz
> On 15 Aug 2016, at 01:12, Hamlin Li wrote: > > There are 2 issues related to test/java/util/Arrays/ParallelPrefix.java, > > 1. JDK-8080165, which is marked as samebinary-highfrequency. Based on below > information, I think this bug should have been resolved, although I don't > know which ch

RFR (JAXP) 6211561: XPath.evaluate(String, Object, QName) throws exception if context node is null

2016-08-16 Thread Joe Wang
Hi, Please review a javadoc fix for XPath, and the same for XPathExpression. Error message is improved to be more relevant. Please ignore the Lic header for XPATHErrorResources.java, they will be handled in the future. JBS: https://bugs.openjdk.java.net/browse/JDK-6211561 Webrev: http://cr.

RFR 9 7180225 : SecurityExceptions not defined in some class loader methods

2016-08-16 Thread Brent Christian
Hi, Please review this change which does some cleanup around documenting conditions for throwing SecurityExceptions. It adds a missing @throws tag to Class.forName(String, boolean, ClassLoader), and consolidates specifics in the @throws tags of ClassLoader & Thread. Bug: https://bugs.

Re: [jdk9] RFR: 8163517: Various cleanup in java.io code

2016-08-16 Thread Ivan Gerasimov
Thank you Aleksey for your careful review! On 16.08.2016 16:08, Aleksey Shipilev wrote: On 08/16/2016 03:53 PM, Ivan Gerasimov wrote: BUGURL: https://bugs.openjdk.java.net/browse/JDK-8163517 WEBREV: http://cr.openjdk.java.net/~igerasim/8163517/00/webrev/ Both ObjectInputStream and ObjectOutpu

Re: [jdk9] RFR: 8163517: Various cleanup in java.io code

2016-08-16 Thread Ivan Gerasimov
Thanks Roger for the review and the pointer! I'll follow the process. With kind regards, Ivan On 16.08.2016 17:30, Roger Riggs wrote: Hi Ivan, Look fine. Remember to use the enhancement process[1] to get approval for this enhancement. Roger [1] http://openjdk.java.net/projects/jdk9/fc-e

Re: [jdk9] RFR: 8163517: Various cleanup in java.io code

2016-08-16 Thread Roger Riggs
Hi Ivan, Look fine. Remember to use the enhancement process[1] to get approval for this enhancement. Roger [1] http://openjdk.java.net/projects/jdk9/fc-extension-process On 8/16/2016 8:53 AM, Ivan Gerasimov wrote: Hello! Here's a cleanup pass through the code in java.io package. Would yo

Re: RFR: 6543126: Level.known can leak memory

2016-08-16 Thread Peter Levart
Hi Daniel, Now that you have various findByXXX methods return Optional, you could make methods that use them more Optional-API-powered. For example, findLevel could be written as a single expression: static Level findLevel(String name) { return KnownLevel .findByName(O

Re: RFR: 6543126: Level.known can leak memory

2016-08-16 Thread Peter Levart
On 08/16/2016 03:14 PM, Daniel Fuchs wrote: Hi Peter, On 16/08/16 13:52, Peter Levart wrote: Ah, I see. Right. Of course, my bad. In that case, there is a possible race that could lead to exception here: 476 // add new Level. 477 Level levelObject = new Level(nam

Re: RFR: 6543126: Level.known can leak memory

2016-08-16 Thread Daniel Fuchs
Hi Peter, On 16/08/16 13:52, Peter Levart wrote: Ah, I see. Right. Of course, my bad. In that case, there is a possible race that could lead to exception here: 476 // add new Level. 477 Level levelObject = new Level(name, x); 478 return KnownLevel.findByV

Re: RFR: 6543126: Level.known can leak memory

2016-08-16 Thread Daniel Fuchs
On 16/08/16 13:59, Peter Levart wrote: Hi Daniel, Another place that is not clear to me is the following (in old code): 585 // Returns a KnownLevel with the given localized name matching 586 // by calling the Level.getLocalizedLevelName() method (i.e. found 587 // fro

Re: [jdk9] RFR: 8163517: Various cleanup in java.io code

2016-08-16 Thread Aleksey Shipilev
On 08/16/2016 03:53 PM, Ivan Gerasimov wrote: > BUGURL: https://bugs.openjdk.java.net/browse/JDK-8163517 > WEBREV: http://cr.openjdk.java.net/~igerasim/8163517/00/webrev/ Both ObjectInputStream and ObjectOutputStream can use auto-unboxing in these blocks? 1271 if (result.booleanValue()) {

Re: RFR: 6543126: Level.known can leak memory

2016-08-16 Thread Peter Levart
Hi Daniel, Another place that is not clear to me is the following (in old code): 585 // Returns a KnownLevel with the given localized name matching 586 // by calling the Level.getLocalizedLevelName() method (i.e. found 587 // from the resourceBundle associated with the

[jdk9] RFR: 8163517: Various cleanup in java.io code

2016-08-16 Thread Ivan Gerasimov
Hello! Here's a cleanup pass through the code in java.io package. Would you please help review? BUGURL: https://bugs.openjdk.java.net/browse/JDK-8163517 WEBREV: http://cr.openjdk.java.net/~igerasim/8163517/00/webrev/ With kind regards, Ivan

Re: RFR: 6543126: Level.known can leak memory

2016-08-16 Thread Peter Levart
On 08/16/2016 02:30 PM, Daniel Fuchs wrote: Hi Peter, On 16/08/16 13:05, Peter Levart wrote: Hi Daniel, Passing Stream returning extractors to Stream::flatMap is one way of doing it. The other would be to make findByXXX methods return Optional and then use Optional::map method on the result

Re: RFR: 6543126: Level.known can leak memory

2016-08-16 Thread Daniel Fuchs
Hi Peter, On 16/08/16 13:05, Peter Levart wrote: Hi Daniel, Passing Stream returning extractors to Stream::flatMap is one way of doing it. The other would be to make findByXXX methods return Optional and then use Optional::map method on the result to extract the needed property, so instead of:

Re: RFR: 6543126: Level.known can leak memory

2016-08-16 Thread Peter Levart
Hi Daniel, Passing Stream returning extractors to Stream::flatMap is one way of doing it. The other would be to make findByXXX methods return Optional and then use Optional::map method on the result to extract the needed property, so instead of: Optional level = findByName(name, KnownLev

Re: RFR: 6543126: Level.known can leak memory

2016-08-16 Thread Daniel Fuchs
Hi Mandy, I added an additional selector parameter to the find methods. This made it possible to return Optional instead of KnownLevel - and it does simply the parse() method. http://cr.openjdk.java.net/~dfuchs/webrev_6543126/webrev.02 best regards, -- daniel On 11/08/16 20:12, Mandy Chung wr

Re: RFR 8162458 Buffer view implementations use incorrect offset for Unsafe access

2016-08-16 Thread Andrew Haley
On 16/08/16 03:05, David Holmes wrote: > hs-comp is the team forest for the compiler team. If you are working > primarily on hotspot compiler issues and want to integrate with latest > work the compiler team is doing, and/or you have shared compiler > changes, then you would push to hs-comp. >