On Wed, 13 Sep 2023 14:22:35 GMT, 温绍锦 <d...@openjdk.org> wrote:

>> improve date toString performance, includes:
>> 
>> java.util.Date.toString
>> java.util.Date.toGMTString
>> java.time.Instant.toString
>> java.time.LocalDate.toString
>> java.time.LocalDateTime.toString
>> java.time.LocalTime.toString
>
> 温绍锦 has updated the pull request incrementally with one additional commit 
> since the last revision:
> 
>   simplify LocalDate::getChars

Lots of adhoc changes bulk up the source and make it less maintainable.
Given the common element of time and date formatting strings as a domain 
specific language, there would be more benefit to leveraging one of several 
existing mechanisms to generate optimized formatters from application or 
library format strings.
For example, the general purpose [JEP 430: String 
Template](https://openjdk.org/jeps/430)s could be used to compose the string 
and leverage its optimizations of formatting the components.
Making improvements there either to performance or functionality would benefit 
more applications.

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

PR Comment: https://git.openjdk.org/jdk/pull/15658#issuecomment-1726038572

Reply via email to