Closed plokhotnyuk closed 1 year ago
Thanks!
@piotrrzysko I've relaunched benchmarks on the same environment after merged https://github.com/simdjson/simdjson-java/pull/13 and got following results:
Benchmark Mode Cnt Score Error Units
ParseAndSelectBenchmark.countUniqueUsersWithDefaultProfile_fastjson thrpt 5 931.609 ± 59.739 ops/s
ParseAndSelectBenchmark.countUniqueUsersWithDefaultProfile_jackson thrpt 5 833.133 ± 29.339 ops/s
ParseAndSelectBenchmark.countUniqueUsersWithDefaultProfile_jsoniter thrpt 5 549.024 ± 39.648 ops/s
ParseAndSelectBenchmark.countUniqueUsersWithDefaultProfile_jsoniter_scala thrpt 5 2448.460 ± 41.755 ops/s
ParseAndSelectBenchmark.countUniqueUsersWithDefaultProfile_simdjson thrpt 5 1060.051 ± 31.904 ops/s
ParseAndSelectBenchmark.countUniqueUsersWithDefaultProfile_simdjsonPadded thrpt 5 1078.887 ± 23.682 ops/s
Would it be possible to turn off UTF-8 validation optionally?
I'm planning to add such an option. However, I believe validation should be enabled by default. I'm currently exploring other options to improve the performance, such as the on-demand API available in the C++ version of simdjson, along with support for 512-bit vectors in the utf-8 validator.
BTW, would you mind running the same benchmark from this branch: https://github.com/simdjson/simdjson-java/tree/utf8-experiments? This branch introduces support for 512-bit vectors, and if I'm not mistaken, your CPU supports AVX-512 instructions.
Here are results from the current state of utf8-experiments
branch (I wasn't able to rebase it over the current main
due to a lot of conflicts):
Benchmark Mode Cnt Score Error Units
ParseAndSelectBenchmark.countUniqueUsersWithDefaultProfile_fastjson thrpt 5 926.479 ± 85.427 ops/s
ParseAndSelectBenchmark.countUniqueUsersWithDefaultProfile_jackson thrpt 5 843.090 ± 26.506 ops/s
ParseAndSelectBenchmark.countUniqueUsersWithDefaultProfile_jsoniter thrpt 5 539.741 ± 59.262 ops/s
ParseAndSelectBenchmark.countUniqueUsersWithDefaultProfile_jsoniter_scala thrpt 5 2472.701 ± 17.107 ops/s
ParseAndSelectBenchmark.countUniqueUsersWithDefaultProfile_simdjson thrpt 5 2264.005 ± 28.860 ops/s
ParseAndSelectBenchmark.countUniqueUsersWithDefaultProfile_simdjsonPadded thrpt 5 2392.960 ± 45.448 ops/s
Thanks.
Results on Intel® Core™ i7-11800H CPU @ 2.3GHz (max 4.6GHz), RAM 64Gb DDR4-3200, Ubuntu 23.10 (Linux 6.6.1) with JDK 21 (Java HotSpot(TM) 64-Bit Server VM, 21+35-LTS-2513):