schlosna commented on PR #14678: URL: https://github.com/apache/lucene/pull/14678#issuecomment-2887624646
Added `BytesRefBenchmark` demonstrating existing `new BytesRef(CharSequence)` vs. `new BytesRef(String)` demonstrating 2x to 6x throughput improvement on AMD EPYC 7R13 Processor: ``` # AMD EPYC 7R13 Processor # JMH version: 1.37 # VM version: JDK 24.0.1, OpenJDK 64-Bit Server VM, 24.0.1+9-FR # VM invoker: /home/dev/.gradle/jdks/amazon-corretto-24.0.1.9.1-linux-x64/bin/java # VM options: -XX:+UseParallelGC -XX:TieredStopAtLevel=1 -XX:ActiveProcessorCount=1 -Dfile.encoding=UTF-8 -Duser.country=US -Duser.language=en -Duser.variant # Blackhole mode: compiler (auto-detected, use -Djmh.blackhole.autoDetect=false to disable) # Warmup: 3 iterations, 3 s each # Measurement: 5 iterations, 3 s each (before) (after) bytesRefCharSequence bytesRefString Benchmark (length) (type) Mode Cnt Score Error Score Error Units BytesRefBenchmark 10 ASCII thrpt 5 75.650 ± 4.078 180.382 ± 7.672 ops/us BytesRefBenchmark 10 ISO_8859_1 thrpt 5 66.688 ± 3.957 114.655 ± 7.510 ops/us BytesRefBenchmark 10 UTF_8_BMP thrpt 5 46.678 ± 2.387 77.036 ± 2.484 ops/us BytesRefBenchmark 10 UTF_16 thrpt 5 26.289 ± 1.376 49.021 ± 1.740 ops/us BytesRefBenchmark 100 ASCII thrpt 5 9.106 ± 0.487 47.246 ± 1.218 ops/us BytesRefBenchmark 100 ISO_8859_1 thrpt 5 8.447 ± 0.628 23.809 ± 0.488 ops/us BytesRefBenchmark 100 UTF_8_BMP thrpt 5 5.129 ± 0.141 10.431 ± 0.336 ops/us BytesRefBenchmark 100 UTF_16 thrpt 5 2.963 ± 0.127 5.904 ± 0.271 ops/us BytesRefBenchmark 1000 ASCII thrpt 5 0.917 ± 0.038 5.891 ± 0.428 ops/us BytesRefBenchmark 1000 ISO_8859_1 thrpt 5 0.830 ± 0.024 1.981 ± 0.077 ops/us BytesRefBenchmark 1000 UTF_8_BMP thrpt 5 0.468 ± 0.014 0.950 ± 0.057 ops/us BytesRefBenchmark 1000 UTF_16 thrpt 5 0.298 ± 0.011 0.537 ± 0.021 ops/us ``` -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org For additional commands, e-mail: issues-h...@lucene.apache.org