[development] Strip out theme functions into a .theme file

Dries Buytaert dries.buytaert at gmail.com
Fri Aug 4 10:23:57 UTC 2006


On 03 Aug 2006, at 20:32, Jakub Suchy wrote:
>> Adrian seems to think it is not a performance issue though.
>
> Imagine you have 15 activated modules. Every module has 2 theme
> functions, which makes it 30 fopen() calls for every page load.  
> This IS
> performance issue.

There is lots of subtle trade-offs involved (eg. less PHP parsing,  
smaller memory footprint, but more fopen() calls) and it is hard to  
predict how these level out.  Let's not make claims and just  
benchmark it?

We did some preliminary benchmarks and noticed a 10% performance  
cost.  This cost was not caused by fopen() but by the way variables  
were handled.  This might be less of an issue with this patch.

It's well worth exploring this further, IMO, but rather than guessing  
we should collect factual data.

--
Dries Buytaert  ::  http://www.buytaert.net/



More information about the development mailing list