codeigniter4 / CodeIgniter4

Open Source PHP Framework (originally from EllisLab)
https://codeigniter.com/
MIT License
5.4k stars 1.9k forks source link

CI4 performance regression #6889

Open joanhey opened 2 years ago

joanhey commented 2 years ago

PHP Version

8.1

CodeIgniter4 Version

4.2.10

CodeIgniter4 Installation Method

Composer (as dependency to an existing project)

Which operating systems have you tested for this bug?

Linux

Which server did you use?

fpm-fcgi

Database

MySQL 8

What happened?

After update to CI4 in the TechEmpower bench.

CI3 PHP 8.1 vs CI4 PHP8.1 (with JIT) Req/s Framework JSON 1-query 20-query Fortunes Updates Plaintext
CI3 26,313 25,189 12,049 24,358 -- 25,646
CI4 5,746 5,314 4,244 5,320 2,086 5,791

Please, could anybody review the code in the bench.

If after review the code, still get this performance, exist another problem.

Thank you

Steps to Reproduce

https://tfb-status.techempower.com/

I can help, only ask me.

Expected Output

Similar or higher numbers than CI3. Not 5 times slower.

Anything else?

PR that update to CI4: https://github.com/TechEmpower/FrameworkBenchmarks/pull/7686

Final code to review: https://github.com/TechEmpower/FrameworkBenchmarks/tree/master/frameworks/PHP/codeigniter

Previous code with CI3: https://github.com/TechEmpower/FrameworkBenchmarks/tree/e062401d0dbc660ed2e7c969ddbcc84e66ae5824/frameworks/PHP/codeigniter

When finish the run, I'll send the logs.