How Much Faster Is PHP 8.1? In‑Depth Benchmark Results Across Versions
An extensive Phoronix benchmark on Ubuntu‑based AMD EPYC servers compares PHP 8.1 with earlier releases, revealing roughly 4 % speed gains over PHP 8.0, lower peak memory usage, and consistent performance improvements across micro‑benchmarks, XML parsing, and JSON generation.
Read: PHP 8.1 was officially released last week, and tech media Phoronix subsequently published a performance benchmark report for PHP 8.1.
The tests were run on an Ubuntu Linux server equipped with an AMD EPYC 72F3 CPU.
All tested PHP versions were rebuilt on the same system using identical packages and build options. Versions compared include PHP 8.1, PHP 8.0.13, PHP 7.4.26, PHP 7.3.33, PHP 7.0.33 and PHP 5.6.40. PHP 7.1 and 7.2 were excluded due to build/runtime errors.
The benchmark results are illustrated in the following graphs:
The data shows that since PHP 5.6 the language has made steady progress. Building on the stability improvements of the 7.x series, PHP 8.1 adds roughly another 4 % performance boost over PHP 8.0.
Micro‑benchmark tests (e.g., XML parsing, JSON generation) also demonstrate noticeable gains, especially when moving from PHP 7.3 to PHP 8.0, with PHP 8.1 delivering a solid improvement.
Rendering tests confirm that PHP 8.1 continues the positive performance trend.
Notably, PHP 8.1’s peak memory usage is slightly lower than previous versions, making it a strong step forward for server‑side programming.
Overall, PHP 8.1 introduces useful language features and incremental performance improvements that enhance its competitiveness against other scripting languages.
User feedback:
“PHP has evolved into a modern, excellent programming language. It has addressed many past criticisms and only lacks generics, generic properties, and async/await.”
“I find PHP traits odd and think they add unnecessary glue; using dependency inversion with constructor injection would be a cleaner solution.”
Signed-in readers can open the original source through BestHub's protected redirect.
This article has been distilled and summarized from source material, then republished for learning and reference. If you believe it infringes your rights, please contactand we will review it promptly.
21CTO
21CTO (21CTO.com) offers developers community, training, and services, making it your go‑to learning and service platform.
How this landed with the community
Was this worth your time?
0 Comments
Thoughtful readers leave field notes, pushback, and hard-won operational detail here.
