Jump to content

Template talk:Regional articles

Page contents not supported in other languages.
From Wikipedia, the free encyclopedia

Expensive code

[edit]

Why is this template so slow (4 seconds of CPU time usage)?

Under “Parser profiling data” (in the edit preview window) I get:

Parser profiling data
CPU time usage 4.418 seconds
Real time usage 6.248 seconds
Preprocessor visited node count 54,913/1,000,000
Post-expand include size 340,301/2,097,152 bytes
Template argument size 100,932/2,097,152 bytes
Highest expansion depth 37/100
Expensive parser function count 116/500
Unstrip recursion depth 0/20
Unstrip post-expand size 25,618/5,000,000 bytes
Lua time usage 4.221/10.000 seconds
Lua memory usage 6,291,921/52,428,800 bytes
Lua Profile
?   2100 ms 49.8%
recursiveClone <mwInit.lua:45> 600 ms 14.2%
MediaWiki\Extension\Scribunto\Engines\LuaSandbox\LuaSandboxCallback::getEntityId   580 ms 13.7%
MediaWiki\Extension\Scribunto\Engines\LuaSandbox\LuaSandboxCallback::getExpandedArgument   320 ms 7.6%
MediaWiki\Extension\Scribunto\Engines\LuaSandbox\LuaSandboxCallback::getContent   100 ms 2.4%
(for generator)   100 ms 2.4%
MediaWiki\Extension\Scribunto\Engines\LuaSandbox\LuaSandboxCallback::sub   60 ms 1.4%
MediaWiki\Extension\Scribunto\Engines\LuaSandbox\LuaSandboxCallback::callParserFunction   60 ms 1.4%
tostring   40 ms 0.9%
insert   40 ms 0.9%
[others]   220 ms 5.2%
Number of Wikibase entities loaded 28

--Grufo (talk) 07:30, 1 October 2024 (UTC)[reply]