Skip to content

Commit 75b98b9

Browse files
committed
- Updated benchmarks for arm64 arch.
1 parent 3300f08 commit 75b98b9

File tree

2 files changed

+60
-50
lines changed

2 files changed

+60
-50
lines changed

benchmarks-arm64.md

Lines changed: 55 additions & 50 deletions
Original file line numberDiff line numberDiff line change
@@ -39,11 +39,11 @@ Pipeline:
3939

4040
| | Nearest | Box | Bilinear | Bicubic | Lanczos3 |
4141
|----------|:-------:|:------:|:--------:|:-------:|:--------:|
42-
| image | 88.57 | - | 161.64 | 302.78 | 427.58 |
43-
| resize | 18.23 | 57.41 | 100.21 | 182.06 | 269.21 |
44-
| libvips | 26.80 | 127.55 | 106.28 | 207.19 | 278.34 |
45-
| fir rust | 0.90 | 21.87 | 35.17 | 83.46 | 112.76 |
46-
| fir neon | 0.90 | 19.73 | 30.06 | 50.35 | 72.19 |
42+
| image | 88.05 | - | 160.98 | 294.47 | 426.20 |
43+
| resize | 18.14 | 57.28 | 99.28 | 185.31 | 269.80 |
44+
| libvips | 26.19 | 126.94 | 107.36 | 208.17 | 277.11 |
45+
| fir rust | 0.84 | 21.60 | 34.95 | 81.72 | 109.98 |
46+
| fir neon | 0.84 | 19.70 | 29.30 | 49.19 | 73.35 |
4747

4848
<!-- bench_compare_rgb end -->
4949

@@ -62,10 +62,10 @@ Pipeline:
6262

6363
| | Nearest | Box | Bilinear | Bicubic | Lanczos3 |
6464
|----------|:-------:|:------:|:--------:|:-------:|:--------:|
65-
| resize | 25.54 | 88.18 | 123.40 | 200.42 | 293.80 |
66-
| libvips | 33.41 | 238.14 | 352.40 | 716.10 | 973.96 |
67-
| fir rust | 0.97 | 49.57 | 63.97 | 125.33 | 169.58 |
68-
| fir neon | 0.97 | 37.39 | 50.31 | 78.54 | 107.03 |
65+
| resize | 25.49 | 87.09 | 124.43 | 197.94 | 292.21 |
66+
| libvips | 33.92 | 235.04 | 350.01 | 708.27 | 973.00 |
67+
| fir rust | 0.95 | 47.90 | 62.63 | 125.31 | 167.72 |
68+
| fir neon | 0.95 | 37.47 | 50.57 | 76.71 | 106.23 |
6969

7070
<!-- bench_compare_rgba end -->
7171

@@ -83,11 +83,11 @@ Pipeline:
8383

8484
| | Nearest | Box | Bilinear | Bicubic | Lanczos3 |
8585
|----------|:-------:|:-----:|:--------:|:-------:|:--------:|
86-
| image | 81.61 | - | 108.99 | 175.51 | 247.57 |
87-
| resize | 10.85 | 27.94 | 40.56 | 64.81 | 96.27 |
88-
| libvips | 12.29 | 50.07 | 38.45 | 70.87 | 94.21 |
89-
| fir rust | 0.47 | 8.81 | 12.35 | 18.06 | 27.73 |
90-
| fir neon | 0.47 | 6.13 | 9.11 | 16.15 | 24.81 |
86+
| image | 82.40 | - | 108.23 | 176.18 | 243.14 |
87+
| resize | 10.63 | 27.73 | 40.17 | 63.92 | 93.05 |
88+
| libvips | 12.24 | 49.95 | 38.41 | 69.98 | 94.07 |
89+
| fir rust | 0.47 | 8.81 | 12.28 | 18.45 | 28.09 |
90+
| fir neon | 0.47 | 5.98 | 9.10 | 15.85 | 24.45 |
9191

9292
<!-- bench_compare_l end -->
9393

@@ -108,9 +108,9 @@ Pipeline:
108108

109109
| | Nearest | Box | Bilinear | Bicubic | Lanczos3 |
110110
|----------|:-------:|:------:|:--------:|:-------:|:--------:|
111-
| libvips | 19.29 | 144.90 | 220.76 | 403.94 | 550.70 |
112-
| fir rust | 0.68 | 37.46 | 46.04 | 61.22 | 71.23 |
113-
| fir neon | 0.68 | 18.38 | 24.45 | 36.89 | 52.69 |
111+
| libvips | 19.00 | 144.15 | 223.38 | 402.93 | 554.41 |
112+
| fir rust | 0.67 | 37.10 | 45.15 | 60.54 | 71.70 |
113+
| fir neon | 0.67 | 18.83 | 25.06 | 37.76 | 52.57 |
114114

115115
<!-- bench_compare_la end -->
116116

@@ -128,11 +128,11 @@ Pipeline:
128128

129129
| | Nearest | Box | Bilinear | Bicubic | Lanczos3 |
130130
|----------|:-------:|:------:|:--------:|:-------:|:--------:|
131-
| image | 91.90 | - | 170.26 | 331.19 | 470.90 |
132-
| resize | 19.59 | 56.26 | 96.88 | 179.84 | 268.43 |
133-
| libvips | 27.43 | 141.41 | 115.52 | 234.66 | 312.04 |
134-
| fir rust | 1.42 | 61.01 | 90.50 | 148.67 | 205.49 |
135-
| fir neon | 1.42 | 63.82 | 71.03 | 93.53 | 132.92 |
131+
| image | 93.07 | - | 169.86 | 332.89 | 475.00 |
132+
| resize | 19.55 | 56.39 | 96.71 | 182.61 | 270.17 |
133+
| libvips | 27.34 | 140.29 | 112.81 | 235.59 | 313.47 |
134+
| fir rust | 1.36 | 61.08 | 89.19 | 145.51 | 203.83 |
135+
| fir neon | 1.36 | 63.59 | 70.68 | 93.43 | 131.31 |
136136

137137
<!-- bench_compare_rgb16 end -->
138138

@@ -151,10 +151,10 @@ Pipeline:
151151

152152
| | Nearest | Box | Bilinear | Bicubic | Lanczos3 |
153153
|----------|:-------:|:------:|:--------:|:-------:|:--------:|
154-
| resize | 31.53 | 87.13 | 129.24 | 219.52 | 318.78 |
155-
| libvips | 37.19 | 245.54 | 368.92 | 742.45 | 1004.81 |
156-
| fir rust | 1.59 | 97.25 | 133.51 | 225.08 | 296.06 |
157-
| fir neon | 1.59 | 56.57 | 78.24 | 119.19 | 162.73 |
154+
| resize | 29.04 | 88.00 | 133.03 | 221.31 | 314.83 |
155+
| libvips | 36.63 | 246.57 | 369.53 | 747.34 | 1015.17 |
156+
| fir rust | 1.59 | 96.13 | 131.20 | 218.79 | 292.14 |
157+
| fir neon | 1.59 | 55.42 | 77.15 | 118.79 | 163.50 |
158158

159159
<!-- bench_compare_rgba16 end -->
160160

@@ -172,11 +172,11 @@ Pipeline:
172172

173173
| | Nearest | Box | Bilinear | Bicubic | Lanczos3 |
174174
|----------|:-------:|:-----:|:--------:|:-------:|:--------:|
175-
| image | 81.22 | - | 110.96 | 185.44 | 253.11 |
176-
| resize | 11.12 | 27.58 | 43.97 | 72.33 | 98.01 |
177-
| libvips | 12.39 | 55.35 | 41.49 | 80.00 | 104.92 |
178-
| fir rust | 0.63 | 28.46 | 39.16 | 58.51 | 83.71 |
179-
| fir neon | 0.63 | 12.96 | 17.41 | 26.79 | 38.46 |
175+
| image | 82.99 | - | 113.48 | 188.98 | 258.69 |
176+
| resize | 11.09 | 27.46 | 43.78 | 72.15 | 98.44 |
177+
| libvips | 12.35 | 55.60 | 42.90 | 81.53 | 104.17 |
178+
| fir rust | 0.66 | 27.95 | 38.46 | 59.48 | 84.43 |
179+
| fir neon | 0.66 | 13.63 | 17.66 | 27.17 | 38.21 |
180180

181181
<!-- bench_compare_l16 end -->
182182

@@ -197,9 +197,9 @@ Pipeline:
197197

198198
| | Nearest | Box | Bilinear | Bicubic | Lanczos3 |
199199
|----------|:-------:|:------:|:--------:|:-------:|:--------:|
200-
| libvips | 20.97 | 150.55 | 241.54 | 428.63 | 583.38 |
201-
| fir rust | 1.00 | 61.63 | 80.23 | 115.45 | 153.73 |
202-
| fir neon | 1.00 | 26.84 | 36.52 | 55.71 | 75.56 |
200+
| libvips | 20.74 | 149.18 | 237.81 | 430.47 | 582.17 |
201+
| fir rust | 1.03 | 61.38 | 80.31 | 115.02 | 153.03 |
202+
| fir neon | 1.03 | 27.42 | 36.49 | 55.28 | 74.79 |
203203

204204
<!-- bench_compare_la16 end -->
205205

@@ -217,13 +217,18 @@ Pipeline:
217217

218218
| | Nearest | Box | Bilinear | Bicubic | Lanczos3 |
219219
|----------|:-------:|:-----:|:--------:|:-------:|:--------:|
220-
| image | 24.55 | - | 49.54 | 78.44 | 104.51 |
221-
| resize | 5.03 | 8.64 | 13.85 | 30.14 | 45.81 |
222-
| libvips | 5.96 | 25.74 | 21.52 | 42.24 | 71.71 |
223-
| fir rust | 0.20 | 9.87 | 14.93 | 29.66 | 51.71 |
220+
| image | 42.00 | - | 96.55 | 185.17 | 250.26 |
221+
| resize | 11.85 | 23.72 | 32.72 | 56.64 | 84.38 |
222+
| libvips | 10.51 | 53.28 | 44.32 | 100.09 | 124.13 |
223+
| fir rust | 0.96 | 21.13 | 32.32 | 53.92 | 79.45 |
224224

225225
<!-- bench_compare_l32f end -->
226226

227+
Note:
228+
The `resize` crate uses `f32` for intermediate calculations.
229+
The `fast_image_resize` uses `f64`. This is a reason why `fast_image_resize`
230+
is slower or equal in cases with `f32`-based pixels.
231+
227232
<!-- bench_compare_la32f start -->
228233

229234
### Resize LA32F (luma with alpha channel) image (F32x2) 4928x3279 => 852x567
@@ -239,10 +244,10 @@ Pipeline:
239244
- The `image` crate does not support multiplying and dividing by alpha channel.
240245
- The `resize` crate does not support this pixel format.
241246

242-
| | Nearest | Box | Bilinear | Bicubic | Lanczos3 |
243-
|----------|:-------:|:-----:|:--------:|:-------:|:--------:|
244-
| libvips | 11.58 | 70.05 | 101.70 | 176.48 | 252.74 |
245-
| fir rust | 0.38 | 22.75 | 30.35 | 49.41 | 71.81 |
247+
| | Nearest | Box | Bilinear | Bicubic | Lanczos3 |
248+
|----------|:-------:|:------:|:--------:|:-------:|:--------:|
249+
| libvips | 19.41 | 142.92 | 210.17 | 382.61 | 506.77 |
250+
| fir rust | 1.60 | 43.16 | 68.07 | 132.43 | 169.07 |
246251

247252
<!-- bench_compare_la32f end -->
248253

@@ -258,12 +263,12 @@ Pipeline:
258263
has converted into RGB32F image.
259264
- Numbers in the table mean a duration of image resizing in milliseconds.
260265

261-
| | Nearest | Box | Bilinear | Bicubic | Lanczos3 |
262-
|----------|:-------:|:-----:|:--------:|:-------:|:--------:|
263-
| image | 26.32 | - | 62.99 | 104.89 | 147.02 |
264-
| resize | 8.97 | 16.30 | 24.52 | 48.25 | 72.16 |
265-
| libvips | 11.75 | 60.36 | 52.63 | 113.20 | 197.67 |
266-
| fir rust | 0.83 | 16.39 | 26.95 | 50.36 | 75.58 |
266+
| | Nearest | Box | Bilinear | Bicubic | Lanczos3 |
267+
|----------|:-------:|:------:|:--------:|:-------:|:--------:|
268+
| image | 51.58 | - | 129.50 | 310.96 | 419.49 |
269+
| resize | 20.90 | 34.90 | 66.06 | 128.80 | 189.37 |
270+
| libvips | 23.94 | 141.04 | 117.50 | 280.96 | 365.64 |
271+
| fir rust | 2.29 | 41.90 | 77.14 | 163.38 | 224.46 |
267272

268273
<!-- bench_compare_rgb32f end -->
269274

@@ -285,7 +290,7 @@ Pipeline:
285290

286291
| | Nearest | Box | Bilinear | Bicubic | Lanczos3 |
287292
|----------|:-------:|:------:|:--------:|:-------:|:--------:|
288-
| libvips | 23.22 | 111.26 | 140.16 | 249.97 | 381.64 |
289-
| fir rust | 1.01 | 35.88 | 45.64 | 70.56 | 93.29 |
293+
| libvips | 36.40 | 236.39 | 326.62 | 618.09 | 820.17 |
294+
| fir rust | 3.33 | 72.85 | 118.83 | 244.32 | 322.10 |
290295

291296
<!-- bench_compare_rgba32f end -->

benchmarks-wasm32.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -216,6 +216,11 @@ Pipeline:
216216

217217
<!-- bench_compare_l32f end -->
218218

219+
Note:
220+
The `resize` crate uses `f32` for intermediate calculations.
221+
The `fast_image_resize` uses `f64`. This is a reason why `fast_image_resize`
222+
is slower or equal in cases with `f32`-based pixels.
223+
219224
<!-- bench_compare_la32f start -->
220225

221226
### Resize LA32F (luma with alpha channel) image (F32x2) 4928x3279 => 852x567

0 commit comments

Comments
 (0)