![]() ![]() PHP 8.0 has many other innovations to offer, a small selection of which is listed below: The innovations make the code more flexible and also make it possible to write clean code. Here, the order does not have to be considered and optional parameters can be skipped. Now values can be passed to a function by specifying values. Previously, this was only possible via an order. “Named Arguments” also called "named parameters" now allow parameters to be passed to a function based on the parameter name. ![]() Feel free to share your experiences with us - just write an email to We will then include them in our blog article updates. The extent to which the new JIT compiler can actually keep its promise regarding more performance will therefore only become clear in the next few weeks, when more tests have been made with the live version. Brent comes to the conclusion that no performance increase of more than 10 % can be expected for web requests. And the PHP developer Brent has also carried out some tests before the release of the current software. On gitconnected there is another performance test by Pedro Escudero. Performance improvement of PHP 8.0 (with and without JIT compiler) compared to previous PHP versions Whether only frequently used functions or all functions are translated into machine code with the JIT compiler depends on the "opcache.jit" setting.īut does this feature really make applications faster? Phoronix already conducted initial tests in June and determined a performance increase of 7% when switching from PHP 7.4 to PHP 8.0 (Git, Alpha 1) and a more than 50% increase when using PHP 8.0 with JIT compiler compared to PHP 8.0 without JIT compiler: Instead of the actual PHP bytecode, this is then executed directly. The JIT compiler goes one step further here, as it has a function that translates the code in places - during runtime, always "just in time" - into native assembly code. So far, this has already been accelerated by the PHP Opcache, which translates and caches the human-readable PHP code into a machine-readable bytecode. What is a JIT compiler or what does it do? Since PHP is an interpreted language, the code is not compiled but interpreted line by line during runtime. Below are some selected functions and improvements that contribute to this (a complete overview of the implemented features can be found here). New features and improvementsĪll reports in the run-up to the PHP 8.0 release agreed: The new version will be faster and more secure. ![]() If you need a refresher on your PHP programming skills, the following PHP tutorial or the course platform might help you. You can find a list of all changes here: and the official documentation here. Please note that you may have to make adjustments to the code due to the improvements in PHP 8.0. Keeping your website's code up to date and always using new versions of PHP has its advantages: New features not only offer greater variety, but allow for improvements in performance and security issues are fixed. However, many websites written with PHP are still using an old version that will (probably) soon no longer be supported. However, this should cause fewer problems if you have always kept your PHP version up to date. The new version PHP 8.0Īs the version number shows, this time it is a major release, which implies some changes that may not be downward compatible. We have summarised this information in the blog post - and will update it continuously over the next few weeks.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |