Manual:$wgDebugProfiling

Details
Detects non-matching wfProfileIn/wfProfileOut calls.