@@ -29,15 +29,16 @@ Benchmarking on components like template engines or ORM/Database libraries is ou
2929
3030#### Environment
3131
32- * Ubuntu 22.04 LTS 64bit
33- * PHP 8.1.6
34- * OPCache enabled
32+ * Ubuntu 22.04 LTS x86_64
33+ * PHP 8.2.5
34+ * OPCache Off
3535 * Apache 2.4.52
36- * CPU Core i7 2600K@4Ghz
36+ * WRK 4.2.0
37+ 3738 * Memory 16G
3839
3940
40- #### Results (2022 /5/22 )
41+ #### Results (2023 /5/15 )
4142
4243These are my benchmarks, not yours. ** I encourage you to run on your (production equivalent) environments.**
4344
@@ -46,28 +47,29 @@ These are my benchmarks, not yours. **I encourage you to run on your (production
4647![ Benchmark Results Graph Execution Time] ( screenshots/php-frameworks-bench-exectime.png )
4748![ Benchmark Results Graph Included Files] ( screenshots/php-frameworks-bench-includedfiles.png )
4849
49- | framework | requests per second| relative| peak memory| relative|
50- | -------------------| ------------------:| -------:| ----------:| -------:|
51- | pure-php | 42,114.24| 52.1| 0.34| 1.0|
52- | phroute-2.2 | 33,424.47| 42.4| 0.34| 1.0|
53- | fastroute-1.3 | 33,190.14| 42.1| 0.34| 1.0|
54- | siler-1.7.9 | 22,152.74| 28.8| 0.36| 1.1|
55- | leaf-3.0 | 20,685.10| 26.3| 0.36| 1.1|
56- | fatfree-3.8.0 | 19,282.52| 24.5| 0.39| 1.1|
57- | frameworkx-dev | 18,033.22| 22.9| 0.37| 1.1|
58- | slim-4.10 | 14,958.27| 19.0| 0.38| 1.1|
59- | slim-3.12 | 14,714.84| 18.7| 0.39| 1.1|
60- | yii-2.0-basic | 11,831.91| 15.0| 0.70| 2.1|
61- | ubiquity-2.4.x.dev | 11,669.47| 14.8| 0.38| 1.1|
62- | silex-2.3 | 10,415.74| 13.2| 0.39| 1.1|
63- | symfony-5.4 | 9,761.44| 12.4| 0.46| 1.4|
64- | symfony-6.0 | 9,737.48| 12.4| 0.45| 1.3|
65- | lumen-9.0 | 6,205.79| 7.7| 0.39| 1.1|
66- | cakephp-4.3 | 5,562.91| 7.0| 0.43| 1.3|
67- | laminas-2.0.x.dev | 5,015.71| 6.4| 0.49| 1.4|
68- | fuelphp-1.9 | 4,894.22| 6.2| 0.45| 1.3|
69- | codeigniter-4.1 | 1,938.43| 2.5| 1.46| 4.3|
70- | laravel-9.1 | 788.76| 1.0| 0.55| 1.6|
50+ | framework | requests per second (rps)| relative (rps)| peak memory| relative (mem)|
51+ | -------------------| ------------------------:| -------------:| ----------:| -------------:|
52+ | pure-php | 27,379.94| 27,379.9| 0.42| 0.4|
53+ | fastroute-1.3 | 4,591.01| 4,591.0| 0.56| 0.6|
54+ | phroute-2.2 | 4,303.07| 4,303.1| 0.58| 0.6|
55+ | leaf-3.3 | 1,576.68| 1,576.7| 1.10| 1.1|
56+ | fatfree-3.8.1 | 1,512.30| 1,512.3| 1.67| 1.7|
57+ | siler-1.7.9 | 1,416.80| 1,416.8| 1.17| 1.2|
58+ | slim-3.12 | 1,061.05| 1,061.1| 1.40| 1.4|
59+ | frameworkx-dev | 994.55| 994.6| 1.45| 1.5|
60+ | slim-4.11 | 805.51| 805.5| 1.57| 1.6|
61+ | ubiquity-2.4.x.dev | 726.70| 726.7| 1.64| 1.6|
62+ | silex-2.3 | 558.07| 558.1| 2.16| 2.2|
63+ | yii-2.0-basic | 508.32| 508.3| 2.57| 2.6|
64+ | fuelphp-1.9 | 450.65| 450.7| 2.51| 2.5|
65+ | lumen-10.0 | 352.94| 352.9| 3.49| 3.5|
66+ | codeigniter-4.3 | 324.27| 324.3| 3.50| 3.5|
67+ | symfony-5.4 | 319.55| 319.6| 3.82| 3.8|
68+ | symfony-6.2 | 314.21| 314.2| 3.89| 3.9|
69+ | laminas-2.0 | 309.30| 309.3| 3.50| 3.5|
70+ | cakephp-4.4 | 262.25| 262.3| 4.49| 4.5|
71+ | laravel-10.0 | 96.97| 97.0| 11.99| 12.0|
72+
7173
7274
7375## Benchmarking Policy
@@ -94,13 +96,14 @@ If you want to have benchmarks on `PHP extension frameworks` like Phalcon, you n
94961- Download & Setup:
9597
9698``` bash
97- # you can put --branch vx.x
99+ # ... --branch vx.x
98100$ git clone https://github.com/myaaghubi/PHP-Frameworks-Bench.git
99101
100102$ cd PHP-Frameworks-Bench
101103
102104# run the setup & follow the progress
103105# check out benchmark.config
106+ # yes | bash setup.sh
104107$ bash setup.sh
105108```
106109
@@ -120,8 +123,14 @@ $ bash benchmark.sh
120123```
121124
1221254- Check the resuts:
126+ - web:
127+
128+ < http://localhost/PHP-Frameworks-Bench/ >
123129
124- < http://localhost/PHP-Frameworks-Bench/ >
130+ - command:
131+ ```
132+ bash show-table.sh
133+ ```
125134
126135
127136## Commands
@@ -132,7 +141,7 @@ $ bash update.sh
132141
133142# to clean them all
134143# trouble? run it then
135- # you can use setup.sh again
144+ # you can use `bash setup.sh` again
136145$ bash clean.sh
137146
138147# clear the cache of frameworks
@@ -147,7 +156,7 @@ To specify the frameworks, put them with `-t ...` after each command:
147156``` bash
148157# supported for `setup.sh`, `benchmark.sh`, `update.sh`, `clean.sh`, and `clear-cache.sh`
149158# bash benchmarks.sh --help -h
150- $ bash benchmark.sh -t laravel-9.1 / slim-4.10/ fatfree-3.8.0 / ...
159+ $ bash benchmark.sh -t laravel-10.0 / slim-4.11 / ...
151160...
152161```
153162
0 commit comments