@@ -11,6 +11,81 @@ bundle exec ruby decompress.rb city.json
1111
1212
1313# Result
14+ ## 2024/03/29
15+ https://github.com/SpringMT/zstd-ruby/commit/53ab279a0db4125dfdc646f638a81f2625c720b5
16+
17+ ```
18+ % system_profiler SPHardwareDataType
19+ Hardware:
20+
21+ Hardware Overview:
22+
23+ Model Name: MacBook Pro
24+ Model Identifier: Mac14,7
25+ Chip: Apple M2
26+ Total Number of Cores: 8 (4 performance and 4 efficiency)
27+ Memory: 24 GB
28+ System Firmware Version: 8422.100.650
29+ OS Loader Version: 7459.141.1
30+ Serial Number (system): V90G2M34LL
31+ Hardware UUID: C9914E86-7CF2-5927-92F9-EE062FB87913
32+ Provisioning UDID: 00008112-000205A22E31401E
33+ Activation Lock Status: Disabled
34+ ```
35+ ### Compression
36+ ```
37+ % bundle exec ruby compress.rb city.json
38+ ruby 3.3.0 (2023-12-25 revision 5124f9ac75) [arm64-darwin21]
39+ Warming up --------------------------------------
40+ snappy 12.000 i/100ms
41+ gzip 5.000 i/100ms
42+ xz 1.000 i/100ms
43+ lz4 43.000 i/100ms
44+ zstd 34.000 i/100ms
45+ Calculating -------------------------------------
46+ snappy 124.315 (± 3.2%) i/s - 624.000 in 5.024270s
47+ gzip 51.185 (± 5.9%) i/s - 255.000 in 5.000801s
48+ xz 3.358 (± 0.0%) i/s - 17.000 in 5.074521s
49+ lz4 443.950 (± 4.1%) i/s - 2.236k in 5.045395s
50+ zstd 352.064 (± 6.5%) i/s - 1.768k in 5.044874s
51+
52+ ```
53+ #### Data Size
54+ ##### before
55+ ```
56+ % ls -alh samples/city.json
57+ -rw-r--r-- 1 springmt staff 1.7M 9 3 2022 samples/city.json
58+ ```
59+ ##### after
60+ ```
61+ % ls -alh results
62+ total 2816
63+ drwxr-xr-x 7 springmt staff 224B 4 9 2023 .
64+ drwxr-xr-x 13 springmt staff 416B 4 9 2023 ..
65+ -rw-r--r-- 1 springmt staff 219K 3 29 14:46 city.json.gzip
66+ -rw-r--r-- 1 springmt staff 384K 3 29 14:46 city.json.lz4
67+ -rw-r--r-- 1 springmt staff 358K 3 29 14:46 city.json.snappy
68+ -rw-r--r-- 1 springmt staff 166K 3 29 14:46 city.json.xz
69+ -rw-r--r-- 1 springmt staff 225K 3 29 14:46 city.json.zstd
70+ ```
71+ ### Decompression
72+ ```
73+ % bundle exec ruby decompress.rb city.json
74+ ruby 3.3.0 (2023-12-25 revision 5124f9ac75) [arm64-darwin21]
75+ Warming up --------------------------------------
76+ snappy 45.000 i/100ms
77+ gzip 44.000 i/100ms
78+ xz 7.000 i/100ms
79+ lz4 121.000 i/100ms
80+ zstd 95.000 i/100ms
81+ Calculating -------------------------------------
82+ snappy 454.245 (± 3.1%) i/s - 2.295k in 5.057263s
83+ gzip 440.680 (± 3.4%) i/s - 2.244k in 5.098470s
84+ xz 77.378 (± 2.6%) i/s - 392.000 in 5.070707s
85+ lz4 1.224k (± 5.1%) i/s - 6.171k in 5.056241s
86+ zstd 932.464 (± 3.2%) i/s - 4.750k in 5.099694s
87+ ```
88+
1489## 2022/06/20
1590https://github.com/SpringMT/zstd-ruby/commit/77a9e704747ad24761bcc8194884270f983538c1
1691```
0 commit comments