the preprocess method can be called many times during a page build, meaning that separately generating the theme information each time it is called gets expensive.

Members fund testing for the Drupal project. Drupal Association Learn more


acrollet created an issue. See original summary.

acrollet’s picture

Status: Active » Needs review
1.63 KB

patch attached for review.

acrollet’s picture

Issue tags: +Performance
acrollet’s picture

Forgot to mention figures, reduced page load times by an average of .30s (out of roughly 3)

sylus’s picture

This looks great as another performance improvement ^_^, I also gave the patch a go and attached a profile comparison before and after the patch with a drush cr before each page load.

markcarver’s picture

Status: Needs review » Postponed
markcarver’s picture

Assigned: Unassigned » markcarver
Status: Postponed » Needs work

Same with this one.

markcarver’s picture

Title: theme context generation in Bootstrap::preprocess() is expensive » Bootstrap::preprocess() theme context generation is expensive
markcarver’s picture

Assigned: markcarver » Unassigned
Status: Needs work » Fixed
3.61 KB

  • markcarver committed 43c1c4f on 8.x-3.x
    Issue #2905747 by markcarver, acrollet, sylus: Bootstrap::preprocess()...

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.