On Thu, 31 Dec 2020 10:10:56 GMT, Philippe Marschall <github.com+471021+marsch...@openjdk.org> wrote:
> Implement three optimiztations for Reader.read(CharBuffer) > > * Add a code path for heap buffers in Reader#read to use the backing array > instead of allocating a new one. > * Change the code path for direct buffers in Reader#read to limit the > intermediate allocation to `TRANSFER_BUFFER_SIZE`. > * Implement `InputStreamReader#read(CharBuffer)` and delegate to > `StreamDecoder`. > * Implement `StreamDecoder#read(CharBuffer)` and avoid buffer allocation. This pull request has now been integrated. Changeset: 65c19c40 Author: Philippe Marschall <philippe.marsch...@gmail.com> Committer: Brian Burkhalter <b...@openjdk.org> URL: https://git.openjdk.java.net/jdk/commit/65c19c40 Stats: 371 lines in 6 files changed: 361 ins; 0 del; 10 mod 4926314: Optimize Reader.read(CharBuffer) Reviewed-by: alanb, bpb ------------- PR: https://git.openjdk.java.net/jdk/pull/1915