Re: String.join for Iterable, not just CharSequence

2019-04-11 Thread Michael Rasmussen
Hi Stuart Thanks for the references to the discussion regarding .stream() on Iterable; I had been wondering that myself from time to time why they weren't there. It has always bothered my, that converting an Iterable to a Stream is a bit cumbersome, having to go through the spliterator and the St

Re: RFR : 8221696: MappedByteBuffer.force method to specify range

2019-04-11 Thread Alan Bateman
On 10/04/2019 12:15, Andrew Dinn wrote: : An updated webrev is available: JIRA: https://bugs.openjdk.java.net/browse/JDK-8221696 webrev: http://cr.openjdk.java.net/~adinn/8221696/webrev.01 The updated javadoc looks good. A minor nit is that it reads "and includes {@code length} bytes" when

Re: RFR : 8221696: MappedByteBuffer.force method to specify range

2019-04-11 Thread Andrew Dinn
On 11/04/2019 11:34, Alan Bateman wrote: > On 10/04/2019 12:15, Andrew Dinn wrote: >> : >> An updated webrev is available: >> >> JIRA:   https://bugs.openjdk.java.net/browse/JDK-8221696 >> webrev: http://cr.openjdk.java.net/~adinn/8221696/webrev.01 >> >> > The updated javadoc looks good. A minor ni

Re: RFR(s): 8217405 rmic should reject class files with preview features enabled

2019-04-11 Thread Alan Bateman
On 11/04/2019 02:22, Stuart Marks wrote: Hi all, Please review this small fix to rmic to make it reject class files that were compiled with preview features enabled. Bug: https://bugs.openjdk.java.net/browse/JDK-8217405 Webrev: http://cr.openjdk.java.net/~smarks/reviews/8217405/web

RFR: 8222276: (zipfs) Refactoring and cleanups to prepare for JDK-8213031

2019-04-11 Thread Langer, Christoph
Hi, working on JDK-8213031 to add posix file permission support for the zipfs, I thought it makes sense to factor out some of the changes into a separate change. Those changes reorganize and clean up some parts of the code which I think makes sense in any case. Please review: Bug: https://bugs

Re: RFR: 8215017: Improve String::equals warmup characteristics

2019-04-11 Thread Claes Redestad
Hi, please review this improved version, which drops the new sameCoder() method and insteads inlines that test in the one place where its use is performance sensitive. Webrev: http://cr.openjdk.java.net/~redestad/8215017/jdk.01/ Microbenchmark show perfectly matching results, except an addition

Re: RFR: 8215017: Improve String::equals warmup characteristics

2019-04-11 Thread Martin Buchholz
I'm confused. This change seems to remove the one and only call to StringUTF16.equals, making that dead code? Looking more closely at StringUTF16.equals and StringLatin1.equals, both seem to boil down to equivalent """do the byte arrays contain the same bytes?"""? Which suggests we can coalesce the

Re: RFR: 8215017: Improve String::equals warmup characteristics

2019-04-11 Thread John Rose
On Dec 7, 2018, at 4:11 PM, Claes Redestad wrote: > > - Jim's proposal to use Arrays.equals is _interesting_: it improves > peak performance on some inputs but regress it on others. I'll defer > that to a future RFE as it needs a more thorough examination. > > - what we can do is simplify to onl

Re: RFR: 8215017: Improve String::equals warmup characteristics

2019-04-11 Thread Claes Redestad
On 2019-04-11 18:06, Martin Buchholz wrote: I'm confused. This change seems to remove the one and only call to StringUTF16.equals, making that dead code? Looking more closely at StringUTF16.equals and StringLatin1.equals, both seem to boil down to equivalent """do the byte arrays contain the

Re: RFR(s): 8217405 rmic should reject class files with preview features enabled

2019-04-11 Thread Stuart Marks
Thanks Lance. On 4/10/19 7:00 PM, Lance Andersen wrote: Looks OK Stuart :-) On Apr 10, 2019, at 9:22 PM, Stuart Marks > wrote: Hi all, Please review this small fix to rmic to make it reject class files that were compiled with preview features enabled. Bug:

Re: RFR(s): 8217405 rmic should reject class files with preview features enabled

2019-04-11 Thread Stuart Marks
On 4/11/19 5:36 AM, Alan Bateman wrote: I think this looks okay. If you are putting any effort into rmic then I think it should be to work out a plan to remove it :-) Hold my beer.

RFR: JDK-8222151: refactoring: enhancements to java.lang.Class::methodToString and java.lang.Class::getTypeName

2019-04-11 Thread Vicente Romero
Please review the enhancements to java.lang.Class proposed by Sergei Tsypanov see discussion at [1]. The bug can be found at [2] and the fix at [3]. This enhancement is removing uses of StringBuilder in:     ::toGenericString     ::methodToString, and     ::getTypeName Thanks, Vicente [1] htt

Re: RFR: JDK-8222151: refactoring: enhancements to java.lang.Class::methodToString and java.lang.Class::getTypeName

2019-04-11 Thread Joseph D. Darcy
Hi Vicente, For methodToString, factoring out computing the common getName() + '.' + name prefix might be preferable, but otherwise the patch looks fine. Thanks, -Joe On 4/11/2019 10:22 AM, Vicente Romero wrote: Please review the enhancements to java.lang.Class proposed by Sergei Tsypan

RFE: JDK-8217895: jpackage --identifier purpose

2019-04-11 Thread Andy Herrick
Please review the jpackage fix for bug [1] at [2]. This is a fix for the JDK-8200758-branch branch of the open sandbox repository (jpackage). [1] https://bugs.openjdk.java.net/browse/JDK-8217895 [2] http://cr.openjdk.java.net/~herrick/8217895/ /Andy

Re: RFR: JDK-8222151: refactoring: enhancements to java.lang.Class::methodToString and java.lang.Class::getTypeName

2019-04-11 Thread Vicente Romero
Hi Joe, Thanks for the review please, I have modified the webrev [1] [1] http://cr.openjdk.java.net/~vromero/8222151/webrev.01/ On 4/11/19 1:26 PM, Joseph D. Darcy wrote: Hi Vicente, For methodToString, factoring out computing the common     getName() + '.' + name prefix might be preferable

Re: RFR: JDK-8222151: refactoring: enhancements to java.lang.Class::methodToString and java.lang.Class::getTypeName

2019-04-11 Thread Joe Darcy
Hi Vicente, That version is better. If one doesn't mind the ?: operator, something like the following is possible: return getName() + '.' + name + (argTypes == null || argTypes.length == 0) ? "()":   Arrays.stream(argTypes)   .map(c -> c == null ? "null" : c.getName())   .collect(Collectors.jo

Re: RFE: JDK-8217895: jpackage --identifier purpose

2019-04-11 Thread Alexander Matveev
Hi Andy, Looks good. Thanks, Alexander On 4/11/2019 12:05 PM, Andy Herrick wrote: Please review the jpackage fix for bug [1] at [2]. This is a fix for the JDK-8200758-branch branch of the open sandbox repository (jpackage). [1] https://bugs.openjdk.java.net/browse/JDK-8217895 [2] http://c

Re: RFE: JDK-8217895: jpackage --identifier purpose

2019-04-11 Thread semyon . sadetsky
On 4/11/19 12:05 PM, Andy Herrick wrote: Please review the jpackage fix for bug [1] at [2]. This is a fix for the JDK-8200758-branch branch of the open sandbox repository (jpackage). [1] https://bugs.openjdk.java.net/browse/JDK-8217895 [2] http://cr.openjdk.java.net/~herrick/8217895/ Andy

Re: RFR: JDK-8222151: refactoring: enhancements to java.lang.Class::methodToString and java.lang.Class::getTypeName

2019-04-11 Thread Vicente Romero
Hi Joe, Thanks for your suggestion, please see [1] Vicente [1] http://cr.openjdk.java.net/~vromero/8222151/webrev.02/ On 4/11/19 4:48 PM, Joe Darcy wrote: Hi Vicente, That version is better. If one doesn't mind the ?: operator, something like the following is possible: return getName() +

Re: RFR: JDK-8222151: refactoring: enhancements to java.lang.Class::methodToString and java.lang.Class::getTypeName

2019-04-11 Thread Joe Darcy
Hi Vicente, Looks good; thanks, -Joe On 4/11/2019 3:07 PM, Vicente Romero wrote: Hi Joe, Thanks for your suggestion, please see [1] Vicente [1] http://cr.openjdk.java.net/~vromero/8222151/webrev.02/ On 4/11/19 4:48 PM, Joe Darcy wrote: Hi Vicente, That version is better. If one doesn't