Re: RFR: 8248655: Support supplementary characters in String case insensitive operations

2020-07-21 Thread naoto . sato
Hi Brent, On 7/21/20 2:56 PM, Brent Christian wrote: Hi, Naoto I have a few comments: src/java.base/share/classes/java/lang/StringUTF16.java 379 private static int getSupplementaryCodePoint(byte[] ba, int cp, int index, int start, int end) I think it would be worth a small addition to

Re: RFR: 8248655: Support supplementary characters in String case insensitive operations

2020-07-21 Thread Brent Christian
Hi, Naoto I have a few comments: src/java.base/share/classes/java/lang/StringUTF16.java 379 private static int getSupplementaryCodePoint(byte[] ba, int cp, int index, int start, int end) I think it would be worth a small addition to the comment to reflect that non-surrogate chars are re

Re: RFR: 8248655: Support supplementary characters in String case insensitive operations

2020-07-21 Thread naoto . sato
Thank you, Joe. I got it now. Will try out and benchmark. Naoto On 7/21/20 10:05 AM, Joe Wang wrote: On 7/20/2020 8:58 PM, naoto.s...@oracle.com wrote: The short-cut worked well. There's maybe a further optimization we could do to rid us of the performance concern (or the need to run additi

Re: RFR: 8248655: Support supplementary characters in String case insensitive operations

2020-07-21 Thread Joe Wang
On 7/20/2020 8:58 PM, naoto.s...@oracle.com wrote: The short-cut worked well. There's maybe a further optimization we could do to rid us of the performance concern (or the need to run additional performance tests). Consider the cases where strings in comparison don't contain any sup characte