Skip to content

Commit 83a14ae

Browse files
committed
docs: Update benchmarks
1 parent 4e17cf6 commit 83a14ae

File tree

3 files changed

+17
-17
lines changed

3 files changed

+17
-17
lines changed

README.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -140,14 +140,14 @@ fn main() -> Result<(), css_inline::InlineError> {
140140

141141
`css-inline` typically inlines HTML emails within hundreds of microseconds, though results may vary with input complexity.
142142

143-
Benchmarks for `css-inline==0.10.5`:
143+
Benchmarks for `css-inline==0.11.1`:
144144

145-
- Basic: **6.40 µs**, 230 bytes
146-
- Realistic-1: **140.19 µs**, 8.58 KB
147-
- Realistic-2: **86.21 µs**, 4.3 KB
148-
- GitHub page: **263.33 ms**, 1.81 MB
145+
- Basic: **6.60 µs**, 230 bytes
146+
- Realistic-1: **134.99 µs**, 8.58 KB
147+
- Realistic-2: **93.56 µs**, 4.3 KB
148+
- GitHub page: **329.99 ms**, 1.81 MB
149149

150-
These benchmarks, conducted using `rustc 1.71.1`, can be found in `css-inline/benches/inliner.rs`.
150+
These benchmarks, conducted using `rustc 1.74.0`, can be found in `css-inline/benches/inliner.rs`.
151151

152152
## Bindings
153153

bindings/python/README.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -170,17 +170,17 @@ Most of the time it achieves over a **10x** speed advantage compared to the next
170170

171171
Here is the performance comparison:
172172

173-
| | Size | `css_inline 0.10.4` | `premailer 3.10.0` | `toronado 0.1.0` | `inlinestyler 0.2.5` | `pynliner 0.8.0` |
173+
| | Size | `css_inline 0.11.1` | `premailer 3.10.0` | `toronado 0.1.0` | `inlinestyler 0.2.5` | `pynliner 0.8.0` |
174174
|-------------|---------|---------------------|-------------------------|-------------------------|-------------------------|-------------------------|
175-
| Basic | 230 B | 6.58 µs | 130.45 µs (**19.82x**) | 671.87 µs (**102.06**) | 1.05 ms (**161.00**) | 1.23 ms (**187.51x**) |
176-
| Realistic-1 | 8.58 KB | 146.20 µs | 1.42 ms (**9.71x**) | 16.56 ms (**113.29x**) | 27.45 ms (**187.78x**) | 51.85 ms (**354.66x**) |
177-
| Realistic-2 | 4.3 KB | 87.91 µs | 2.71 ms (**30.90x**) | ERROR | 18.07 ms (**205.64x**) | ERROR |
178-
| GitHub page | 1.81 MB | 262.74 ms | 25.38 s (**96.63x**) | ERROR | ERROR | ERROR |
175+
| Basic | 230 B | 6.62 µs | 127.54 µs (**19.25x**) | 661.58 µs (**99.86**) | 1.04 ms (**157.91**) | 1.13 ms (**180.99x**) |
176+
| Realistic-1 | 8.58 KB | 145.58 µs | 1.47 ms (**10.10x**) | 17.07 ms (**117.26x**) | 28.22 ms (**193.88x**) | 52.96 ms (**363.81x**) |
177+
| Realistic-2 | 4.3 KB | 94.20 µs | 2.67 ms (**28.36x**) | ERROR | 17.95 ms (**190.59x**) | ERROR |
178+
| GitHub page | 1.81 MB | 338.88 ms | 25.58 s (**75.49x**) | ERROR | ERROR | ERROR |
179179

180180
The above data was obtained from benchmarking the inlining of CSS in HTML, as described in the Usage section.
181181
Note that the `toronado`, `inlinestyler` and `pynliner` libraries both encountered errors when used to inline CSS in the last scenario.
182182

183-
The benchmarking code is available in the `benches/bench.py` file. The benchmarks were conducted using the stable `rustc 1.71.1` on Python `3.11.4`.
183+
The benchmarking code is available in the `benches/bench.py` file. The benchmarks were conducted using the stable `rustc 1.74` on Python `3.11.6`.
184184

185185
## Comparison with other libraries
186186

bindings/ruby/README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -137,15 +137,15 @@ It consistently outperforms `premailer`, offering speed increases often exceedin
137137

138138
The table below provides a detailed comparison between `css_inline` and `premailer` when inlining CSS into an HTML document (like in the Usage section above):
139139

140-
| | Size | `css_inline 0.10.4` | `premailer 1.21.0 with Nokogiri 1.15.2` | Difference |
140+
| | Size | `css_inline 0.11.1` | `premailer 1.21.0 with Nokogiri 1.15.2` | Difference |
141141
|-------------------|---------|---------------------|------------------------------------------------|------------|
142-
| Basic usage | 230 B | 8.05 µs | 419.75 µs | **52.13x** |
143-
| Realistic email 1 | 8.58 KB | 164.22 µs | 9.75 ms | **59.40x** |
144-
| Realistic email 2 | 4.3 KB | 106.95 µs | Error: Cannot parse 0 calc((100% - 500px) / 2) | - |
142+
| Basic usage | 230 B | 8.23 µs | 415.18 µs | **50.93x** |
143+
| Realistic email 1 | 8.58 KB | 162.69 µs | 10.12 ms | **62.21x** |
144+
| Realistic email 2 | 4.3 KB | 116.01 µs | Error: Cannot parse 0 calc((100% - 500px) / 2) | - |
145145
| GitHub Page | 1.81 MB | 308.11 ms | 3.08 s | **9.99x** |
146146

147147
Please refer to the `test/bench.rb` file to review the benchmark code.
148-
The results displayed above were measured using stable `rustc 1.71.1` on Ruby `3.2.2`.
148+
The results displayed above were measured using stable `rustc 1.74.0` on Ruby `3.2.2`.
149149

150150
## Ruby support
151151

0 commit comments

Comments
 (0)