Quantcast
Channel: Issues for Drupal core
Viewing all articles
Browse latest Browse all 295382

Cache module_implements()

$
0
0

As follow-ups to #497118: Remove the registry (for functions), we should introduce back some modest memory and function call optimizations.

The elements are 2-fold:

  1. allow hook implementations to live in a single .inc file per module. This would be for info-type hooks like hook_menu() or hook_theme() that are only called rarely. E.g. modulename.hooks.inc
  2. Change functions like module_invoke_all() so that we cache a list of modules the implement certain hooks (and possibly whether the implementation is in the new .inc file). This would let us avoid doing a file_exists() + require_once for every hook invocation which the first element alone would need, plus make all such invocations more efficient.

Viewing all articles
Browse latest Browse all 295382

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>