HHVM 3.20, 3.21 and 3.22 are still faster than PHP 7.2 especially with many connections under load, however as of October 2017 there still are no official pre-compiled HHVM packages for CentOS 7.x so we need to revisit how to build it by hand, which is not too difficult, just takes most servers awhile to assemble
There are instructions on the HHVM wiki for CentOS7 but they are a year out of date now.
The process is straightforward, first we need to not only make sure we have all the libraries we need but also the development libraries and most recently a newer version of the GCC compiler, we will use GCC 6.3 found in the official SCL Devtoolset-6 for CentOS 7 (trusted because it is built by Redhat/CentOS)
Very exciting to see the PHP team set the date for the PHP 7.0 final (gold) release.
Thursday November 12th – 90 days from today, mark your calendars!
It will be as if millions of servers cried out as their loads were cut in half.
The first PHP 7.0 release candidate will ship August 20th, 2015 (this coming Thursday!)
All changes to PHP 7.0 now are stabilization/fixes only (feature frozen).
In 30 days, on September 14th 2015, the PHP team will start the PHP 7.1 master trunk branch as PHP 5.4 is marked “end of life”
If you need legacy code support, be sure to read my post on how to put mysql functions back into PHP 7.0
A casual Sunday morning benchmark for August 9th 2015 using latest builds:
1000 Front Pages of WordPress (virtually stock default install) HHVM 11.99, 11.83, 11.81, 11.78, 11.85 seconds PHP7 11.18, 10.95, 10.85, 10.96, 10.88 seconds
WordPress trunk 4.3 RC2
HHVM trunk 3.9-dev
PHP trunk 7.0 RC1
(on CentOS 7)
2015 UPDATE: new wiki page for HHVM on CentOS7 with alternate instructions
While building HHVM (HipHop Virtual Machine) for faster PHP on CentOS 6.x was pretty much a nightmare because almost none of third-party libraries are available from major repositories, the freshly released CentOS 7.0 solves most of this problem as it has far newer packages available from EPEL (because it has roots in more modern Fedora 19).
Note that unlike PHP/PHPNG, HHVM requires major resources to build. You may be used to making PHP in 15 minutes on a little old 256mb 1ghz box. You can forget that with HHVM which is a beast to compile. 1gb ram minimum and lots of cpu power required to keep it an hour or two (this is part of why PHP NG instead is so exciting because it will be so much easier to custom build).
Zeev Suraski (CTO of Zend and therefore an extremely qualified authority on PHP NG) has written a fascinating article comparing the performance of PHPNG against the current HHVM versions. A must read.
Perhaps even more importantly, he has written about the current state and future of PHP NG.
correction: php core developers have urged that it is improper to call this version “5.7” (despite the versioning file stating so)
PHP 5.7 PHP NG is still in alpha development, however it is starting to show breathtaking performance improvements over 5.6 while maintaining virtually complete compatibility.
Dmitry Stogov has been hard at work since his first announcement in mid-January 2014 and milestone update in early-May to keep folding in more and more ideas to increase PHP speed (with significant contributions by Xinchen Hui, Nikita Popov and others).
Six months later in mid-July, their efforts are really bearing fruit and PHP
5.7 NG is about to become nearly 100% faster than PHP 5.6 when rendering the front page of a stock WordPress 3.6 installation:
PHP 5.6, 1000 renderings of WP front page = 26.756 seconds
PHP NG, 1000 renderings of WP front page = 14.810 seconds
Red Hat released RHEL 7 on June 10th which means the CentOS 7 community got to work, to prep their release based on the source. It is currently in “QA” release for review and will go to “GA” release (general availability) sometime in July.
The big news, at least for me, is performance improvements over CentOS 6.5
Red Hat claims 11% to 25% speed increase depending on workload:
Is that plausible from just an OS upgrade? Possibly, depending on better use of hardware and how much contention is going on. CentOS 7 will finally bring the linux 3.10 kernel to replace the 2.6.32 kernel in CentOS 6.5 – this means the elimination of the “big kernel lock” and better memory management.
7 will also bring the XFS filesystem as a default, alternative to EXT4. I am not sold on this change. I have seen a number of benchmarks that show EXT4 is faster in many cases, by a significant percent, over XFS (you can still use EXT4 of course). Apparently GRUB was also replaced with GRUB2 which is something I have to research and learn since it is critical for boot.
Initially there is no direct upgrade path for CentOS 6.5 to 7.
But they are discussing it and promise to explore after the GA release.