pjfanning commented on PR #2148: URL: https://github.com/apache/pekko/pull/2148#issuecomment-3259034060
Benchmarks show possible small gains. I can try more Java versions and Scala versions later. I'm using an old Macbook to run this. ``` sbt "bench-jmh/Jmh/run -i 3 -wi 3 -f 1 .*ByteString_indexOf_Benchmark" ``` ``` Scala 2.13 with SWAR changes (Java 17.0.16) [info] Benchmark Mode Cnt Score Error Units [info] ByteString_indexOf_Benchmark.bs1_indexOf_from thrpt 3 760238669.404 ± 767807134.762 ops/s [info] ByteString_indexOf_Benchmark.bss_indexOf_from_best_case thrpt 3 217038390.875 ± 209292888.785 ops/s [info] ByteString_indexOf_Benchmark.bss_indexOf_from_far_index_case thrpt 3 17367673.994 ± 1163638.424 ops/s [info] ByteString_indexOf_Benchmark.bss_indexOf_from_worst_case thrpt 3 5519954.663 ± 441205.202 ops/s [success] Total time: 497 s (0:08:17.0), completed 5 Sep 2025, 17:23:18 Scala 2.13 main branch without SWAR changes (Java 17.0.16) Score Error Units [info] ByteString_indexOf_Benchmark.bs1_indexOf_from thrpt 3 698656851.582 ± 823327975.698 ops/s [info] ByteString_indexOf_Benchmark.bss_indexOf_from_best_case thrpt 3 186356562.647 ± 321470798.822 ops/s [info] ByteString_indexOf_Benchmark.bss_indexOf_from_far_index_case thrpt 3 17710312.697 ± 9020140.588 ops/s [info] ByteString_indexOf_Benchmark.bss_indexOf_from_worst_case thrpt 3 5291631.416 ± 3775859.071 ops/s [success] Total time: 449 s (0:07:29.0), completed 5 Sep 2025, 17:33:31 ``` -- 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: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
