Re: RFR: 8361972: Clarify the condition of System.console() about standard input/output [v2]

2025-07-19 Thread Alan Bateman
On Thu, 17 Jul 2025 17:39:01 GMT, Justin Lu wrote: >> I was considering the case for `jshell`, where its `System.console()` >> returns a `Console` instance regardless of the `isTTY` state: >> >> https://github.com/openjdk/jdk/blob/bd55d7a49514da9fa4de0d4a372956e21deab4d2/src/jdk.jshell/share/cl

Re: RFR: 8362376: Use @Stable annotation in Java FDLIBM implementation [v3]

2025-07-19 Thread ExE Boss
On Thu, 17 Jul 2025 21:40:13 GMT, Joe Darcy wrote: >> Add `@Stable` to the static final arrays used in the Java port of FDLIBM. > > Joe Darcy has updated the pull request incrementally with one additional > commit since the last revision: > > Implement review feedback. src/java.base/share/cl

Re: RFR: 8357913: Add `@Stable` to BigInteger and BigDecimal [v4]

2025-07-19 Thread Chen Liang
On Wed, 4 Jun 2025 13:12:33 GMT, Shaojin Wen wrote: >> Some static final arrays of BigInteger and BigDecimal are stable and >> immutable. We should add `@Stable` to give the optimizer more information > > Shaojin Wen has updated the pull request with a new target base due to a > merge or a reba

Re: RFR: 8357913: Add `@Stable` to BigInteger and BigDecimal [v3]

2025-07-19 Thread Chen Liang
On Wed, 4 Jun 2025 12:08:09 GMT, Per Minborg wrote: >> Shaojin Wen has updated the pull request incrementally with one additional >> commit since the last revision: >> >> BigInteger::mag remove Stable > > The newly marked arrays are indeed only updated once. Can we see any > benchmark showin

Re: String.charAt vs StringBuilder.charAt performance

2025-07-19 Thread Brett Okken
Making sequence a local variable does improve things (especially for ascii), but a substantial difference remains. It appears that the performance difference for ascii goes all the way back to jdk 11. The difference for non-ascii showed up in jdk 21. I wonder if this is related to the index checks?

Re: String.charAt vs StringBuilder.charAt performance

2025-07-19 Thread Chen Liang
Without looking at C2 IRs, I think there are a few potential culprits we can look into: 1. JDK-8351000 and JDK-8351443 updated StringBuilder 2. Sequence field is read in the loop; I wonder if making it an explicit immutable local variable changes anything here. On Sat, Jul 19, 2025 at 2:34 PM Bret

String.charAt vs StringBuilder.charAt performance

2025-07-19 Thread Brett Okken
I was looking at the performance of StringCharBuffer for various backing CharSequence types and was surprised to see a significant performance difference between String and StringBuffer. I wrote a small jmh which shows that the String implementation of charAt is significantly slower than StringBuil

Re: RFR: 8361587: AssertionError in File.listFiles() when path is empty and -esa is enabled [v8]

2025-07-19 Thread Jaikiran Pai
On Tue, 15 Jul 2025 17:36:22 GMT, Brian Burkhalter wrote: >> Changes to address `File.listFiles` invoked on an empty path. This fixes an >> oversight in #22821. > > Brian Burkhalter has updated the pull request incrementally with one > additional commit since the last revision: > > 8361587:

Withdrawn: 8354799: ZipInputStream doesn't verify CRC for ZIP entry with empty file data

2025-07-19 Thread duke
On Thu, 8 May 2025 12:08:09 GMT, Jaikiran Pai wrote: > Can I please get a review of this change which addresses the issue noted in > https://bugs.openjdk.org/browse/JDK-8354799? > > `java.util.zip.ZipInputStream` when dealing with a `STORED` entry of zero > size was missing a CRC check for tha