Skip to content
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

Use spl_object_id() instead of spl_object_hash() #1180

Merged
merged 1 commit into from Jan 14, 2020

Conversation

@Toflar
Copy link
Member

Toflar commented Jan 14, 2020

Now that we require at least PHP 7.2 we can use spl_object_id() instead of spl_object_hash() which is faster and requires a lot less memory.

https://3v4l.org/WCYb8/perf#output
https://3v4l.org/I4mEg/perf#output

@Toflar Toflar added the feature label Jan 14, 2020
@Toflar Toflar added this to the 4.9 milestone Jan 14, 2020
@Toflar Toflar requested review from aschempp and leofeyer Jan 14, 2020
@Toflar Toflar self-assigned this Jan 14, 2020
@leofeyer leofeyer merged commit ce47fcb into master Jan 14, 2020
9 checks passed
9 checks passed
Coverage
Details
Coding Style
Details
PHP 7.2
Details
PHP 7.3
Details
PHP 7.4
Details
Prefer Lowest
Details
Bundles
Details
Windows
Details
codecov/project 89.72% remains the same compared to 735df94
Details
@leofeyer leofeyer deleted the feature/perf-improvement branch Jan 14, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.