MediaWiki  REL1_23
Profiler.php File Reference

Base class and functions for profiling. More...

Go to the source code of this file.

Classes

class  Profiler
class  ProfileSection
 Class for handling function-scope profiling. More...

Functions

 wfProfileIn ($functionname)
 Begin profiling of a function.
 wfProfileOut ($functionname= 'missing')
 Stop profiling of a function.

Detailed Description

Base class and functions for profiling.

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. http://www.gnu.org/copyleft/gpl.html

This file is only included if profiling is enabled

Definition in file Profiler.php.


Function Documentation

wfProfileIn ( functionname)

Begin profiling of a function.

Parameters:
string$functionnamename of the function we will profile

Definition at line 33 of file Profiler.php.

References Profiler\$__instance, and Profiler\instance().

Referenced by StubObject\_unstub(), LinkCache\addLinkObj(), WatchedItem\addWatch(), Parser\argSubstitution(), SkinTemplate\buildContentActionUrls(), SkinTemplate\buildContentNavigationUrls(), ChangesFeed\buildItems(), SkinTemplate\buildNavUrls(), SkinTemplate\buildPersonalUrls(), Skin\buildSidebar(), Profiler\calculateOverhead(), TableDiffFormatter\changed(), UploadBase\checkWarnings(), WordLevelDiff\closing(), ViewCountUpdate\collect(), LanguageKk\convertGrammar(), UploadBase\detectScript(), UploadBase\detectVirus(), Parser\doHeadings(), UserCache\doQuery(), LinkBatch\doQuery(), DjVuHandler\doTransform(), DeferredUpdates\doUpdates(), Xml\elementClean(), RunJobs\execute(), CurlHttpRequest\execute(), PhpHttpRequest\execute(), LinkBatch\executeInto(), SpecialRunJobs\executeJobs(), SpecialPageFactory\executePath(), Linker\formatComment(), FeedUtils\formatDiffRow(), Linker\formatHiddenCategories(), SpecialProtectedtitles\formatRow(), Linker\formatTemplates(), CoreParserFunctions\gender(), ChangesFeed\generateFeed(), MessageBlobStore\get(), MemcachedPeclBagOStuff\get(), ParserCache\get(), JobQueueAggregator\getAllReadyWikiQueues(), Skin\getCachedNotice(), Title\getCascadeProtectionSources(), CreditsAction\getCredits(), ResourceLoaderModule\getDefinitionMtime(), User\getEditCount(), Title\getLinkURL(), SpecialPageFactory\getList(), DjVuHandler\getMetaTree(), ResourceLoaderFileModule\getModifiedTime(), ResourceLoaderStartUpModule\getModuleRegistrations(), MemcachedPeclBagOStuff\getMulti(), Skin\getNamespaceNotice(), Title\getPageLanguage(), UploadBase\getRealPath(), Skin\getSiteNotice(), Skin\getSkinNames(), ProtectedTitlesPager\getStartBody(), MergeHistoryPager\getStartBody(), ApiTokens\getTokenTypes(), BaseTemplate\getToolbox(), Title\getUserPermissionsErrorsInternal(), SpecialVersion\getVersion(), SpecialVersion\getVersionLinked(), SearchHighlighter\highlightSimple(), SearchHighlighter\highlightText(), Skin\initPage(), Linker\link(), Linker\linkAttribs(), Linker\linkUrl(), MagicWord\load(), MediaWiki\main(), Linker\makeBrokenImageLinkObj(), LinkHolderArray\makeHolder(), Linker\makeKnownLinkObj(), Linker\makeLinkObj(), LanguageBe_tarask\normalizeForSearch(), LanguageYue\normalizeForSearch(), LanguageZh_hans\normalizeForSearch(), LanguageZh\normalizeForSearch(), Linker\normalizeSubpageLink(), SearchMySQL\normalizeText(), JobQueueAggregator\notifyQueueEmpty(), JobQueueAggregator\notifyQueueNonEmpty(), WatchAction\onSubmit(), UnwatchAction\onSubmit(), CreditsAction\onView(), WordLevelDiff\orig(), SkinTemplate\outputPage(), InfoAction\pageCounts(), SiteStats\pagesInNs(), UploadBase\performUpload(), SkinTemplate\prepareQuickTemplate(), BlockListPager\preprocessResults(), ApiBase\profileDBIn(), ApiBase\profileIn(), JobQueueAggregator\purge(), LocalFile\purgeOldThumbnails(), BacklinkCache\queryLinks(), SvgHandler\rasterize(), MWCryptRand\realGenerate(), OldChangesList\recentChangesLine(), Parser\recursivePreprocess(), Sanitizer\removeHTMLcomments(), Sanitizer\removeHTMLtags(), WatchedItem\removeWatch(), SearchHighlighter\removeWiki(), LinkHolderArray\replace(), ReplacementArray\replace(), LinkHolderArray\replaceInternal(), LinkHolderArray\replaceInterwiki(), WikitextContent\replaceSection(), LinkHolderArray\replaceText(), Http\request(), DjVuImage\retrieveMetaData(), JpegHandler\rotate(), BitmapHandler\rotate(), Hooks\run(), PrefixSearch\searchWithVariants(), SkinTemplate\setupTemplateForOutput(), UploadBase\stashFile(), StreamFile\stream(), BitmapHandler\transformCustom(), BitmapHandler\transformImageMagick(), MediaWiki_I18N\translate(), StripState\unstripType(), WikiPage\updateIfNewerOn(), UploadBase\verifyFile(), UploadBase\verifyMimeType(), UploadBase\verifyPartialFile(), UploadBase\verifyUpload(), wfIsBadImage(), and wfMsgReal().

wfProfileOut ( functionname = 'missing')

Stop profiling of a function.

Parameters:
string$functionnamename of the function we have profiled

Definition at line 46 of file Profiler.php.

References Profiler\$__instance, and Profiler\instance().

Referenced by StubObject\_unstub(), LinkCache\addLinkObj(), WatchedItem\addWatch(), Parser\argSubstitution(), SkinTemplate\buildContentActionUrls(), SkinTemplate\buildContentNavigationUrls(), ChangesFeed\buildItems(), SkinTemplate\buildNavUrls(), SkinTemplate\buildPersonalUrls(), Skin\buildSidebar(), Profiler\calculateOverhead(), TableDiffFormatter\changed(), UploadBase\checkWarnings(), WordLevelDiff\closing(), ViewCountUpdate\collect(), LanguageKk\convertGrammar(), UploadBase\detectScript(), UploadBase\detectVirus(), Parser\doHeadings(), UserCache\doQuery(), LinkBatch\doQuery(), DjVuHandler\doTransform(), DeferredUpdates\doUpdates(), Xml\elementClean(), RunJobs\execute(), CurlHttpRequest\execute(), PhpHttpRequest\execute(), LinkBatch\executeInto(), SpecialRunJobs\executeJobs(), SpecialPageFactory\executePath(), Linker\formatComment(), FeedUtils\formatDiffRow(), SpecialProtectedtitles\formatRow(), Linker\formatTemplates(), CoreParserFunctions\gender(), ChangesFeed\generateFeed(), MessageBlobStore\get(), MemcachedPeclBagOStuff\get(), ParserCache\get(), JobQueueAggregator\getAllReadyWikiQueues(), Skin\getCachedNotice(), Title\getCascadeProtectionSources(), CreditsAction\getCredits(), ResourceLoaderModule\getDefinitionMtime(), User\getEditCount(), Title\getLinkURL(), SpecialPageFactory\getList(), DjVuHandler\getMetaTree(), ResourceLoaderFileModule\getModifiedTime(), ResourceLoaderStartUpModule\getModuleRegistrations(), MemcachedPeclBagOStuff\getMulti(), Skin\getNamespaceNotice(), Title\getPageLanguage(), UploadBase\getRealPath(), Skin\getSiteNotice(), Skin\getSkinNames(), ProtectedTitlesPager\getStartBody(), MergeHistoryPager\getStartBody(), ApiTokens\getTokenTypes(), BaseTemplate\getToolbox(), Title\getUserPermissionsErrorsInternal(), SpecialVersion\getVersion(), SpecialVersion\getVersionLinked(), SearchHighlighter\highlightSimple(), SearchHighlighter\highlightText(), Skin\initPage(), Linker\link(), Linker\linkAttribs(), Linker\linkUrl(), MagicWord\load(), MediaWiki\main(), Linker\makeBrokenImageLinkObj(), LinkHolderArray\makeHolder(), Linker\makeKnownLinkObj(), Linker\makeLinkObj(), LanguageBe_tarask\normalizeForSearch(), LanguageYue\normalizeForSearch(), LanguageZh_hans\normalizeForSearch(), LanguageZh\normalizeForSearch(), Linker\normalizeSubpageLink(), SearchMySQL\normalizeText(), JobQueueAggregator\notifyQueueEmpty(), JobQueueAggregator\notifyQueueNonEmpty(), WatchAction\onSubmit(), UnwatchAction\onSubmit(), CreditsAction\onView(), WordLevelDiff\orig(), SkinTemplate\outputPage(), InfoAction\pageCounts(), SiteStats\pagesInNs(), UploadBase\performUpload(), SkinTemplate\prepareQuickTemplate(), BlockListPager\preprocessResults(), ApiBase\profileDBOut(), ApiBase\profileOut(), JobQueueAggregator\purge(), LocalFile\purgeOldThumbnails(), BacklinkCache\queryLinks(), SvgHandler\rasterize(), MWCryptRand\realGenerate(), OldChangesList\recentChangesLine(), Parser\recursivePreprocess(), Sanitizer\removeHTMLcomments(), Sanitizer\removeHTMLtags(), WatchedItem\removeWatch(), SearchHighlighter\removeWiki(), LinkHolderArray\replace(), ReplacementArray\replace(), LinkHolderArray\replaceInternal(), LinkHolderArray\replaceInterwiki(), WikitextContent\replaceSection(), LinkHolderArray\replaceText(), Http\request(), DjVuImage\retrieveMetaData(), JpegHandler\rotate(), BitmapHandler\rotate(), Hooks\run(), PrefixSearch\searchWithVariants(), SkinTemplate\setupTemplateForOutput(), UploadBase\stashFile(), StreamFile\stream(), BitmapHandler\transformCustom(), BitmapHandler\transformImageMagick(), MediaWiki_I18N\translate(), StripState\unstripType(), WikiPage\updateIfNewerOn(), UploadBase\verifyFile(), UploadBase\verifyMimeType(), UploadBase\verifyPartialFile(), UploadBase\verifyUpload(), wfIsBadImage(), and wfMsgReal().