SymfonyのPHP8.0および7.4ベンチマーク:OPCacheプリロードとともに最大+ 9%のJITパフォーマンスの向上

「SymfonyFramework」コースの将来の学生と、「Microframes:Comparing Symfony andSymlexPerformance」というトピックに関するオープンウェビナーにサインアップすることに関心のあるすべての人招待します



役立つ記事の翻訳も共有しています。










PHP 8.0は2020年11月26日にリリースされ、まもなく最新バージョンのSymfony5.2がリリースされます。これは、両方のプロジェクトの最新バージョンで実行された一連のベンチマークです。これは純粋なハローワールドのシナリオであり、そのように解釈する必要があります。相対的なパフォーマンスのみが重要です。YMMVの現実の世界では(結果はこれらとは異なる場合があります)。





1: JIT PHP 8.0, . , !





2: PHP 8.0.0 Symfony 5.2.0 . , , .





PHP 8.0-RC5 Symfony 5.2-RC2. , , . Hetzner Helsinki CCX11 (2 , 8 ), , . Ubuntu 20.20 PHP, .





Symfony 5.2 . HTML 100 999. (1, 10, 25, 50, 100) .





PHP-FPM Nginx:





  • PHP 7.4 OPCache





  • PHP 7.4 OPCache





  • PHP 8.0 OPCache





  • PHP 8.0 OPCache





  • PHP 8.0 OPCache JIT 





OPCache - OPCache:





opcache.preload_user=www-data
opcache.memory_consumption=1024
opcache.interned_strings_buffer=256
opcache.max_accelerated_files=30000
opcache.validate_timestamps=0

# only when OPCache Preloading was enabled
opcache.preload=/var/www/php80/var/cache/prod/App_KernelProdContainer.preload.php

# only when JIT was enabled
opcache.jit_buffer_size=512mb
opcache.jit=1225
      
      



hey, (req/s) (). , .





, PHP 7.4, 8.0 OPCache. PHP 7.4 , . , , 10 100 , PHP 8.0 JIT, , , 7.4 OPCache, 25+ .





, . OPCache , PHP 7.4 8.0. ( , ) PHP 8.0 , 7.4, . , 10 100. 8.0 JIT : , .





, Symfony, PHP 8.0 7.4. , , JIT PHP 8.0, PHP 7.0, , .





, JIT , OPCache. , , . , JIT PHP.





, 7.4 8.0 . , PHP 7.3 7.4 OPCache. , PHP 8.0 . . , , ( 4.4 PHP 5.0 2004 ). 8.x.





Discourse: PHP 8.0 7.4






"Symfony Framework".



": Symfony Symlex".





OTUS . .   OTUS.





, " " -   .












All Articles