RFR: 8318709: Improve System.nanoTime performance on Windows [v2]
Daniel Jeliński
djelinski at openjdk.org
Mon Oct 30 07:57:40 UTC 2023
On Thu, 26 Oct 2023 07:25:48 GMT, Daniel Jeliński <djelinski at openjdk.org> wrote:
>> - use LARGE_INTEGER.QuadPart instead of assembling the jlong from high/low parts
>> - precalculate counts_per_nano to avoid costly floating-point division in counter to nanosecond conversion
>>
>> Benchmark before:
>> SystemTime.nanoTime avgt 15 19,366 � 0,383 ns/op
>>
>> After:
>> SystemTime.nanoTime avgt 15 15,812 � 0,385 ns/op
>>
>> Tier1-2 clean.
>
> Daniel Jeliński has updated the pull request incrementally with one additional commit since the last revision:
>
> Fix variable name
Thanks for the reviews!
-------------
PR Comment: https://git.openjdk.org/jdk/pull/16336#issuecomment-1784653275
More information about the hotspot-runtime-dev
mailing list