On Mon, 26 Jun 2023 09:57:31 GMT, 温绍锦 <d...@openjdk.org> wrote:

>> By optimizing the implementation of java.lang.Long#fastUUID, the performance 
>> of the java.util.UUID#toString method can be significantly improved.
>> 
>> The following are the test results of JMH: 
>> 
>> Benchmark                     Mode  Cnt      Score      Error   Units
>> UUIDUtilsBenchmark.new       thrpt    5  92676.550 ±  292.213  ops/ms
>> UUIDUtilsBenchmark.original  thrpt    5  37040.165 ± 1023.532  ops/ms
>
> 温绍锦 has updated the pull request incrementally with one additional commit 
> since the last revision:
> 
>   use ISO_8859_1.INSTANCE directly instead of StandardCharsets.ISO_8859_1

with JVMOpts '-XX:-CompactStrings', i tested on the MacBookPro M1 Max and found 
that the current version is faster than the baseline version.


Benchmark                Mode  Cnt      Score      Error   Units (PR current 
version 6b61a715) 
UUIDUtilsBenchmark.jdk  thrpt    5  89601.097 ± 1879.659  ops/ms

Benchmark                Mode  Cnt      Score     Error   Units (baseline)
UUIDUtilsBenchmark.jdk  thrpt    5  71783.920 ± 170.914  ops/ms

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

PR Comment: https://git.openjdk.org/jdk/pull/14578#issuecomment-1608475831

Reply via email to