Page MenuHomePhabricator

ResourceLoader::register() called for page views
Closed, ResolvedPublic

Description

It seems register() is called in cases where it's not needed. Domas showed me a profile of Special:Blankpage where register() is called 106 times, that's excessive.


Version: unspecified
Severity: normal

Details

Reference
bz29013

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 21 2014, 11:34 PM
bzimport set Reference to bz29013.

I'm going to profile the unit tests, fwiw, in the process of getting them to run faster. MOAR PROFILING!!!

I made register() non-recursive in r103682, that reduces the number of calls and hopefully makes things faster.

(In reply to comment #2)

I made register() non-recursive in r103682, that reduces the number of calls
and hopefully makes things faster.

That did indeed make register() take 8x less time on the live site.

Since we can't actually avoid initializing RL on page views, I'm gonna close this bug.