Re: RFR: 8304745: Lazily initialize byte[] in java.io.BufferedInputStream [v6]

2023-03-24 Thread Sergey Tsypanov
On Fri, 24 Mar 2023 17:59:24 GMT, Chen Liang wrote: >> Sergey Tsypanov has updated the pull request incrementally with one >> additional commit since the last revision: >> >> 8304745: Amend copyright > > test/micro/org/openjdk/bench/java/io/BufferedInputStreamBenchmark.java line 1: > >> 1: /

Re: RFR: 8304745: Lazily initialize byte[] in java.io.BufferedInputStream [v6]

2023-03-24 Thread Chen Liang
On Fri, 24 Mar 2023 17:02:30 GMT, Sergey Tsypanov wrote: >> By default `BufferedInputStream` is constructed with internal buffer with >> capacity 8192. In some cases this buffer is never used, e.g. when we call >> `IS.readNBytes()` or `IS.readAllBytes()` (relying on `BIS.read1()`) or when >> `

Re: RFR: 8304745: Lazily initialize byte[] in java.io.BufferedInputStream [v6]

2023-03-24 Thread Chen Liang
On Fri, 24 Mar 2023 17:51:03 GMT, Eirik Bjorsnos wrote: > Is something wrong with line endings in the added benchmark? jcheck seems to > complain a lot? It often happens when copying a file on windows. Can usually be fixed in intellij idea by navigating to the file and changing line endings to

Re: RFR: 8304745: Lazily initialize byte[] in java.io.BufferedInputStream [v6]

2023-03-24 Thread Eirik Bjorsnos
On Fri, 24 Mar 2023 17:02:30 GMT, Sergey Tsypanov wrote: >> By default `BufferedInputStream` is constructed with internal buffer with >> capacity 8192. In some cases this buffer is never used, e.g. when we call >> `IS.readNBytes()` or `IS.readAllBytes()` (relying on `BIS.read1()`) or when >> `

Re: RFR: 8304745: Lazily initialize byte[] in java.io.BufferedInputStream [v6]

2023-03-24 Thread Sergey Tsypanov
> By default `BufferedInputStream` is constructed with internal buffer with > capacity 8192. In some cases this buffer is never used, e.g. when we call > `IS.readNBytes()` or `IS.readAllBytes()` (relying on `BIS.read1()`) or when > `BufferedInputStream` is cascaded. Sergey Tsypanov has updated