Skip to content

Faster analysis with a big const array in a class #3862

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Mar 9, 2025

Conversation

staabm
Copy link
Contributor

@staabm staabm commented Mar 9, 2025

closes phpstan/phpstan#12159

before this PR

➜  phpstan-src git:(2.1.x) ✗ time php bin/phpstan analyze bug12159.php --debug 
....                                                       

php bin/phpstan analyze bug12159.php --debug  24.02s user 0.19s system 99% cpu 24.217 total

after this PR

➜  phpstan-src git:(perf) ✗ time php bin/phpstan analyze bug12159.php --debug 
...                                                                     
                                                                                                                        
php bin/phpstan analyze bug12159.php --debug  0.52s user 0.11s system 99% cpu 0.632 total

@staabm
Copy link
Contributor Author

staabm commented Mar 9, 2025

//cc @xPaw

@staabm staabm marked this pull request as ready for review March 9, 2025 07:25
@phpstan-bot
Copy link
Collaborator

This pull request has been marked as ready for review.

@ondrejmirtes ondrejmirtes merged commit 843be53 into phpstan:2.1.x Mar 9, 2025
412 of 418 checks passed
@ondrejmirtes
Copy link
Member

Thank you.

@staabm staabm deleted the perf branch March 9, 2025 07:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Slow analysis with a big const array in a class
3 participants