2011/4/5 Magnus Manske <[email protected]>:
> So is the time spent with the actual expansion (replacing variables),
> or getting the wikitext for n-depth template recursion? Or is it the
> parser functions?
>
Well, getting the wikitext shouldn't be very expensive as it is cached
in several cache layers. Basically it's just expanding many, many
preprocessor nodes. A while ago I did a bit of testing with my
template tool on dewiki[1] and found that wikimedia servers spend
approx. 0.2 ms per expanded node part, although there's of course much
variation depending on current load. My tool counts 303,905 nodes when
expanding [[Barack Obama]] so that would account for about 60 s of
render time. As already said, YMMV.

Paul Copperman

[1] <http://de.wikipedia.org/wiki/Benutzer:P.Copp/scripts/templateutil.js>,
you can test it with <javascript:void
importScriptURI('http://de.wikipedia.org/w/index.php?action=raw&title=Benutzer:P.Copp/scripts/templateutil.js&ctype=text/javascript')>
and a click on "Template tools" in the toolbox

_______________________________________________
Wikitech-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikitech-l

Reply via email to