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

2023-03-27 Thread Sergey Tsypanov
On Fri, 24 Mar 2023 19:30:22 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 [v8]

2023-03-25 Thread Alan Bateman
On Sat, 25 Mar 2023 05:55:46 GMT, Eirik Bjorsnos wrote: > I think the benchmark would benefit with a few words explaining why you > focused on those methods/calling patterns. For someone walking past this > benchmark, this is not obvious why you picked those. I think the interesting case is wh

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

2023-03-24 Thread Eirik Bjorsnos
On Fri, 24 Mar 2023 19:30:22 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 [v8]

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