Skip to content

Commit 32cf6be

Browse files
committed
Docs: update benchmark results ahead of v0.34.3
1 parent 96dfd40 commit 32cf6be

File tree

1 file changed

+44
-42
lines changed

1 file changed

+44
-42
lines changed

docs/src/content/docs/performance.md

Lines changed: 44 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -43,24 +43,24 @@ The I/O limits of the relevant (de)compression library will generally determine
4343

4444
### Contenders
4545

46-
* [jimp](https://www.npmjs.com/package/jimp) v1.6.0 - Image processing in pure JavaScript.
47-
* [imagemagick](https://www.npmjs.com/package/imagemagick) v0.1.3 - Supports filesystem only and "*has been unmaintained for a long time*".
48-
* [gm](https://www.npmjs.com/package/gm) v1.25.1 - Fully featured wrapper around GraphicsMagick's `gm` command line utility, but "*has been sunset*".
49-
* sharp v0.34.0 / libvips v8.16.1 - Caching within libvips disabled to ensure a fair comparison.
46+
- [jimp](https://www.npmjs.com/package/jimp) v1.6.0 - Image processing in pure JavaScript.
47+
- [imagemagick](https://www.npmjs.com/package/imagemagick) v0.1.3 - Supports filesystem only and "_has been unmaintained for a long time_".
48+
- [gm](https://www.npmjs.com/package/gm) v1.25.1 - Fully featured wrapper around GraphicsMagick's `gm` command line utility, but "_has been sunset_".
49+
- sharp v0.34.3 / libvips v8.17.0 - Caching within libvips disabled to ensure a fair comparison.
5050

5151
### Environment
5252

5353
#### AMD64
5454

55-
* AWS EC2 us-west-2 [c7a.xlarge](https://aws.amazon.com/ec2/instance-types/c7a/) (4x AMD EPYC 9R14)
56-
* Ubuntu 24.10 [fad5ba7223f8](https://hub.docker.com/layers/library/ubuntu/24.10/images/sha256-fad5ba7223f8d87179dfa23211d31845d47e07a474ac31ad5258afb606523c0d)
57-
* Node.js 22.14.0
55+
- AWS EC2 us-west-2 [c7a.xlarge](https://aws.amazon.com/ec2/instance-types/c7a/) (4x AMD EPYC 9R14)
56+
- Ubuntu 25.04
57+
- Node.js 24.3.0
5858

5959
#### ARM64
6060

61-
* AWS EC2 us-west-2 [c8g.xlarge](https://aws.amazon.com/ec2/instance-types/c8g/) (4x ARM Graviton4)
62-
* Ubuntu 24.10 [133f2e05cb69](https://hub.docker.com/layers/library/ubuntu/24.10/images/sha256-133f2e05cb6958c3ce7ec870fd5a864558ba780fb7062315b51a23670bff7e76)
63-
* Node.js 22.14.0
61+
- AWS EC2 us-west-2 [c8g.xlarge](https://aws.amazon.com/ec2/instance-types/c8g/) (4x ARM Graviton4)
62+
- Ubuntu 25.04
63+
- Node.js 24.3.0
6464

6565
### Task: JPEG
6666

@@ -72,27 +72,29 @@ Note: jimp does not support Lanczos 3, bicubic resampling used instead.
7272

7373
#### Results: JPEG (AMD64)
7474

75-
| Module | Input | Output | Ops/sec | Speed-up |
76-
| :----------------- | :----- | :----- | ------: | -------: |
77-
| jimp | buffer | buffer | 2.35 | 1.0 |
78-
| imagemagick | file | file | 10.51 | 4.5 |
79-
| gm | buffer | buffer | 11.67 | 5.0 |
80-
| gm | file | file | 11.75 | 5.1 |
81-
| sharp | stream | stream | 60.72 | 25.8 |
82-
| sharp | file | file | 62.37 | 26.5 |
83-
| sharp | buffer | buffer | 65.15 | 27.7 |
75+
| Package | I/O | Ops/sec | Speed-up |
76+
| :---------- | :----- | ------: | -------: |
77+
| jimp | buffer | 2.40 | 1.0 |
78+
| jimp | file | 2.60 | 1.1 |
79+
| imagemagick | file | 9.70 | 4.0 |
80+
| gm | buffer | 11.60 | 4.8 |
81+
| gm | file | 11.72 | 4.9 |
82+
| sharp | stream | 59.40 | 24.8 |
83+
| sharp | file | 62.67 | 26.1 |
84+
| sharp | buffer | 64.42 | 26.8 |
8485

8586
#### Results: JPEG (ARM64)
8687

87-
| Module | Input | Output | Ops/sec | Speed-up |
88-
| :----------------- | :----- | :----- | ------: | -------: |
89-
| jimp | buffer | buffer | 2.13 | 1.0 |
90-
| imagemagick | file | file | 12.95 | 6.1 |
91-
| gm | buffer | buffer | 13.53 | 6.4 |
92-
| gm | file | file | 13.52 | 6.4 |
93-
| sharp | stream | stream | 46.58 | 21.9 |
94-
| sharp | file | file | 48.42 | 22.7 |
95-
| sharp | buffer | buffer | 50.16 | 23.6 |
88+
| Package | I/O | Ops/sec | Speed-up |
89+
| :---------- | :----- | ------: | -------: |
90+
| jimp | buffer | 2.24 | 1.0 |
91+
| jimp | file | 2.47 | 1.1 |
92+
| imagemagick | file | 10.42 | 4.7 |
93+
| gm | buffer | 12.80 | 5.7 |
94+
| gm | file | 12.88 | 5.7 |
95+
| sharp | stream | 45.58 | 20.3 |
96+
| sharp | file | 47.99 | 21.4 |
97+
| sharp | buffer | 49.20 | 22.0 |
9698

9799
### Task: PNG
98100

@@ -106,23 +108,23 @@ Note: jimp does not support premultiply/unpremultiply.
106108

107109
#### Results: PNG (AMD64)
108110

109-
| Module | Input | Output | Ops/sec | Speed-up |
110-
| :----------------- | :----- | :----- | ------: | -------: |
111-
| gm | file | file | 8.66 | 1.0 |
112-
| imagemagick | file | file | 8.79 | 1.0 |
113-
| jimp | buffer | buffer | 11.26 | 1.3 |
114-
| sharp | file | file | 27.93 | 3.2 |
115-
| sharp | buffer | buffer | 28.69 | 3.3 |
111+
| Package | I/O | Ops/sec | Speed-up |
112+
| :---------- | :----- | ------: | -------: |
113+
| imagemagick | file | 6.06 | 1.0 |
114+
| gm | file | 8.44 | 1.4 |
115+
| jimp | buffer | 10.98 | 1.8 |
116+
| sharp | file | 28.26 | 4.7 |
117+
| sharp | buffer | 28.70 | 4.7 |
116118

117119
#### Results: PNG (ARM64)
118120

119-
| Module | Input | Output | Ops/sec | Speed-up |
120-
| :----------------- | :----- | :----- | ------: | -------: |
121-
| gm | file | file | 9.65 | 1.0 |
122-
| imagemagick | file | file | 9.72 | 1.0 |
123-
| jimp | buffer | buffer | 10.68 | 1.1 |
124-
| sharp | file | file | 23.90 | 2.5 |
125-
| sharp | buffer | buffer | 24.48 | 2.5 |
121+
| Package | I/O | Ops/sec | Speed-up |
122+
| :---------- | :----- | ------: | -------: |
123+
| imagemagick | file | 7.09 | 1.0 |
124+
| gm | file | 8.93 | 1.3 |
125+
| jimp | buffer | 10.28 | 1.5 |
126+
| sharp | file | 23.81 | 3.4 |
127+
| sharp | buffer | 24.19 | 3.4 |
126128

127129
## Running the benchmark test
128130

0 commit comments

Comments
 (0)