Closed 94noni closed 1 year ago
With Symfony v6.1 which requires PHP v8.1, I have understood it is no more relevant
I didn't found a clear explanation but Symfony members wrote this:
But then, preloading itself is going to be almost useless as of PHP 8.1.
Source: https://symfony.com/blog/symfony-6-1-will-require-php-8-1
preloading is also mostly dead since 8.1
https://github.com/symfony/symfony/pull/44380#pullrequestreview-819949886
can you please help here @nicolas-grekas ? Thank you
Preloading gives 2 benefits:
With PHP 8.1, the second benefit is almost gone because of a newly introduced inheritance cache that also has to do with signature compatibility checks, see this benchmark: https://github.com/php/php-src/pull/6627#issuecomment-775869140
Benefit number 1 still stands though, but depending on the application, it may or may not be dwarfed by other things. On my applications, which are very few, I haven't been able to witness a significant impact from preloading. Would be nice to have benchmark from other people on other apps.
closing as related code PR was closed
What about removing this part: https://symfony.com/doc/6.1/performance.html#use-the-opcache-class-preloading
With Symfony v6.1 which requires PHP v8.1, I have understood it is no more relevant