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

Utility Class Optimizations #1311

Open
mariuswilms opened this issue Apr 11, 2017 · 0 comments
Open

Utility Class Optimizations #1311

mariuswilms opened this issue Apr 11, 2017 · 0 comments

Comments

@mariuswilms
Copy link
Member

mariuswilms commented Apr 11, 2017

The following bullet points identify areas for optimizing utility classes. This include removal of seldom used features (which presence at the same time also hurts performance) as well as pure performance optimizations.

Utility classes are special in that they are used across the entire framework. This makes them an important target for optimization efforts.

  • Use array_column() when possible in Set::extract(). extract() is one of the hot methods and using native functions is generally faster. If we need to make extract() less feature-rich to make this work, than we are ready to compromise.
  • Deprecate try/catch block in String::insert(), silencing exceptions is bad practice and also hurts performance when done in that loop. aeb1009
  • Deprecate non-flatten mode in Set::extract(), there is just one assertion for it and not used anywhere inside core. 063612f
  • Deprecate ? mode in Text::insert(), replace usage in data/source by prepared statements, then check it's not used anywhere else.
@mariuswilms mariuswilms changed the title Utility Class Optimization Utility Class Optimizations Apr 11, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant