Integrated: 8358533: Improve performance of java.io.Reader.readAllLines

Brian Burkhalter bpb at openjdk.org
Wed Jul 9 16:18:47 UTC 2025


On Wed, 18 Jun 2025 00:04:37 GMT, Brian Burkhalter <bpb at openjdk.org> wrote:

> Replaces the implementation `readAllCharsAsString().lines().toList()` with reading into a temporary `char` array which is then processed to detect line terminators and copy non-terminating characters into strings which are added to the list.

This pull request has now been integrated.

Changeset: 6e203384
Author:    Brian Burkhalter <bpb at openjdk.org>
URL:       https://git.openjdk.org/jdk/commit/6e203384f8777fc55081065b128bd2b0ba074729
Stats:     208 lines in 3 files changed: 192 ins; 10 del; 6 mod

8358533: Improve performance of java.io.Reader.readAllLines

Reviewed-by: rriggs, sherman

-------------

PR: https://git.openjdk.org/jdk/pull/25863


More information about the core-libs-dev mailing list