Re: RFR: 8283335 : Add exists and readAttributesIfExists methods to FileSystemProvider

2022-06-23 Thread Alan Bateman
On Wed, 22 Jun 2022 22:18:05 GMT, Brian Burkhalter wrote: > I think that this is the only use of `stat2()`. It could be deleted if this > method were replaced with this: The purpose of these additions to the SPI is to improve the performance of user facing methods that don't throw an exception

Re: RFR: 8283335 : Add exists and readAttributesIfExists methods to FileSystemProvider

2022-06-23 Thread Chris Hegarty
On Wed, 22 Jun 2022 19:05:41 GMT, Lance Andersen wrote: > Hi, > > Please review the following patch which will: > > - Enhance the java.nio.file.spi.FileSystemProvider abstract class to include > the methods > > - public boolean exists(Path path, LinkOption... options) > - public A readAt

Re: RFR: 8288979: Improve CLDRConverter run time [v3]

2022-06-23 Thread Daniel Jeliński
> This PR improves the performance of deduplication done by > ResourceBundleGenerator. > > The original implementation compared every pair of values, requiring O(n^2) > time. The new implementation uses a HashMap to find duplicates, trading off > some extra memory consumption for O(n) computati

Re: RFR: 8288979: Improve CLDRConverter run time [v3]

2022-06-23 Thread Daniel Jeliński
On Wed, 22 Jun 2022 21:45:25 GMT, Naoto Sato wrote: >> IIUC, once this fix makes it to the repository, the build will be >> reproducible. Making it to be sorted is a welcome enhancement (I compare the >> generated bundles manually from time to time), but it may be costly so it >> could defy th

Re: RFR: 8288979: Improve CLDRConverter run time [v3]

2022-06-23 Thread Daniel Jeliński
On Thu, 23 Jun 2022 08:56:08 GMT, Daniel Jeliński wrote: >> BTW, this can utilize the new `HashMap.newHashMap()`, although I don't think >> resizing would be occurring in this case. > >> once this fix makes it to the repository, the build will be reproducible > > Yes, we always produce the same

Re: RFR: 8288589: Files.readString ignores encoding errors for UTF-16 [v6]

2022-06-23 Thread Alan Bateman
On Wed, 22 Jun 2022 17:46:58 GMT, Naoto Sato wrote: >> This is a regression caused by the fix to >> [JDK-8286287](https://bugs.openjdk.org/browse/JDK-8286287), which assumed >> the method `String.decodeWithDecoder()` was only invoked with cs.REPLACE >> mode based on the comment "should not hap

Re: RFR: 8288589: Files.readString ignores encoding errors for UTF-16 [v5]

2022-06-23 Thread Alan Bateman
On Wed, 22 Jun 2022 17:41:45 GMT, Naoto Sato wrote: > Done. Thanks, that will be helpful if the test fails. - PR: https://git.openjdk.org/jdk/pull/9193

Integrated: 8287760: --do-not-resolve-by-default gets overwritten if --warn-if-resolved flags is used

2022-06-23 Thread Thiago Henrique Hüpner
On Tue, 7 Jun 2022 00:45:17 GMT, Thiago Henrique Hüpner wrote: > 8287760: --do-not-resolve-by-default gets overwritten if --warn-if-resolved > flags is used This pull request has now been integrated. Changeset: a802b981 Author:Thiago Henrique Hüpner Committer: Alan Bateman URL: h

Re: RFR: 8283335 : Add exists and readAttributesIfExists methods to FileSystemProvider

2022-06-23 Thread Alan Bateman
On Wed, 22 Jun 2022 19:05:41 GMT, Lance Andersen wrote: > Hi, > > Please review the following patch which will: > > - Enhance the java.nio.file.spi.FileSystemProvider abstract class to include > the methods > > - public boolean exists(Path path, LinkOption... options) > - public A readAt

Re: RFR: 8283335 : Add exists and readAttributesIfExists methods to FileSystemProvider

2022-06-23 Thread Alan Bateman
On Wed, 22 Jun 2022 19:05:41 GMT, Lance Andersen wrote: > Hi, > > Please review the following patch which will: > > - Enhance the java.nio.file.spi.FileSystemProvider abstract class to include > the methods > > - public boolean exists(Path path, LinkOption... options) > - public A readAt

RFR: 8247407: tools/jlink/plugins/CompressorPluginTest.java test failing

2022-06-23 Thread Jaikiran Pai
Can I please get a review for this change which fixes an issue in `jdk.internal.jimage.ImageReader`? The `ImageReader` maintains a map of `nodes` which it uses to keep track of directories/resources from within the image. When a `findNode` is called, it leads to building the `Node` if the node

Re: RFR: 8247407: tools/jlink/plugins/CompressorPluginTest.java test failing

2022-06-23 Thread Athijegannathan Sundararajan
On Thu, 23 Jun 2022 12:59:34 GMT, Jaikiran Pai wrote: > Can I please get a review for this change which fixes an issue in > `jdk.internal.jimage.ImageReader`? > > The `ImageReader` maintains a map of `nodes` which it uses to keep track of > directories/resources from within the image. When a

Re: RFR: 8288495: [test] Make OutputAnalyzer exception more informative

2022-06-23 Thread Roger Riggs
On Thu, 23 Jun 2022 01:13:17 GMT, Jaikiran Pai wrote: >> The RuntimeException from OutputAnalyzer for expected and unexpected exit >> values should include both the actual and expected values. >> The method `shouldHaveExitvalue` and `shouldNotHaveExitValue` include the >> value expected and the

Re: RFR: 8288495: [test] Make OutputAnalyzer exception more informative

2022-06-23 Thread Roger Riggs
On Thu, 23 Jun 2022 06:08:49 GMT, David Holmes wrote: >> test/lib/jdk/test/lib/process/OutputAnalyzer.java line 505: >> >>> 503: reportDiagnosticSummary(); >>> 504: throw new RuntimeException("Unexpected to get exit value >>> of [" >>> 505: + notExpec

Re: RFR: 8288495: [test] Make OutputAnalyzer exception more informative [v2]

2022-06-23 Thread Roger Riggs
> The RuntimeException from OutputAnalyzer for expected and unexpected exit > values should include both the actual and expected values. > The method `shouldHaveExitvalue` and `shouldNotHaveExitValue` include the > value expected and the value not expected instead of the actual value > returned.

Re: RFR: 8288979: Improve CLDRConverter run time [v3]

2022-06-23 Thread Roger Riggs
On Thu, 23 Jun 2022 08:53:37 GMT, Daniel Jeliński wrote: >> This PR improves the performance of deduplication done by >> ResourceBundleGenerator. >> >> The original implementation compared every pair of values, requiring O(n^2) >> time. The new implementation uses a HashMap to find duplicates,

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

2022-06-23 Thread Roger Riggs
On Tue, 21 Jun 2022 22:30:43 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 >> dis

Re: Bug JDK-8176553

2022-06-23 Thread Ricardo Martin Camarero
Hi Aleksei! Thanks for looking this! I have submitted a PR: https://github.com/openjdk/jdk/pull/9256 Best regards! On 6/21/22 17:30, Aleksei Efimov wrote: Hi Ricardo,

Integrated: 8288589: Files.readString ignores encoding errors for UTF-16

2022-06-23 Thread Naoto Sato
On Thu, 16 Jun 2022 22:21:23 GMT, Naoto Sato wrote: > This is a regression caused by the fix to > [JDK-8286287](https://bugs.openjdk.org/browse/JDK-8286287), which assumed the > method `String.decodeWithDecoder()` was only invoked with cs.REPLACE mode > based on the comment "should not happen"

RFR: 8288589: Files.readString ignores encoding errors for UTF-16

2022-06-23 Thread Naoto Sato
Hi all, This pull request contains a backport of commit [2728770e](https://urldefense.com/v3/__https://github.com/openjdk/jdk/commit/2728770e3d73bb11c4d6e54b5aff91588a1a780b__;!!ACWV5N9M2RV99hQ!N3mEnVUKBkymH2i4wvdNdT17pAtXF6773dQA7XG_uBo8CmAZNuaRhs6MMY2TvgGZ6WI7Xst8ex_Eul_yWGyTcg$ ) from the [op

Integrated: 8288589: Files.readString ignores encoding errors for UTF-16

2022-06-23 Thread Naoto Sato
On Thu, 23 Jun 2022 16:12:31 GMT, Naoto Sato wrote: > Hi all, > > This pull request contains a backport of commit > [2728770e](https://urldefense.com/v3/__https://github.com/openjdk/jdk/commit/2728770e3d73bb11c4d6e54b5aff91588a1a780b__;!!ACWV5N9M2RV99hQ!I5gYvkBBqN_IvjE2nbA57e5GTqsIW-Vww4LdZpqNP

Re: RFR: 8288589: Files.readString ignores encoding errors for UTF-16

2022-06-23 Thread Iris Clark
On Thu, 23 Jun 2022 16:12:31 GMT, Naoto Sato wrote: > Hi all, > > This pull request contains a backport of commit > [2728770e](https://urldefense.com/v3/__https://github.com/openjdk/jdk/commit/2728770e3d73bb11c4d6e54b5aff91588a1a780b__;!!ACWV5N9M2RV99hQ!JWTXtcOlxAlKs1OamoE2hbweIBcqRBtUZoAQmPyrE

Integrated: 8287076: Document.normalizeDocument() produces different results

2022-06-23 Thread Joe Wang
On Wed, 22 Jun 2022 20:01:58 GMT, Joe Wang wrote: > Fix a regression in Document.normalizeDocument() caused by a change in JDK 10. > > Test: new test (as in the bug report) and Tier2 passed. This pull request has now been integrated. Changeset: 1f9521e6 Author:Joe Wang URL: https:/

Re: RFR: 8288979: Improve CLDRConverter run time [v3]

2022-06-23 Thread Naoto Sato
On Thu, 23 Jun 2022 08:53:37 GMT, Daniel Jeliński wrote: >> This PR improves the performance of deduplication done by >> ResourceBundleGenerator. >> >> The original implementation compared every pair of values, requiring O(n^2) >> time. The new implementation uses a HashMap to find duplicates,

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

2022-06-23 Thread Joe Darcy
On Tue, 14 Jun 2022 14:22:29 GMT, Roger Riggs wrote: >> Joe Darcy has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Respond to review feedback. > > src/java.base/share/classes/java/lang/reflect/AccessFlag.java line 104: > >> 102: */

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

2022-06-23 Thread Joe Darcy
On Wed, 22 Jun 2022 17:33:25 GMT, Mandy Chung wrote: >> Joe Darcy has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Remove implSpec tag from Executable.accessFlags since the class is sealed. > > src/java.base/share/classes/java/lang/reflec

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

2022-06-23 Thread Joe Darcy
> 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 > distinct. There are concepts that overlap in the two domains

Re: RFR: 8288495: [test] Make OutputAnalyzer exception more informative [v2]

2022-06-23 Thread Leonid Mesnik
On Thu, 23 Jun 2022 14:09:20 GMT, Roger Riggs wrote: >> The RuntimeException from OutputAnalyzer for expected and unexpected exit >> values should include both the actual and expected values. >> The method `shouldHaveExitvalue` and `shouldNotHaveExitValue` include the >> value expected and the

Re: RFR: 8288495: [test] Make OutputAnalyzer exception more informative [v2]

2022-06-23 Thread Naoto Sato
On Thu, 23 Jun 2022 14:09:20 GMT, Roger Riggs wrote: >> The RuntimeException from OutputAnalyzer for expected and unexpected exit >> values should include both the actual and expected values. >> The method `shouldHaveExitvalue` and `shouldNotHaveExitValue` include the >> value expected and the

RFR: 8289078: Make STARTTIME_ANY and STARTTIME_PROCESS_UNKNOWN fields static in ProcessHandleImpl

2022-06-23 Thread Andrey Turbanov
Fields `STARTTIME_ANY` and `STARTTIME_PROCESS_UNKNOWN` are actually unused, but they are useful as documentation on the interface to native. Make them `static` to reduce memory usage. - Commit messages: - [PATCH] Make STARTTIME_ANY and STARTTIME_PROCESS_UNKNOWN fields static in Pro

Integrated: 8288979: Improve CLDRConverter run time

2022-06-23 Thread Daniel Jeliński
On Wed, 22 Jun 2022 14:24:05 GMT, Daniel Jeliński wrote: > This PR improves the performance of deduplication done by > ResourceBundleGenerator. > > The original implementation compared every pair of values, requiring O(n^2) > time. The new implementation uses a HashMap to find duplicates, trad

Re: RFR: 8288495: [test] Make OutputAnalyzer exception more informative [v3]

2022-06-23 Thread Roger Riggs
> The RuntimeException from OutputAnalyzer for expected and unexpected exit > values should include both the actual and expected values. > The method `shouldHaveExitvalue` and `shouldNotHaveExitValue` include the > value expected and the value not expected instead of the actual value > returned.

Re: RFR: 8288495: [test] Make OutputAnalyzer exception more informative [v3]

2022-06-23 Thread Jaikiran Pai
On Thu, 23 Jun 2022 19:01:47 GMT, Roger Riggs wrote: >> The RuntimeException from OutputAnalyzer for expected and unexpected exit >> values should include both the actual and expected values. >> The method `shouldHaveExitvalue` and `shouldNotHaveExitValue` include the >> value expected and the

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

2022-06-23 Thread Joe Darcy
On Thu, 23 Jun 2022 14:37:42 GMT, Roger Riggs wrote: >> Joe Darcy has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Remove implSpec tag from Executable.accessFlags since the class is sealed. > > src/java.base/share/classes/java/lang/reflec

Re: RFR: 8288495: [test] Make OutputAnalyzer exception more informative [v3]

2022-06-23 Thread David Holmes
On Thu, 23 Jun 2022 19:01:47 GMT, Roger Riggs wrote: >> The RuntimeException from OutputAnalyzer for expected and unexpected exit >> values should include both the actual and expected values. >> The method `shouldHaveExitvalue` and `shouldNotHaveExitValue` include the >> value expected and the

Re: RFR: 8289078: Make STARTTIME_ANY and STARTTIME_PROCESS_UNKNOWN fields static in ProcessHandleImpl

2022-06-23 Thread Jaikiran Pai
On Fri, 17 Jun 2022 08:43:00 GMT, Andrey Turbanov wrote: > Fields `STARTTIME_ANY` and `STARTTIME_PROCESS_UNKNOWN` are actually unused, > but they are useful as documentation on the interface to native. > Make them `static` to reduce memory usage. Marked as reviewed by jpai (Reviewer).