PHP 8.1: real-life performance benchmarks
I did a very quick performance test because I wanted to know the impact of PHP 8.1 on my real-life projects.
These benchmarks were taken on my local machine, and only meant to measure the relative difference between PHP 8.0 and 8.1. I benchmarked a page that showed lots of data, with lots of classes loaded, as I expected that inheritance cache would have the largest performance impact.
|Metric||PHP 8.0||PHP 8.1|
|Requests per second (#/sec)||32.02||34.75|
|Time per request (ms)||31.232||28.777|
The results seem to be in line what what Dmitry originally reported when he added this feature: a 5-8% performance increase.