RFR: 8365053: Refresh hotspot precompiled.hpp with headers based on current frequency [v8]

Quan Anh Mai qamai at openjdk.org
Fri Aug 8 16:31:15 UTC 2025


On Fri, 8 Aug 2025 15:32:32 GMT, Francesco Andreuzzi <duke at openjdk.org> wrote:

>> src/utils/PrecompiledHeaders/PrecompiledHeaders.java line 85:
>> 
>>> 83:                         try {
>>> 84:                             // The first line contains the object name
>>> 85:                             return Files.lines(file).skip(1);
>> 
>> Or maybe `return Files.lines(file).skip(1).distinct()`?
>
> `distinct()` has some overhead, do we need it? Do we expect duplicate headers in a file?

It's not like stream is the most performant method to do anything anyway. I think the clarification is worth the additional overhead, especially when this file is not run very frequently.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/26681#discussion_r2263469891


More information about the hotspot-dev mailing list