Add slash before native functions to speed up resolving #1129

Merged
szsz merged 5 commits from szsz/kbin-core:native-function-invocation into develop 2023-09-15 10:43:44 +00:00

Adding slash before some native functions is a microoptimization that allows the engine to inline them.
It is well explained in an article at https://php.watch/articles/php-zend-engine-special-inlined-functions
and effortlessly enforced in kbin code by change in php-cs-fixer config file

Adding slash before some native functions is a microoptimization that allows the engine to inline them. It is well explained in an article at https://php.watch/articles/php-zend-engine-special-inlined-functions and effortlessly enforced in kbin code by change in php-cs-fixer config file
szsz added 1 commit 2023-09-14 14:12:21 +00:00
Kbin CI/CD pipeline / unit-test (pull_request) Successful in 24s Details
Kbin CI/CD pipeline / build (pull_request) Successful in 40s Details
Kbin CI/CD pipeline / fixer-dry-run (pull_request) Failing after 29s Details
c78d339e0a
Add slash before native functions to speed up resolving
szsz added 1 commit 2023-09-14 14:19:19 +00:00
Kbin CI/CD pipeline / unit-test (pull_request) Successful in 22s Details
Kbin CI/CD pipeline / build (pull_request) Successful in 37s Details
Kbin CI/CD pipeline / fixer-dry-run (pull_request) Successful in 27s Details
0480bea021
Commit missing fixed files

Would like to see actual measurements before and after to be honest. Just curious.

Some benchmarking of adding a topic or a comment. And removing it again. Something like that?

Would like to see actual measurements before and after to be honest. Just curious. Some benchmarking of adding a topic or a comment. And removing it again. Something like that?
ernest approved these changes 2023-09-15 09:33:50 +00:00
szsz added 2 commits 2023-09-15 10:28:12 +00:00
540e37f373
Merge branch 'develop' into native-function-invocation
# Conflicts:
#	src/Repository/EntryRepository.php
Kbin CI/CD pipeline / unit-test (pull_request) Successful in 27s Details
Kbin CI/CD pipeline / build (pull_request) Successful in 39s Details
Kbin CI/CD pipeline / fixer-dry-run (pull_request) Failing after 33s Details
e333e3977d
Re-run fixer
Poster
Owner

Would like to see actual measurements before and after to be honest. Just curious.

Some benchmarking of adding a topic or a comment. And removing it again. Something like that?

The difference will of course be very small, but since its done automatically and doesn't hurt readability of code I'd say its worth it.
The actual benchmarks of this change are available for example at https://veewee.github.io/blog/optimizing-php-performance-by-fq-function-calls/

> Would like to see actual measurements before and after to be honest. Just curious. > > Some benchmarking of adding a topic or a comment. And removing it again. Something like that? The difference will of course be very small, but since its done automatically and doesn't hurt readability of code I'd say its worth it. The actual benchmarks of this change are available for example at https://veewee.github.io/blog/optimizing-php-performance-by-fq-function-calls/
szsz added 1 commit 2023-09-15 10:41:41 +00:00
Kbin CI/CD pipeline / unit-test (pull_request) Successful in 23s Details
Kbin CI/CD pipeline / build (pull_request) Successful in 39s Details
Kbin CI/CD pipeline / fixer-dry-run (pull_request) Successful in 32s Details
44f2c62d56
Add missing fix
szsz merged commit cc727b9133 into develop 2023-09-15 10:43:44 +00:00
szsz deleted branch native-function-invocation 2023-09-15 10:43:45 +00:00
Sign in to join this conversation.
No reviewers
No Milestone
No project
No Assignees
3 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: Kbin/kbin-core#1129
There is no content yet.