Re: RFR [15] 8242230: Whitespace typos, relaxed javadoc, formatting

2020-04-07 Thread Ivan Gerasimov
Looks good to me, thanks! Kind regards, Ivan On 4/7/20 8:28 AM, Pavel Rappo wrote: Hi Ivan, On 7 Apr 2020, at 09:11, Ivan Gerasimov wrote: Hi Pavel! A couple of comments. 1) java/util/logging/Formatter.java This has one extra open curly brace: "{{@literal }" The leftmost c

Re: RFR [15] 8242230: Whitespace typos, relaxed javadoc, formatting

2020-04-07 Thread Ivan Gerasimov
e affected: java.lang, java.text, java.util, java.util.logging, javax.lang.model.util, jdk.internal.reflect -Pavel -- With kind regards, Ivan Gerasimov

Re: [15] RFR 8241727 : Typos: empty lines in javadoc, inconsistent indents, etc. (core-libs only)

2020-03-28 Thread Ivan Gerasimov
s. -Pavel On 27 Mar 2020, at 10:26, Ivan Gerasimov wrote: Hello! This is a javadoc-only fix. There are a few changes that will actually be visible (for example [1], [2]), but the vast majority of changes are to remove redundant empty lines, correct indentation, or otherwise restore harmony.

[15] RFR 8241727 : Typos: empty lines in javadoc, inconsistent indents, etc. (core-libs only)

2020-03-27 Thread Ivan Gerasimov
' in text: https://docs.oracle.com/en/java/javase/13/docs/api/java.base/java/lang/annotation/Annotation.html#hashCode() -- With kind regards, Ivan Gerasimov

Re: RFR 8237599 : Greedy matching against supplementary chars fails to respect the region

2020-03-25 Thread Ivan Gerasimov
Thank you Roger for review! On 3/25/20 6:56 AM, Roger Riggs wrote: Hi Ivan, Looks fine. Interesting edge case, would never be seen with 8 bit charsets. Thanks, Roger On 3/21/20 3:15 AM, Ivan Gerasimov wrote: Gentle ping. The webrev was rebased to accommodate recent changes

Re: RFR 8237599 : Greedy matching against supplementary chars fails to respect the region

2020-03-21 Thread Ivan Gerasimov
Gentle ping. The webrev was rebased to accommodate recent changes in RegExTest.java. The fix is to handle an edge case situation, which is supposedly not too common. Nevertheless, I think, it is important to handle it correctly. Thanks in advance! Ivan On 1/22/20 8:23 PM, Ivan Gerasimov

Re: RFR [15] 8241014: Miscellaneous typos in documentation comments

2020-03-20 Thread Ivan Gerasimov
: whose referent is equal to this referent, or whose referent equals this referent, The former is easier just delete the ’s’. Other bits look good. Paul. On Mar 13, 2020, at 7:03 PM, Ivan Gerasimov wrote: Hi Pavel! Can this please be combined with my collection of typos? http

Re: RFR 8214245 : (regex) Case insensitive matching doesn't work correctly for some character classes

2020-03-18 Thread Ivan Gerasimov
Thank you Roger! Pushed. With kind regards, Ivan On 3/17/20 5:20 PM, Roger Riggs wrote: Hi Ivan, I see the CSR is approved. I'm fine with the change. Regards, Roger On 2/25/20 3:18 PM, Ivan Gerasimov wrote: Thank you Roger for reviewing CSR and the release note! On 2/11/20 12:49 PM

Re: RFR: 8196334: Optimize UUID#fromString

2020-02-28 Thread Ivan Gerasimov
JavaLangAccess I'm not sure there's anything that'd net us any significant gain. And I don't think it's worth it to open up that particular can of worms right now just for this. /Claes On 2020-02-28 20:51, Ivan Gerasimov wrote: Hi Claes and Andriy! It looks good overall. I wonder if it'll be even faster

Re: RFR: 8196334: Optimize UUID#fromString

2020-02-28 Thread Ivan Gerasimov
implementation if ever needed. I've done some light edits, and added a simple microbenchmark. Bug:    https://bugs.openjdk.java.net/browse/JDK-8196334 Webrev: http://cr.openjdk.java.net/~redestad/8196334/open.00/ Testing: tier1-3 Thanks! /Claes -- With kind regards, Ivan Gerasimov

Re: RFR: 8240094: Optimize empty substring

2020-02-26 Thread Ivan Gerasimov
e. Overall I like how the patch now cleans things up a bit on top of (likely) optimizing a few edge cases, and can volunteer to sponsor it if no one else has spoken up already. Doing some quick performance testing and possibly adding a microbenchmark before push would be good. Thanks! /Claes -- With kind regards, Ivan Gerasimov

Re: RFR 8214245 : (regex) Case insensitive matching doesn't work correctly for some character classes

2020-02-25 Thread Ivan Gerasimov
Regards, Roger On 2/7/20 3:05 PM, Ivan Gerasimov wrote: Gentle ping. I had to rebase the fix, as the code has diverged since the RFR was sent out 10 months ago. Also, the test was slightly modified to cover more cases. BUGURL: https://bugs.openjdk.java.net/browse/JDK-8214245 WEBREV: http

Re: [TRIVIAL] Fast-path for String.subsring(n,n)

2020-02-25 Thread Ivan Gerasimov
beginIndex = endIndex (asuming both are valid): -- With kind regards, Ivan Gerasimov

Re: RFR 8214245 : (regex) Case insensitive matching doesn't work correctly for some character classes

2020-02-24 Thread Ivan Gerasimov
, the failures should print which case is failing. (Line 4961, 4990). Regards, Roger On 2/7/20 3:05 PM, Ivan Gerasimov wrote: Gentle ping. I had to rebase the fix, as the code has diverged since the RFR was sent out 10 months ago. Also, the test was slightly modified to cover more cases

Re: RFR 8235812 : (regex) Unicode linebreak with quantifier does not match valid input

2020-02-10 Thread Ivan Gerasimov
interleaved with the test progress output. No need for another review. Thanks, Roger On 2/5/20 8:22 PM, Ivan Gerasimov wrote: Hello! j.u.regex.Pattern supports a special char class \R, which is specified to be equal to \u000D\u000A|[\u000A\u000B\u000C\u000D\u0085\u2028\u2029]. In particular

Re: RFR 8214245 : (regex) Case insensitive matching doesn't work correctly for some character classes

2020-02-07 Thread Ivan Gerasimov
in advance to the volunteer to review the fix! With kind regards, Ivan On 4/21/19 7:50 PM, Ivan Gerasimov wrote: Hello! It turns out, that the case-insensitive j.u.regex.Pattern still pays attention to the characters case when certain char classes are used. For example \p{IsLowerCase}, \p

RFR 8235812 : (regex) Unicode linebreak with quantifier does not match valid input

2020-02-05 Thread Ivan Gerasimov
12/00/webrev/ Control build and testing (tiers1-4) are all green. -- With kind regards, Ivan Gerasimov

RFR 8237599 : Greedy matching against supplementary chars fails to respect the region

2020-01-22 Thread Ivan Gerasimov
/ Thanks in advance! -- With kind regards, Ivan Gerasimov

Re: RFR 8236034 : Use optimized Ques node for curly {0,1} quantifier

2020-01-22 Thread Ivan Gerasimov
Thank you Roger for review! Pushed. -- With kind regards, Ivan Gerasimov

Re: RFR 8234423 : Modifying ArrayList.subList().subList() resets modCount of subList

2020-01-09 Thread Ivan Gerasimov
Thank you Roger for your review! Happy New Year to you too! :) With kind regards, Ivan On 1/9/20 10:36 AM, Roger Riggs wrote: Hi Ivan, Happy New Year! This change looks fine. Roger On 11/23/19 2:30 AM, Ivan Gerasimov wrote: Re-sending the request with the correct Subject line - the bug

Re: Use single character replace variant in Resources.toPackageName(String)

2020-01-09 Thread Ivan Gerasimov
FYI.  I changed the year to 2020 and pushed the fix. Thank you Christoph and Alan! On 1/6/20 11:49 PM, Alan Bateman wrote: On 07/01/2020 07:09, Ivan Gerasimov wrote: So, I filed a Jira bug: BUGURL: https://bugs.openjdk.java.net/browse/JDK-8236705 WEBREV: http://cr.openjdk.java.net/~igerasim

Re: Use single character replace variant in Resources.toPackageName(String)

2020-01-06 Thread Ivan Gerasimov
So, I filed a Jira bug: BUGURL: https://bugs.openjdk.java.net/browse/JDK-8236705 WEBREV: http://cr.openjdk.java.net/~igerasim/8236705/00/webrev/ If we agree on the content of the fix, I can push it after a sanity build. With kind regards, Ivan On 1/6/20 10:41 PM, Ivan Gerasimov wrote: Hi

Re: Use single character replace variant in Resources.toPackageName(String)

2020-01-06 Thread Ivan Gerasimov
I'm sorry for the noise. Cheers, Christoph Dreis -- With kind regards, Ivan Gerasimov

Re: RFR 8225466 : Optimize matching BMP Slice nodes

2019-12-18 Thread Ivan Gerasimov
lse;     }     if (len >= matcher.to) {     matcher.hitEnd =true;     return false;     }     return next.match(matcher, i+len, seq); } Regards, Roger On 10/28/19 9:03 PM, Ivan Gerasimov wrote: Hello! When building a Pattern object, the regex parser recognizes "slices" - continuous c

Re: RFR 8234423 : Modifying ArrayList.subList().subList() resets modCount of subList

2019-12-16 Thread Ivan Gerasimov
Gentle ping. Will someone please volunteer to review this fix of a regression? Thanks in advance! On 11/20/19 10:11 PM, Ivan Gerasimov wrote: Hello! When a sublist of a sublist of an ArrayList is created, its modCount is initialized from the ArrayList root, and not from its immediate

RFR 8236034 : Use optimized Ques node for curly {0,1} quantifier

2019-12-16 Thread Ivan Gerasimov
forms of quantifiers equally well. Would you please help review this enhancement? BUGURL: https://bugs.openjdk.java.net/browse/JDK-8236034 WEBREV: http://cr.openjdk.java.net/~igerasim/8236034/00/webrev/ Thanks in advance! -- With kind regards, Ivan Gerasimov

Re: RFR 8235930 : java.util.regex.PrintPattern does not print a link to the next node

2019-12-15 Thread Ivan Gerasimov
Thank you Martin! Pushed. On 12/14/19 10:45 PM, Martin Buchholz wrote: Looks Good To Me. -- With kind regards, Ivan Gerasimov

Re: RFR 8235930 : java.util.regex.PrintPattern does not print a link to the next node

2019-12-14 Thread Ivan Gerasimov
print() methods, and both of them indent the text. I am not planning to invest much into this utility, just wanted to fix that annoying glitch. With kind regards, Ivan On Fri, Dec 13, 2019 at 12:11 PM Ivan Gerasimov mailto:ivan.gerasi...@oracle.com>> wrote:

RFR 8235930 : java.util.regex.PrintPattern does not print a link to the next node

2019-12-13 Thread Ivan Gerasimov
/8235930/00/webrev/ -- With kind regards, Ivan Gerasimov

Re: RFR 8234147 : Avoid looking up standard charsets in core libraries

2019-12-01 Thread Ivan Gerasimov
wrote: Hi Ivan, you may compare your proposal with: https://bugs.java.com/bugdatabase/view_bug.do?bug_id=6790402 https://bugs.java.com/bugdatabase/view_bug.do?bug_id=6850361 https://bugs.java.com/bugdatabase/view_bug.do?bug_id=6796087 -Ulf Am 27.11.19 um 05:39 schrieb Ivan Gerasimov: Hello

Re: RFR 8234147 : Avoid looking up standard charsets in core libraries

2019-12-01 Thread Ivan Gerasimov
Thank you Alan for the further review! On 11/27/19 12:53 PM, Alan Bateman wrote: On 27/11/2019 11:52, Ivan Gerasimov wrote: : It's not clear how to distinguish the classes inside the java.base module that do not have to depend on sun.nio.cs.  If you feel strong about NTLM and XML, I can

Re: RFR 8234147 : Avoid looking up standard charsets in core libraries

2019-11-27 Thread Ivan Gerasimov
Thank you Alan for reviewing! Please see the comments inline. On 11/26/19 11:54 PM, Alan Bateman wrote: On 27/11/2019 04:39, Ivan Gerasimov wrote: Hello! It is a cleanup fix with mostly two kinds of changes: - when a standard charset is specified by its name, use a preinitialized Charset

RFR 8234147 : Avoid looking up standard charsets in core libraries

2019-11-26 Thread Ivan Gerasimov
. Would you please help review the fix? -- With kind regards, Ivan Gerasimov

Re: RFR 8234423 : Modifying ArrayList.subList().subList() resets modCount of subList

2019-11-22 Thread Ivan Gerasimov
Re-sending the request with the correct Subject line - the bug is not (only) about the iterator. On 11/20/19 10:11 PM, Ivan Gerasimov wrote: Hello! When a sublist of a sublist of an ArrayList is created, its modCount is initialized from the ArrayList root, and not from its immediate parent

RFR 8234423 : More accurate handling of modification counter in ArrayList.SubList.Iterator

2019-11-20 Thread Ivan Gerasimov
/8234423/00/webrev/ -- With kind regards, Ivan Gerasimov

Re: RFR (XXS) 8233658 : Escape + in the expression describing Runtime.Version string

2019-11-06 Thread Ivan Gerasimov
Thank you Naoto! Pushed. On 11/6/19 8:24 AM, naoto.s...@oracle.com wrote: Hi Ivan, Looks good to me. Naoto On 11/5/19 9:39 PM, Ivan Gerasimov wrote: Hello! Here's yet another javadoc-only fix. Format of the Runtime.Version string is described as a list of regular expressions [1

RFR (XXS) 8233658 : Escape + in the expression describing Runtime.Version string

2019-11-05 Thread Ivan Gerasimov
://cr.openjdk.java.net/~igerasim/8233658/00/webrev/ -- With kind regards, Ivan Gerasimov

Re: RFR (S) 8233650 : Javadoc for Math.floorMod(int, int) gives wrong example

2019-11-05 Thread Ivan Gerasimov
Thank you Brian! Pushed. On 11/5/19 4:05 PM, Brian Burkhalter wrote: Hi Ivan, I think this looks good. Brian On Nov 5, 2019, at 3:35 PM, Ivan Gerasimov wrote: The javadoc for the method Math.floorMod(int, int) [1] contains an inaccuracy. There are two sets of examples given: One

RFR (S) 8233650 : Javadoc for Math.floorMod(int, int) gives wrong example

2019-11-05 Thread Ivan Gerasimov
#floorMod(int,int) -- With kind regards, Ivan Gerasimov

RFR 8225466 : Optimize matching BMP Slice nodes

2019-10-28 Thread Ivan Gerasimov
Find  avgt   16  190.612 ? 0.336  ns/op FIXED Benchmark    Mode  Cnt    Score   Error  Units PatternBench.sliceIFind  avgt   16  182.954 ? 0.493  ns/op --- -- With kind regards, Ivan Gerasimov

Re: RFR (S) 8230407 : SocketPermission and FilePermission action list allows leading comma

2019-10-03 Thread Ivan Gerasimov
Hi Chris! On 10/3/19 8:05 AM, Chris Hegarty wrote: Ivan, On 3 Oct 2019, at 04:41, Ivan Gerasimov wrote: ... So, I filed CSR: https://bugs.openjdk.java.net/browse/JDK-8231805 to cover the addition of @throws paragraph in the javadoc of SocketPermission. I would really appreciate

Re: RFR (S) 8230407 : SocketPermission and FilePermission action list allows leading comma

2019-10-03 Thread Ivan Gerasimov
/2/19 11:40 PM, Peter Levart wrote: Hi Ivan, On 10/1/19 10:26 PM, Ivan Gerasimov wrote: Hello! The constructors of SocketPermission and FilePermission expect a String argument with comma-separated list of actions. If the list is malformed, then the constructors throw IllegalArgumentException

Re: RFR (S) 8230407 : SocketPermission and FilePermission action list allows leading comma

2019-10-02 Thread Ivan Gerasimov
ike if we used to allow commas in arbitrary places and stopped doing that.  Instead, it just turned out that the code fails to catch one specific pattern of malformed action list. With kind regards, Ivan Cheers, -Joe On 10/2/2019 4:26 PM, Ivan Gerasimov wrote: Hi Chris! Thank you very much for

Re: RFR (S) 8230407 : SocketPermission and FilePermission action list allows leading comma

2019-10-02 Thread Ivan Gerasimov
/~igerasim/8230407/01/webrev/ With kind regards, Ivan On 10/2/19 6:44 AM, Chris Hegarty wrote: Ivan, On 01/10/2019 21:26, Ivan Gerasimov wrote: Hello! The constructors of SocketPermission and FilePermission expect a String argument with comma-separated list of actions. If the list

Re: 8229022: BufferedReader performance can be improved by using StringBuilder

2019-10-01 Thread Ivan Gerasimov
Hi Brian! This looks good to me! With kind regards, Ivan On 10/1/19 5:13 PM, Brian Burkhalter wrote: While the performance improvement that I measured for this proposed change [1] using JMH was only in the 2% to 8% range as opposed to the 13% claimed in the issue description, given the

RFR (S) 8230407 : SocketPermission and FilePermission action list allows leading comma

2019-10-01 Thread Ivan Gerasimov
with a leading comma. Would you please help review a simple fix, which will make the behavior more consistent? BUGURL: https://bugs.openjdk.java.net/browse/JDK-8230407 WEBREV: http://cr.openjdk.java.net/~igerasim/8230407/00/webrev/ -- With kind regards, Ivan Gerasimov

Re: RFR (XS) 8230415 : Avoid redundant permission checking in FilePermissionCollection and SocketPermissionCollection

2019-09-30 Thread Ivan Gerasimov
Thank you Sean for reviewing! With kind regards, Ivan On 9/27/19 7:20 AM, Sean Mullan wrote: Hi Ivan, The fix looks good. Good catch. --Sean On 8/30/19 7:32 PM, Ivan Gerasimov wrote: Hello! In the two implementations of PermissionCollection.implies(Permission), all the permissions

Re: RFR 8230829 : Matcher matches a surrogate pair that crosses border of the region

2019-09-12 Thread Ivan Gerasimov
Thank you Naoto for reviewing! With kind regards, Ivan On 9/12/19 8:02 AM, naoto.s...@oracle.com wrote: Looks good to me, Ivan. Naoto On 9/10/19 9:13 PM, Ivan Gerasimov wrote: Hello! When the regex.Matcher matches a supplementary codepoint, it may inadvertently cross the border

RFR 8230829 : Matcher matches a surrogate pair that crosses border of the region

2019-09-10 Thread Ivan Gerasimov
/~igerasim/8230829/00/webrev/ Thanks in advance! -- With kind regards, Ivan Gerasimov

Re: RFR 8230365 : Pattern for a control-char matches non-control characters

2019-09-09 Thread Ivan Gerasimov
Thank you Stuart for the analysis! Please see my comments inline. On 9/9/19 4:39 PM, Stuart Marks wrote: On 9/5/19 1:43 PM, Ivan Gerasimov wrote: Personally, I don't have a strong preference here. The compatibility property are meant to be temporary anyways. Maybe if we have a single

Re: RFR 8230365 : Pattern for a control-char matches non-control characters

2019-09-05 Thread Ivan Gerasimov
  Silently changing behavior is bad for users.  ... so let's abandon ALLOW_LOWERCASE_CONTROL_CHAR_IDS. An alternative: int ch = read() ^ 0x40; if (!RESTRICTED_CONTROL_CHAR_IDS || ch < 0x20 || ch == 0x7f) return ch; On Wed, Sep 4, 2019 at 6:49 PM Ivan Gerasimov mailto:ivan.gerasi...@oracl

Re: RFR 8230365 : Pattern for a control-char matches non-control characters

2019-09-05 Thread Ivan Gerasimov
Thank you Martin again! Here's the updated webrev without the lower-case control char ids: http://cr.openjdk.java.net/~igerasim/8230365/03/webrev/ I've also filed a CSR to record the changes in bahavior: https://bugs.openjdk.java.net/browse/JDK-8230675 Could you please help review it? On

Re: RFR 8230365 : Pattern for a control-char matches non-control characters

2019-09-05 Thread Ivan Gerasimov
-libs-dev im Auftrag von Ivan Gerasimov Gesendet: Donnerstag, September 5, 2019 4:00 AM An: Martin Buchholz; Stuart Marks Cc: core-libs-dev Betreff: Re: RFR 8230365 : Pattern for a control-char matches non-control characters Thank you Martin! On 8/30/19 6:19 PM, Martin Buchholz wrote: There's

Re: Reply: what to do next to fix JDK-8230557. thanks

2019-09-05 Thread Ivan Gerasimov
Hi Peter! On 9/5/19 7:24 AM, Peter Levart wrote: Hi Ivan, On 9/5/19 11:22 AM, Ivan Gerasimov wrote: Hello! BitSet is known to be flawed in many ways:?0?2 its size(), length(), cardinality() and nextClearBit?6?7() can return meaningless negative values. I was thinking about disallowing

Re: Reply: what to do next to fix JDK-8230557. thanks

2019-09-05 Thread Ivan Gerasimov
[1]https://bugs.openjdk.java.net/browse/JDK-8230557 [2]http://openjdk.java.net/contribute/ [3]https://www.oracle.com/technetwork/community/oca-486395.html --nbsp;nbsp;-- ??:nbsp;"Bug Report Notification&

Re: RFR 8230365 : Pattern for a control-char matches non-control characters

2019-09-04 Thread Ivan Gerasimov
Thank you Martin! On 8/30/19 6:19 PM, Martin Buchholz wrote: There's a strong expectation that ctrl-A and ctrl-a both map to \u0001, so I support Ivan's initiative. I'm surprised java regex gets this wrong. Might need a transitional system property. Right.  I think it would be best to

RFR (XS) 8230415 : Avoid redundant permission checking in FilePermissionCollection and SocketPermissionCollection

2019-08-30 Thread Ivan Gerasimov
l be executed. The fix does not change the behavior, but helps avoid unnecessary calls to impliesIgnoreMask(). Would you please help review a trivial fix? BUGURL: https://bugs.openjdk.java.net/browse/JDK-8230415 WEBREV: http://cr.openjdk.java.net/~igerasim/8230415/00/webrev/ Thanks in advance! -- With kind regards, Ivan Gerasimov

Re: RFR 8230365 : Pattern for a control-char matches non-control characters

2019-08-29 Thread Ivan Gerasimov
exp, which will again help developers. Please find the updated webrev here: http://cr.openjdk.java.net/~igerasim/8230365/01/webrev/ With kind regards, Ivan s'marks On 8/29/19 4:39 PM, Ivan Gerasimov wrote: Hello! In a regular expression pattern a sequence of the form \\cx is allowed to specify

RFR 8230365 : Pattern for a control-char matches non-control characters

2019-08-29 Thread Ivan Gerasimov
/ -- With kind regards, Ivan Gerasimov

Re: RFR (S) 8230338 : Accurate error message about bad Unicode block name

2019-08-29 Thread Ivan Gerasimov
Thank you Roger! On 8/29/19 6:39 AM, Roger Riggs wrote: Looks fine Ivan, Thanks, Roger -- With kind regards, Ivan Gerasimov

RFR (S) 8230338 : Accurate error message about bad Unicode block name

2019-08-29 Thread Ivan Gerasimov
? BUGURL: https://bugs.openjdk.java.net/browse/JDK-8230338 WEBREV: http://cr.openjdk.java.net/~igerasim/8230338/00/webrev/ Thanks in advance! -- With kind regards, Ivan Gerasimov

Re: RFR (S) 8226831 : Use Objects.equals() when appropriate

2019-08-27 Thread Ivan Gerasimov
Thank you Roger and Brian! The fix has been pushed. With kind regards, Ivan On 8/27/19 1:12 PM, Brian Burkhalter wrote: Hi Ivan, +1 Brian On Aug 27, 2019, at 12:41 PM, Roger Riggs wrote: Hi Ivan, These look fine. Regards, Roger On 8/27/19 2:21 PM, Ivan Gerasimov wrote: Hello

RFR (S) 8226831 : Use Objects.equals() when appropriate

2019-08-27 Thread Ivan Gerasimov
with a few places cleaned up (I had more, but decided to limit this patch due to the concern mentioned above). BUGURL: https://bugs.openjdk.java.net/browse/JDK-8226831 WEBREV: http://cr.openjdk.java.net/~igerasim/8226831/00/webrev/ Thanks in advance! -- With kind regards, Ivan Gerasimov

Re: 8229845: Decrease memory consumption of BigInteger.toString()

2019-08-23 Thread Ivan Gerasimov
Thank you Brian! This looks good to me. With kind regards, Ivan On 8/23/19 1:33 PM, Brian Burkhalter wrote: Hi Ivan, On Aug 23, 2019, at 12:41 PM, Ivan Gerasimov mailto:ivan.gerasi...@oracle.com>> wrote: One minor comment.  Here: 3990 if (digits > 0) { 3991 padWithZeros(bu

Re: 8229845: Decrease memory consumption of BigInteger.toString()

2019-08-23 Thread Ivan Gerasimov
On Aug 22, 2019, at 1:24 PM, Ivan Gerasimov mailto:ivan.gerasi...@oracle.com>> wrote: I have a few further suggestions how to simplify the code. […] Those are all good suggestions: thanks! Here's the patch, which illustrates all the suggestions above: http://cr.openjdk.java.net/~igerasi

Re: RFR: 8229485: Add decrementExact(), incrementExact(), and negateExact() to java.lang.StrictMath

2019-08-23 Thread Ivan Gerasimov
in that paragraph are those that *do not* have a corresponding -Exact method. The fix looks good then, thanks. With kind regards, Ivan Best, Julia On 22/08/2019 17:25, Ivan Gerasimov wrote: Is there a reason to change the text at lines 72-75? Since you've just added the increment/decrement/negate

Re: 8229845: Decrease memory consumption of BigInteger.toString()

2019-08-22 Thread Ivan Gerasimov
n Aug 21, 2019, at 7:38 PM, Ivan Gerasimov mailto:ivan.gerasi...@oracle.com>> wrote: A couple of comments 1) 3974 if (signum == 0) { 3975 buf.append('0'); 3976 return; 3977 } Shouldn't it be padded with zeroes, if digits > 0? If I'm not mistaken, it could happen if result[1] at the end

Re: RFR: 8229485: Add decrementExact(), incrementExact(), and negateExact() to java.lang.StrictMath

2019-08-22 Thread Ivan Gerasimov
/decrement/negate methods, the old text seems to be more complete. With kind regards, Ivan Regards, Julia On 21/08/2019 20:33, Ivan Gerasimov wrote: Hi Julia! This looks good to me. For all the other methods from StrictMath that have a corresponding method in Math there is a link

Re: 8229845: Decrease memory consumption of BigInteger.toString()

2019-08-21 Thread Ivan Gerasimov
9, at 4:31 PM, Brian Burkhalter wrote: On Aug 20, 2019, at 2:45 PM, Ivan Gerasimov mailto:ivan.gerasi...@oracle.com>> wrote: Would it make sense to add an argument `digits` to smallToString (like the same named argument of toString, the minimum number of digits to pad to), so it could

Re: RFR: 8229485: Add decrementExact(), incrementExact(), and negateExact() to java.lang.StrictMath

2019-08-21 Thread Ivan Gerasimov
hould have been added to java.lang.StrictMath for consistency. > > Bug: https://bugs.openjdk.java.net/browse/JDK-8229485 > > Webrev: http://cr.openjdk.java.net/~dfuchs/jboes/8229485/webrev.01/ > > CSR: https://bugs.openjdk.java.net/browse/JDK-8229702 > > Thanks, > > Ju

Re: RFR 8229958: Provider.getService() scalability issue for legacy algorithms and message digests

2019-08-21 Thread Ivan Gerasimov
a JMH test to confirm its performance improvement. We have also had it running in a load test environment of an application for a couple of days, and the improvement was confirmed as well. Best regards, Letu -- With kind regards, Ivan Gerasimov

Re: 8229845: Decrease memory consumption of BigInteger.toString()

2019-08-20 Thread Ivan Gerasimov
) This might be "static final", while we are at it: 4109 private static String[] zeros = new String[64]; Above made final at L4111 in [2]. On Aug 20, 2019, at 10:28 AM, Ivan Gerasimov mailto:ivan.gerasi...@oracle.com>> wrote: While we're here. On 8/20/19 1:05 AM, Aleksey Shi

RFR 8211360 : Change #if DEF to #if defined(DEF)

2019-08-20 Thread Ivan Gerasimov
://bugs.openjdk.java.net/browse/JDK-8211360 WEBREV: http://cr.openjdk.java.net/~igerasim/8211360/00/webrev/ Mach5 control build/testing went fine on all platforms. Would you please help review? -- With kind regards, Ivan Gerasimov

Re: 8229845: Decrease memory consumption of BigInteger.toString()

2019-08-20 Thread Ivan Gerasimov
); and then replace all sb.append(zeros[x]) with sb.append(zeros, 0, x) and sb.insert(pos, zeros[x]) with sb.insert(pos, zeros, 0, x). The difference would be in one extra bounds check, and as both append() and insert() are relatively expensive, this check would hardly be noticeable. -- Wit

Re: RFR: 8229485: Add decrementExact(), incrementExact(), and negateExact() to java.lang.StrictMath

2019-08-14 Thread Ivan Gerasimov
A tiny addition: On 8/14/19 10:56 AM, Ivan Gerasimov wrote: Hi Julia! In ExactArithTests.java 1) 169 long neg2 = -((long)x) ; please remove the superfluous space at the end. 2) 176 long neg2 = (long) x - 1L; should be `long neg2 = -((long)x);` In StrictMath.java 3

Re: RFR: 8229485: Add decrementExact(), incrementExact(), and negateExact() to java.lang.StrictMath

2019-08-14 Thread Ivan Gerasimov
-8229702 Thanks, Julia [1] https://bugs.openjdk.java.net/browse/JDK-8022109 -- With kind regards, Ivan Gerasimov

Re: RFR (XS) 8221307 : String.substring() OOB exception on start index reports improper information

2019-08-13 Thread Ivan Gerasimov
On 2019-08-08 02:17, Ivan Gerasimov wrote: Hello! The exception thrown by substring(int) may look confusing. For example it produces "String index out of range: -1" when the index is length+1. It is proposed to make the error message more clear, similar to what we have for substrin

Re: RFR (XS) 8221307 : String.substring() OOB exception on start index reports improper information

2019-08-08 Thread Ivan Gerasimov
, done. Is there an appropriate test?  There should be. The substring() method is used across many regression tests, so we do have sanity checking. I didn't think it's worth it to check for specific error message. With kind regards, Ivan Thanks, Roger On 8/7/19 8:17 PM, Ivan Gerasimov wrote:

Re: RFR (XS) 8221307 : String.substring() OOB exception on start index reports improper information

2019-08-08 Thread Ivan Gerasimov
URL: https://bugs.openjdk.java.net/browse/JDK-8221307 WEBREV: http://cr.openjdk.java.net/~igerasim/8221307/00/webrev/ Would you please help review? -- With kind regards, Ivan Gerasimov

RFR (XS) 8221307 : String.substring() OOB exception on start index reports improper information

2019-08-07 Thread Ivan Gerasimov
k.java.net/browse/JDK-8221307 WEBREV: http://cr.openjdk.java.net/~igerasim/8221307/00/webrev/ Would you please help review? -- With kind regards, Ivan Gerasimov

Re: RFR (XS) 8228352 : CANON_EQ breaks when pattern contains supplementary codepoint

2019-08-01 Thread Ivan Gerasimov
Thank you Naoto for the review! With kind regards, Ivan On 8/1/19 10:02 AM, naoto.s...@oracle.com wrote: Hi Ivan, The change looks good to me. Naoto On 7/31/19 9:21 PM, Ivan Gerasimov wrote: Hello! Pattern.compile fails with IOOB when normalizing a pattern that contains a surrogate

RFR (XS) 8228352 : CANON_EQ breaks when pattern contains supplementary codepoint

2019-07-31 Thread Ivan Gerasimov
, Ivan Gerasimov

Re: 8193072: File.delete() should remove its path from DeleteOnExitHook.files

2019-07-10 Thread Ivan Gerasimov
d have permission to cancel that deletion as well. That’s a good idea. -- With kind regards, Ivan Gerasimov

Re: 8193072: File.delete() should remove its path from DeleteOnExitHook.files

2019-07-08 Thread Ivan Gerasimov
a +++ b/src/java.base/share/classes/java/io/File.java @@ -1050,6 +1050,7 @@ if (isInvalid()) { return false; } +DeleteOnExitHook.remove(path); return fs.delete(this); } -- With kind regards, Ivan Gerasimov

Re: RFR (XS) 8224849 : Flag (?U:...) is allowed for non-capturing groups

2019-06-28 Thread Ivan Gerasimov
Thank you Stuart for review and the edits! On 6/28/19 4:30 PM, Stuart Marks wrote: On 6/27/19 2:43 PM, Ivan Gerasimov wrote: Yes, good point about the spec change. Here's the CSR filed: https://bugs.openjdk.java.net/browse/JDK-8226914 Can you please review it at your convenience? Thanks

Re: RFR (XS) 8224849 : Flag (?U:...) is allowed for non-capturing groups

2019-06-27 Thread Ivan Gerasimov
-- With kind regards, Ivan Gerasimov

Re: RFR (XS) 8224849 : Flag (?U:...) is allowed for non-capturing groups

2019-06-25 Thread Ivan Gerasimov
Thank you Brent for review! On 6/25/19 10:40 AM, Brent Christian wrote: That looks fine, Ivan. -Brent On 6/24/19 10:46 PM, Ivan Gerasimov wrote: Hello! Would someone volunteer to review this extra-small doc-only fix? Thanks in advance! With kind regards, Ivan On 5/28/19 9:33 AM, Ivan

Re: RFR (XS) 8224716 : Javadoc of Int/Long/DoubleSummaryStatistics should mention possible overflow of count

2019-06-25 Thread Ivan Gerasimov
about this myself. If the changes are within the @implNote(s), then perhaps not? -Brent On 6/25/19 11:15 AM, Brian Burkhalter wrote: > Is a CSR in order? Thanks, Brian On Jun 25, 2019, at 5:49 AM, Ivan Gerasimov wrote: Hello! Would someone volunteer to review this extra-small doc-o

Re: RFR (XS) 8224716 : Javadoc of Int/Long/DoubleSummaryStatistics should mention possible overflow of count

2019-06-25 Thread Ivan Gerasimov
Hello! Would someone volunteer to review this extra-small doc-only fix? Thanks in advance! With kind regards, Ivan On 5/29/19 2:39 PM, Ivan Gerasimov wrote: Hello! In the implNote section of the javadoc for xxxSummaryStatistics classes it is mentioned that the sum is not checked

Re: RFR (XS) 8224849 : Flag (?U:...) is allowed for non-capturing groups

2019-06-24 Thread Ivan Gerasimov
Hello! Would someone volunteer to review this extra-small doc-only fix? Thanks in advance! With kind regards, Ivan On 5/28/19 9:33 AM, Ivan Gerasimov wrote: Hello! When the fix for JDK-7039066 (which added support for the flag UNICODE_CHARACTER_CLASS and corresponding embedded expression

Re: RFR (s) 8225397 : Integer value miscalculation in toString() method of BitSet

2019-06-06 Thread Ivan Gerasimov
On 6/6/19 8:39 AM, Andrew Haley wrote: On 6/6/19 12:35 PM, Ivan Gerasimov wrote: Could you please check it if it looks better now? http://cr.openjdk.java.net/~igerasim/8225397/00/webrev/ OK, it's just a hint, fair enough. Patch is OK. Thank you! For an extra gold star (:-) you could

Re: RFR (s) 8225397 : Integer value miscalculation in toString() method of BitSet

2019-06-06 Thread Ivan Gerasimov
AM, Ivan Gerasimov wrote: Hello! It is yet another instance of integer overflow under certain extreme circumstances. This time it is when calculating the initial capacity of a StringBuilder in BitSet.toString. If there are too many elements in the set, we can't do much anyway. The best effort

RFR (s) 8225397 : Integer value miscalculation in toString() method of BitSet

2019-06-06 Thread Ivan Gerasimov
NegativeArraySizeException and let the method throw OOM. Would you please help review the fix? BUGURL: https://bugs.openjdk.java.net/browse/JDK-8225397 WEBREV: http://cr.openjdk.java.net/~igerasim/8225397/00/webrev/ -- With kind regards, Ivan Gerasimov

Re: RFR: 8225179: (regex) Minor Pattern cleanup

2019-06-04 Thread Ivan Gerasimov
- various cleanups of unused variables, methods and redundant inititialization Webrev: http://cr.openjdk.java.net/~redestad/8225179/open.00/ Bug:https://bugs.openjdk.java.net/browse/JDK-8225179 Testing: tier1-3 Thanks! /Claes -- With kind regards, Ivan Gerasimov

Re: RFR 8225198 : Optimize regex tree for greedy quantifiers of type {N, }

2019-06-04 Thread Ivan Gerasimov
uantifiers. If the maximum is still MAX_REPS, I'd prefer to continue to say that (rather than, "unlimited.") Thanks. -Brent On 6/3/19 12:54 PM, Ivan Gerasimov wrote: Hello! When building a match-tree, the regex engine optimizes '*' and '+' greedy quantifiers by using special node of typ

RFR 8225198 : Optimize regex tree for greedy quantifiers of type {N, }

2019-06-03 Thread Ivan Gerasimov
regards, Ivan Gerasimov

RFR 8224716 : Javadoc of Int/Long/DoubleSummaryStatistics should mention possible overflow of count

2019-05-29 Thread Ivan Gerasimov
? BUGURL: https://bugs.openjdk.java.net/browse/JDK-8224716 WEBREV: http://cr.openjdk.java.net/~igerasim/8224716/00/webrev/ -- With kind regards, Ivan Gerasimov

Re: RFR: 8224986: (str) optimize StringBuilder.append(CharSequence, int, int) for String arguments

2019-05-29 Thread Ivan Gerasimov
1000 avgt 10 5192.000 ± 0.001 B/op -- With kind regards, Ivan Gerasimov

Re: RFR 8224789 : Parsing repetition count in regex does not detect numeric overflow

2019-05-28 Thread Ivan Gerasimov
), ch - '0'); though that makes for some long lines. Just a thought. Thanks, -Brent On 5/24/19 11:28 PM, Ivan Gerasimov wrote: Hello! When Pattern.compile() parses the repetition count in the expressions like '.{100}', '.{1,2}' or '.{3,}' it fails to detect numeric

Re: RFR 8224789 : Parsing repetition count in regex does not detect numeric overflow

2019-05-28 Thread Ivan Gerasimov
int, long, unsigned long. With kind regards, Ivan Otherwise, looks fine. Thanks, Roger On 05/25/2019 02:28 AM, Ivan Gerasimov wrote: Hello! When Pattern.compile() parses the repetition count in the expressions like '.{100}', '.{1,2}' or '.{3,}' it fails to detect numeric overflow if the res

  1   2   3   4   5   6   7   8   9   >