Skip to content

Commit f5f88bf

Browse files
committed
Merge branch 'main' of github.com:SpringMT/zstd-ruby
2 parents 77a9e70 + 6db07f5 commit f5f88bf

File tree

1 file changed

+68
-12
lines changed

1 file changed

+68
-12
lines changed

benchmarks/README.md

Lines changed: 68 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,65 @@ bundle exec ruby decompress.rb city.json
1111

1212

1313
# Result
14-
## Compression
15-
16-
### Performance
14+
## 2022/06/20
15+
```
16+
MacBook Pro (13-inch, 2020, Four Thunderbolt 3 ports)
17+
2 GHz クアッドコアIntel Core i5
18+
16 GB 3733 MHz LPDDR4X
19+
```
20+
### Compression
21+
```
22+
% bundle exec ruby compress.rb city.json
23+
Warming up --------------------------------------
24+
snappy 40.000 i/100ms
25+
gzip 3.000 i/100ms
26+
xz 1.000 i/100ms
27+
lz4 29.000 i/100ms
28+
zstd 18.000 i/100ms
29+
Calculating -------------------------------------
30+
snappy 402.381 (± 8.2%) i/s - 2.040k in 5.112554s
31+
gzip 32.348 (±12.4%) i/s - 162.000 in 5.109498s
32+
xz 1.777 (± 0.0%) i/s - 9.000 in 5.116790s
33+
lz4 291.582 (±12.3%) i/s - 1.450k in 5.076016s
34+
zstd 174.981 (±12.6%) i/s - 864.000 in 5.032567s
35+
```
36+
#### Data Size
37+
##### before
38+
```
39+
% ls -alh samples/city.json
40+
-rw-r--r-- 1 springmt staff 1.7M 12 27 15:42 samples/city.json
41+
```
42+
##### after
43+
```
44+
% ls -alh results
45+
total 2784
46+
drwxr-xr-x 7 springmt staff 224B 12 27 15:42 .
47+
drwxr-xr-x 11 springmt staff 352B 12 27 15:42 ..
48+
-rw-r--r-- 1 springmt staff 219K 6 20 10:06 city.json.gzip
49+
-rw-r--r-- 1 springmt staff 365K 6 20 10:06 city.json.lz4
50+
-rw-r--r-- 1 springmt staff 358K 6 20 10:06 city.json.snappy
51+
-rw-r--r-- 1 springmt staff 166K 6 20 10:06 city.json.xz
52+
-rw-r--r-- 1 springmt staff 225K 6 20 10:06 city.json.zstd
53+
```
54+
### Decompression
55+
```
56+
% bundle exec ruby decompress.rb city.json
57+
Warming up --------------------------------------
58+
snappy 85.000 i/100ms
59+
gzip 20.000 i/100ms
60+
xz 4.000 i/100ms
61+
lz4 70.000 i/100ms
62+
zstd 54.000 i/100ms
63+
Calculating -------------------------------------
64+
snappy 862.639 (± 2.6%) i/s - 4.335k in 5.028667s
65+
gzip 207.820 (± 6.7%) i/s - 1.040k in 5.026189s
66+
xz 41.649 (± 4.8%) i/s - 208.000 in 5.004779s
67+
lz4 680.900 (± 3.5%) i/s - 3.430k in 5.043917s
68+
zstd 541.291 (± 7.4%) i/s - 2.700k in 5.037102s
69+
```
1770

71+
## 2017/02/16(https://github.com/SpringMT/zstd-ruby/commit/0ca4b99e4ffaf18b39b2cdb102b5b5bc31a18071)
72+
### Compression
1873
```
1974
% bundle exec ruby compress.rb city.json
2075
Warming up --------------------------------------
@@ -31,18 +86,15 @@ Calculating -------------------------------------
3186
zstd 195.722 (±14.3%) i/s - 952.000 in 5.027488s
3287
```
3388

34-
35-
36-
### Data Size
37-
38-
#### before
89+
#### Data Size
90+
##### before
3991

4092
```
4193
% ls -alh samples/city.json
4294
-rw-r--r--@ 1 makoto staff 1.7M 2 5 16:07 samples/city.json
4395
```
4496

45-
#### after
97+
##### after
4698

4799
```
48100
% ls -alh results
@@ -54,8 +106,7 @@ total 2712
54106
-rw-r--r-- 1 makoto staff 238K 2 5 16:08 city.json.zstd
55107
```
56108

57-
## Decompression
58-
### Performance
109+
### Decompression
59110

60111
```
61112
Warming up --------------------------------------
@@ -72,4 +123,9 @@ Calculating -------------------------------------
72123
zstd 302.455 (±16.5%) i/s - 1.488k in 5.070354s
73124
```
74125

75-
126+
## YYYY/MM/DD
127+
### Compression
128+
#### Data Size
129+
##### before
130+
##### after
131+
### Decompression

0 commit comments

Comments
 (0)