rCSSmin - Benchmark

The following numbers have been measured with the bench package provided in the source distribution. Since the numbers don’t vary much between python minor releases (e.g. 3.3 vs 3.4), only one benchmark per major version is given below. The docs/BENCHMARKS file in the source distribution contains a more comprehensive list.

Here’s the list of benchmarked implementations:

YUI Port

YUI port by Zachary Voase

rCSSmin

this very project

_rCSSmin

The C reimplementation of rCSSmin

And here’s a list of the benchmarked CSS files:

  • wikipedia.css / wikipedia.min.css

  • bootstrap.css / bootstrap.min.css (3.4.1)

Inside the parentheses are size information in KiB 1. The sign behind the size value denotes the size difference in relation to the YUI port (i.e. cssmin).

1

Bytes / 1024 for Python 2 and Code Points / 1024 for Python 3

Python 3.10.0

Name

bootstrap (142.5)

bootstrap.min (118.6)

YUI Port

1113.70 ms (118.8 *)

1000.29 ms (118.5 *)

rCSSmin

32.29 ms (119.2 >)

14.71 ms (118.6 >)

_rCSSmin

0.48 ms (119.2 >)

0.34 ms (118.6 >)

Name

wikipedia (81.0)

wikipedia.min (49.4)

YUI Port

67.18 ms (49.4 *)

52.86 ms (49.4 *)

rCSSmin

14.57 ms (49.6 >)

7.32 ms (49.4 =)

_rCSSmin

0.28 ms (49.6 >)

0.18 ms (49.4 =)

Python 2.7.18

Name

bootstrap (142.5)

bootstrap.min (118.6)

YUI Port

1078.57 ms (118.8 *)

970.64 ms (118.5 *)

rCSSmin

29.73 ms (119.2 >)

12.66 ms (118.6 >)

_rCSSmin

0.47 ms (119.2 >)

0.33 ms (118.6 >)

Name

wikipedia (81.0)

wikipedia.min (49.4)

YUI Port

62.44 ms (49.4 *)

50.57 ms (49.4 *)

rCSSmin

12.87 ms (49.6 >)

6.16 ms (49.4 =)

_rCSSmin

0.24 ms (49.6 >)

0.15 ms (49.4 =)