Re: RFR: 8281146: Replace StringCoding.hasNegatives with countPositives [v13]

2022-03-09 Thread Claes Redestad
> I'm requesting comments and, hopefully, some help with this patch to replace > `StringCoding.hasNegatives` with `countPositives`. The new method does a very > similar pass, but alters the intrinsic to return the number of leading bytes > in the `byte[]` range which only has positive bytes.

RFR: 8280400: JDK 19 L10n resource files update - msgdrop 10

2022-03-09 Thread Alisen Chung
msg drop for jdk19, Mar 9, 2022 - Commit messages: - open jdk19 l10n msg drop Changes: https://git.openjdk.java.net/jdk/pull/7765/files Webrev: https://webrevs.openjdk.java.net/?repo=jdk=7765=00 Issue: https://bugs.openjdk.java.net/browse/JDK-8280400 Stats: 13775 lines in 142

Re: RFR: 8280400: JDK 19 L10n resource files update - msgdrop 10

2022-03-09 Thread Naoto Sato
On Wed, 9 Mar 2022 21:09:30 GMT, Alisen Chung wrote: > msg drop for jdk19, Mar 9, 2022 `src/java.base/share/classes/sun/util/resources/CurrencyNames_de.properties` `src/java.base/share/classes/sun/util/resources/CurrencyNames_ja.properties`

Re: RFR: 8281146: Replace StringCoding.hasNegatives with countPositives [v14]

2022-03-09 Thread Claes Redestad
> I'm requesting comments and, hopefully, some help with this patch to replace > `StringCoding.hasNegatives` with `countPositives`. The new method does a very > similar pass, but alters the intrinsic to return the number of leading bytes > in the `byte[]` range which only has positive bytes.

Re: RFR: 8281146: Replace StringCoding.hasNegatives with countPositives [v15]

2022-03-09 Thread Claes Redestad
> I'm requesting comments and, hopefully, some help with this patch to replace > `StringCoding.hasNegatives` with `countPositives`. The new method does a very > similar pass, but alters the intrinsic to return the number of leading bytes > in the `byte[]` range which only has positive bytes.

RFR: 8058924: FileReader(String) documentation is insufficient

2022-03-09 Thread Brian Burkhalter
Add a statement to the `java.io` package documentation clarifying how a `String` representing a _pathname string_ is interpreted in the package. - Commit messages: - 8058924: FileReader(String) documentation is insufficient Changes: https://git.openjdk.java.net/jdk/pull/7767/files

Re: RFR: 8281146: Replace StringCoding.hasNegatives with countPositives [v12]

2022-03-09 Thread Claes Redestad
On Wed, 9 Mar 2022 16:52:54 GMT, Claes Redestad wrote: >> I'm requesting comments and, hopefully, some help with this patch to replace >> `StringCoding.hasNegatives` with `countPositives`. The new method does a >> very similar pass, but alters the intrinsic to return the number of leading >>

Re: RFR: 8280400: JDK 19 L10n resource files update - msgdrop 10

2022-03-09 Thread Joe Wang
On Wed, 9 Mar 2022 21:09:30 GMT, Alisen Chung wrote: > msg drop for jdk19, Mar 9, 2022 For the bundles in java.xml: For files with Oracle copyright, update the year to 2022 and @LastModified Mar 2022. Take XPATHErrorResources_ja.java as an example, the copyright year was updated to 2021 and

Re: RFR: 8267319: Use larger default key sizes and algorithms based on CNSA [v3]

2022-03-09 Thread Valerie Peng
On Wed, 9 Mar 2022 19:44:39 GMT, Weijun Wang wrote: >> Valerie Peng has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Update JarSigner javadoc to make it consistent with previous update > >

Re: RFR: 8281631: HashMap copy constructor and putAll can over-allocate table [v27]

2022-03-09 Thread Stuart Marks
On Sat, 5 Mar 2022 19:06:03 GMT, XenoAmess wrote: >> 8281631: HashMap copy constructor and putAll can over-allocate table > > XenoAmess has updated the pull request incrementally with one additional > commit since the last revision: > > refactor tests Sorry, the test changes look like

Re: RFR: 8267319: Use larger default key sizes and algorithms based on CNSA [v3]

2022-03-09 Thread Weijun Wang
On Wed, 9 Mar 2022 19:15:36 GMT, Valerie Peng wrote: >> It's been several years since we increased the default key sizes. Before >> shifting to PQC, NSA replaced its Suite B cryptography recommendations with >> the Commercial National Security Algorithm Suite which suggests: >> >> - SHA-384

RFR: JDK-8282776: Bad NullPointerException message when invoking an interface MethodHandle on a null receiver

2022-03-09 Thread Mandy Chung
A simple patch to call `Objects.requireNonNull(recv)` for an explicit null receiver check rather than NPE thrown by `Object::getClass`. The message of NPE generated by JEP 358 (Helpful NullPointerExceptions) is supposed to be helpful but not in this case. - Commit messages: -

Re: RFR: 4511638: Double.toString(double) sometimes produces incorrect results [v6]

2022-03-09 Thread Brian Burkhalter
On Tue, 8 Feb 2022 22:11:34 GMT, Raffaello Giulietti wrote: >> Hello, >> >> here's a PR for a patch submitted on March 2020 >> [1](https://cr.openjdk.java.net/~bpb/4511638/webrev.04/) when Mercurial was >> a thing. >> >> The patch has been edited to adhere to OpenJDK code conventions about

Re: RFR: JDK-8266670: Better modeling of access flags in core reflection [v17]

2022-03-09 Thread Peter Levart
On Sat, 5 Mar 2022 19:54:44 GMT, Joe Darcy wrote: >> This is an early review of changes to better model JVM access flags, that is >> "modifiers" like public, protected, etc. but explicitly at a VM level. >> >> Language level modifiers and JVM level access flags are closely related, but >>

Re: RFR: 8281146: Replace StringCoding.hasNegatives with countPositives [v14]

2022-03-09 Thread Claes Redestad
On Wed, 9 Mar 2022 23:44:22 GMT, Claes Redestad wrote: >> I'm requesting comments and, hopefully, some help with this patch to replace >> `StringCoding.hasNegatives` with `countPositives`. The new method does a >> very similar pass, but alters the intrinsic to return the number of leading >>

Re: RFR: 8267319: Use larger default key sizes and algorithms based on CNSA [v4]

2022-03-09 Thread Valerie Peng
> It's been several years since we increased the default key sizes. Before > shifting to PQC, NSA replaced its Suite B cryptography recommendations with > the Commercial National Security Algorithm Suite which suggests: > > - SHA-384 for secure hashing > - AES-256 for symmetric encryption > -

Re: RFR: 8279598: Provide adapter from RandomGenerator to Random [v15]

2022-03-09 Thread Stuart Marks
On Sun, 6 Mar 2022 01:39:02 GMT, Yasser Bazzi wrote: >> Hi, could i get a review on this implementation proposed by Stuart Marks, i >> decided to use the >> https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/random/RandomGenerator.html >> interface to create the default

Re: RFR: 4511638: Double.toString(double) sometimes produces incorrect results [v6]

2022-03-09 Thread Suminda Sirinath Salpitikorala Dharmasena
On Tue, 8 Feb 2022 22:11:34 GMT, Raffaello Giulietti wrote: >> Hello, >> >> here's a PR for a patch submitted on March 2020 >> [1](https://cr.openjdk.java.net/~bpb/4511638/webrev.04/) when Mercurial was >> a thing. >> >> The patch has been edited to adhere to OpenJDK code conventions about

Re: RFR: JDK-8282776: Bad NullPointerException message when invoking an interface MethodHandle on a null receiver

2022-03-09 Thread David Holmes
On Wed, 9 Mar 2022 22:52:41 GMT, Mandy Chung wrote: > A simple patch to call `Objects.requireNonNull(recv)` for an explicit null > receiver check rather than NPE thrown by `Object::getClass`. The message of > NPE generated by JEP 358 (Helpful NullPointerExceptions) is supposed to be >

Re: RFR: 8279598: Provide adapter from RandomGenerator to Random [v14]

2022-03-09 Thread Stuart Marks
On Sat, 5 Mar 2022 21:27:47 GMT, Marcono1234 wrote: > Would it make sense to override next(int) to always throw an exception? Even > though it should not be possible for a user to call the method on the > wrapper, it might be better to be on the safe side; for example in case a new > Random

Re: RFR: JDK-8266670: Better modeling of access flags in core reflection [v17]

2022-03-09 Thread Peter Levart
On Tue, 8 Mar 2022 00:19:58 GMT, Joe Darcy wrote: > > The mapping from Location to AccessFlag(s) could be implemented event > > without using a Map. You just have to be careful not to use EnumSet for > > that (i.e. before AccessFlag enum constants are fully initialized) - an > > ArrayList is

Re: RFR: 8264160: Regex \b is not consistent with \w without UNICODE_CHARACTER_CLASS [v4]

2022-03-09 Thread Lance Andersen
On Wed, 9 Mar 2022 01:33:43 GMT, Ian Graves wrote: >> Proposed change in behavior to correct inconsistencies between `\w` and `\b` >> metacharacters > > Ian Graves has updated the pull request incrementally with one additional > commit since the last revision: > > Updating with additional

Re: RFR: 8279508: Auto-vectorize Math.round API [v12]

2022-03-09 Thread Jatin Bhateja
> Summary of changes: > - Intrinsify Math.round(float) and Math.round(double) APIs. > - Extend auto-vectorizer to infer vector operations on encountering scalar IR > nodes for above intrinsics. > - Test creation using new IR testing framework. > > Following are the performance number of a JMH

Re: RFR: 8282429: StringBuilder/StringBuffer.toString() skip compressing for UTF16 strings [v3]

2022-03-09 Thread Daniel Jeliński
On Wed, 9 Mar 2022 08:33:36 GMT, Xin Liu wrote: >> If AbstractStringBuilder only grow, the inflated value which has been >> encoded in UTF16 can't be compressed. >> toString() can skip compression in this case. This can save an >> ArrayAllocation in StringUTF16::compress(). >> >>

Re: RFR: 8253495: CDS generates non-deterministic output [v2]

2022-03-09 Thread David Holmes
On Wed, 9 Mar 2022 05:10:44 GMT, Ioi Lam wrote: >> This patch makes the result of "java -Xshare:dump" deterministic: >> - Disabled new Java threads from launching. This is harmless. See comments >> in jvm.cpp >> - Fixed a problem in hashtable ordering in heapShared.cpp >> - BasicHashtableEntry

Re: RFR: 8282662: Use List/Set.of() factory methods to reduce memory consumption [v2]

2022-03-09 Thread liach
On Wed, 9 Mar 2022 08:35:45 GMT, Сергей Цыпанов wrote: >> `List.of()` along with `Set.of()` create unmodifiable `List/Set` but with >> smaller footprint comparing to `Arrays.asList()` / `new HashSet()` when >> called with vararg of size 0, 1, 2. >> >> In general replacement of

Re: RFR: 8264160: Regex \b is not consistent with \w without UNICODE_CHARACTER_CLASS [v4]

2022-03-09 Thread Brian Burkhalter
On Wed, 9 Mar 2022 01:33:43 GMT, Ian Graves wrote: >> Proposed change in behavior to correct inconsistencies between `\w` and `\b` >> metacharacters > > Ian Graves has updated the pull request incrementally with one additional > commit since the last revision: > > Updating with additional

Re: RFR: 8267319: Use larger default key sizes and algorithms based on CNSA [v2]

2022-03-09 Thread Weijun Wang
On Wed, 9 Mar 2022 02:02:51 GMT, Valerie Peng wrote: >> It's been several years since we increased the default key sizes. Before >> shifting to PQC, NSA replaced its Suite B cryptography recommendations with >> the Commercial National Security Algorithm Suite which suggests: >> >> - SHA-384

Re: RFR: 8281146: Replace StringCoding.hasNegatives with countPositives [v12]

2022-03-09 Thread Claes Redestad
> I'm requesting comments and, hopefully, some help with this patch to replace > `StringCoding.hasNegatives` with `countPositives`. The new method does a very > similar pass, but alters the intrinsic to return the number of leading bytes > in the `byte[]` range which only has positive bytes.

Re: RFR: 8282662: Use List/Set.of() factory methods to reduce memory consumption [v2]

2022-03-09 Thread Сергей Цыпанов
On Tue, 8 Mar 2022 14:27:23 GMT, liach wrote: >> Сергей Цыпанов has updated the pull request incrementally with one >> additional commit since the last revision: >> >> 8282662: Revert dubious changes > > src/java.base/share/classes/java/nio/file/FileTreeIterator.java line 70: > >> 68:

Re: RFR: 8282429: StringBuilder/StringBuffer.toString() skip compressing for UTF16 strings [v3]

2022-03-09 Thread Xin Liu
> If AbstractStringBuilder only grow, the inflated value which has been encoded > in UTF16 can't be compressed. > toString() can skip compression in this case. This can save an > ArrayAllocation in StringUTF16::compress(). > > java.io.BufferedRead::readLine() is a case that StringBuilder grows

Re: RFR: 8282628: Potential memory leak in sun.font.FontConfigManager.getFontConfig() [v2]

2022-03-09 Thread Alexey Ivanov
On Tue, 8 Mar 2022 15:54:45 GMT, Zhengyu Gu wrote: >> Please review this small patch that fixes a potential memory leak that >> exception return fails to release allocated `cacheDirs` >> >> Test: >> >> - [x] jdk_desktop on Linux x86_64 > > Zhengyu Gu has updated the pull request incrementally

Re: RFR: 8282628: Potential memory leak in sun.font.FontConfigManager.getFontConfig() [v2]

2022-03-09 Thread Alexey Ivanov
On Tue, 8 Mar 2022 20:47:45 GMT, Alexey Ivanov wrote: > You're right. The old icon handles in `hOldIcon` and `hOldIconSm` will be > leaked here if `CreateIconFromRaster` throws an exception. I've submitted [JDK-8282862](https://bugs.openjdk.java.net/browse/JDK-8282862): AwtWindow::SetIconData

Re: RFR: 8253495: CDS generates non-deterministic output [v2]

2022-03-09 Thread Thomas Stuefe
On Wed, 9 Mar 2022 05:10:44 GMT, Ioi Lam wrote: >> This patch makes the result of "java -Xshare:dump" deterministic: >> - Disabled new Java threads from launching. This is harmless. See comments >> in jvm.cpp >> - Fixed a problem in hashtable ordering in heapShared.cpp >> - BasicHashtableEntry

Re: RFR: 8282662: Use List/Set.of() factory methods to reduce memory consumption [v2]

2022-03-09 Thread Сергей Цыпанов
> `List.of()` along with `Set.of()` create unmodifiable `List/Set` but with > smaller footprint comparing to `Arrays.asList()` / `new HashSet()` when > called with vararg of size 0, 1, 2. > > In general replacement of `Arrays.asList()` with `List.of()` is dubious as > the latter is

Re: RFR: 8282662: Use List/Set.of() factory methods to reduce memory consumption [v2]

2022-03-09 Thread Сергей Цыпанов
On Tue, 8 Mar 2022 14:28:00 GMT, liach wrote: >> Сергей Цыпанов has updated the pull request incrementally with one >> additional commit since the last revision: >> >> 8282662: Revert dubious changes > > src/java.base/share/classes/sun/reflect/annotation/AnnotationSupport.java > line 79: >

[jdk18] RFR: 8277072: ObjectStreamClass caches keep ClassLoaders alive

2022-03-09 Thread Roman Kennke
Hi all, This pull request contains a backport of commit [8eb453ba](https://github.com/openjdk/jdk/commit/8eb453baebe377697286f7eb32280ca9f1fd7775) from the [openjdk/jdk](https://git.openjdk.java.net/jdk) repository. The commit being backported was authored by Roman Kennke on 10 Dec

Re: RFR: JDK-8282798 java.lang.runtime.Carrier

2022-03-09 Thread Jim Laskey
On Tue, 8 Mar 2022 14:02:39 GMT, Jim Laskey wrote: > We propose to provide a runtime anonymous carrier class object generator; > java.lang.runtime.Carrier. This generator class is designed to share > anonymous classes when shapes are similar. For example, if several clients > require objects

Re: Please help backport the fix with the XSLT compiler in JDK18 to JDK11 & JDK17

2022-03-09 Thread Joe Darcy
Note that management of the update releases are are discussed on different aliases and follow their own processes:     http://mail.openjdk.java.net/mailman/listinfo/jdk-updates-dev     http://openjdk.java.net/projects/jdk-updates/ -Joe On 3/7/2022 6:59 PM, Cheng Jin wrote: Hi there, I

Re: [jdk18] RFR: 8277072: ObjectStreamClass caches keep ClassLoaders alive

2022-03-09 Thread Roger Riggs
On Wed, 9 Mar 2022 13:11:27 GMT, Roman Kennke wrote: > Hi all, > > This pull request contains a backport of commit > [8eb453ba](https://github.com/openjdk/jdk/commit/8eb453baebe377697286f7eb32280ca9f1fd7775) > from the [openjdk/jdk](https://git.openjdk.java.net/jdk) repository. > > The

Re: [jdk18] RFR: 8277072: ObjectStreamClass caches keep ClassLoaders alive

2022-03-09 Thread Roman Kennke
On Wed, 9 Mar 2022 13:11:27 GMT, Roman Kennke wrote: > Hi all, > > This pull request contains a backport of commit > [8eb453ba](https://github.com/openjdk/jdk/commit/8eb453baebe377697286f7eb32280ca9f1fd7775) > from the [openjdk/jdk](https://git.openjdk.java.net/jdk) repository. > > The

[jdk18] Withdrawn: 8277072: ObjectStreamClass caches keep ClassLoaders alive

2022-03-09 Thread Roman Kennke
On Wed, 9 Mar 2022 13:11:27 GMT, Roman Kennke wrote: > Hi all, > > This pull request contains a backport of commit > [8eb453ba](https://github.com/openjdk/jdk/commit/8eb453baebe377697286f7eb32280ca9f1fd7775) > from the [openjdk/jdk](https://git.openjdk.java.net/jdk) repository. > > The

Re: RFR: 8282662: Use List/Set.of() factory methods to reduce memory consumption [v2]

2022-03-09 Thread liach
On Wed, 9 Mar 2022 09:37:30 GMT, Сергей Цыпанов wrote: >> src/java.base/share/classes/java/nio/file/FileTreeIterator.java line 70: >> >>> 68: throws IOException >>> 69: { >>> 70: this.walker = new FileTreeWalker(List.of(options), maxDepth); >> >> Relates to

Re: RFR: JDK-8282798 java.lang.runtime.Carrier [v2]

2022-03-09 Thread Jim Laskey
> We propose to provide a runtime anonymous carrier class object generator; > java.lang.runtime.Carrier. This generator class is designed to share > anonymous classes when shapes are similar. For example, if several clients > require objects containing two integer fields, then Carrier will

Re: RFR: 8264160: Regex \b is not consistent with \w without UNICODE_CHARACTER_CLASS [v5]

2022-03-09 Thread Brian Burkhalter
On Wed, 9 Mar 2022 17:49:11 GMT, Ian Graves wrote: >> Proposed change in behavior to correct inconsistencies between `\w` and `\b` >> metacharacters > > Ian Graves has updated the pull request incrementally with one additional > commit since the last revision: > > Removing superfluous 'if'

Re: RFR: 8264160: Regex \b is not consistent with \w without UNICODE_CHARACTER_CLASS [v5]

2022-03-09 Thread Naoto Sato
On Wed, 9 Mar 2022 17:55:47 GMT, Ian Graves wrote: >> Proposed change in behavior to correct inconsistencies between `\w` and `\b` >> metacharacters > > Ian Graves has updated the pull request incrementally with one additional > commit since the last revision: > > Removing superfluous 'if'

Re: RFR: 8264160: Regex \b is not consistent with \w without UNICODE_CHARACTER_CLASS [v4]

2022-03-09 Thread Ian Graves
On Wed, 9 Mar 2022 16:30:24 GMT, Brian Burkhalter wrote: >> Ian Graves has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Updating with additional descriptors. Removing DataProvider import > >

Re: RFR: 8264160: Regex \b is not consistent with \w without UNICODE_CHARACTER_CLASS [v5]

2022-03-09 Thread Ian Graves
> Proposed change in behavior to correct inconsistencies between `\w` and `\b` > metacharacters Ian Graves has updated the pull request incrementally with one additional commit since the last revision: Removing superfluous 'if' - Changes: - all:

Re: RFR: 8254574: PrintWriter handling of InterruptedIOException PrintWriter handling of InterruptedIOException should be removed [v2]

2022-03-09 Thread Brian Burkhalter
> Remove reference to `java.io.InterruptedIOException` from > `java.io.PrintStream`, and make the specifications of `checkError()`, > `setError()`, and `clearError()` consistent between `java.io.PrintStream` and > `java.io.PrintWriter`. Brian Burkhalter has refreshed the contents of this pull

Re: RFR: 8267319: Use larger default key sizes and algorithms based on CNSA [v3]

2022-03-09 Thread Valerie Peng
> It's been several years since we increased the default key sizes. Before > shifting to PQC, NSA replaced its Suite B cryptography recommendations with > the Commercial National Security Algorithm Suite which suggests: > > - SHA-384 for secure hashing > - AES-256 for symmetric encryption > -

Re: RFR: 8256018: Adler32/CRC32/CRC32C missing reachabilityFence [v2]

2022-03-09 Thread Volker Simonis
On Wed, 11 Nov 2020 11:58:08 GMT, Lance Andersen wrote: >> Hi, >> >> Please review the fix for JDK-8256018 which addresses the issue that the >> update(ByteBuffer) methods of Adler32, CRC32, and CRC32C should use >> Reference.reachabilityFence to ensure that direct byte buffer are kept

Re: RFC: JDK-8282648: Problems due to conflicting specification of Inflater::inflate(..) and InflaterInputStream::read(..)

2022-03-09 Thread Volker Simonis
@Alan, @Lance, Sorry for my obtrusiveness, but what's your opinion on this issue? Thank you and best regards, Volker On Fri, Mar 4, 2022 at 11:04 AM Volker Simonis wrote: > > `java.util.zip.Inflater` is the Java wrapper class for zlib's inflater > functionality. `Inflater::inflate(byte[]