Commit graph

33 commits

Author SHA1 Message Date
Platonides
b51b77bba1 Move the overhead computation to another function. 2011-02-10 16:54:51 +00:00
Sam Reed
035218f403 Revert r74913, caused many problems, and was only likely to cause more in the future 2010-10-17 21:18:04 +00:00
Sam Reed
47b13d184c Move profiler stuff to own folder, updater AutoLoader to match
ProfilerSimpleTrace isn't in AutoLoader. Neither is ProfilerStub

Profiler also says " * This file is only included if profiling is enabled"...
2010-10-17 19:04:05 +00:00
Alexandre Emsenhuber
9c8a11764d Fixed some doxygen warnings 2010-07-01 20:45:21 +00:00
Roan Kattouw
cb480c416c Fix division by zero in Profiler 2010-04-09 12:31:27 +00:00
Alexandre Emsenhuber
b8b254da7f Fixes to r62995:
* Avoid fatal error if $wgProfiler is either not a object (ProfilerStub.php) or an instance of Profiler
* Set $wgProfiler to null in ProfilerStub.php so that $wgProfiler doesn't need to be checked with "isset" first, updated check in GlobalFunctions.php accordingly
2010-02-26 08:53:06 +00:00
Alexandre Emsenhuber
bccd2ad03b fix some doxygen errors 2009-12-11 22:19:37 +00:00
Aaron Schulz
1d05356f12 stop undefined variable notices 2009-12-07 16:50:36 +00:00
Alexandre Emsenhuber
0c4280dc38 Avoid infinite loop when an exception occurs in command line mode 2009-07-29 14:38:28 +00:00
Aaron Schulz
3bdaba94c6 * Fixed $wgProfileToDatabase/$wgProfileCallTree interaction (later disabled the former)
* Made $wgProfileLimit actually work (bug 17485)
2009-02-24 09:50:22 +00:00
Roan Kattouw
53b85fc55a Remove stray semicolon 2009-01-23 20:39:54 +00:00
Aaron Schulz
bcf2165694 Check $wgProfiling. This lets long running scripts disable profiling to avoid OOM errors due to the growing work stack size. 2009-01-19 23:34:13 +00:00
Tim Starling
90ed80443e (bug 12586) Use wfHostname() everywhere, remove $wguname and $wgNodeName. Use getenv('COMPUTERNAME') on Windows. 2008-10-06 07:30:38 +00:00
Alexandre Emsenhuber
087a9f70c5 WARNING: HUGE COMMIT
Doxygen documentation update:
* Changed alls @addtogroup to @ingroup. @addtogroup adds the comment to the group description, but doesn't add the file, class, function, ... to the group like @ingroup does. See for example http://svn.wikimedia.org/doc/group__SpecialPage.html where it's impossible to see related files, classes, ... that should belong to that group.
* Added @file to file description, it seems that it should be explicitely decalred for file descriptions, otherwise doxygen will think that the comment document the first class, variabled, function, ... that is in that file.
* Removed some empty comments
* Removed some ?>

Added following groups:
* ExternalStorage
* JobQueue
* MaintenanceLanguage

One more thing: there are still a lot of warnings when generating the doc.
2008-05-20 17:13:28 +00:00
Alexandre Emsenhuber
464c24f510 *stab* some tweaks for my last commit 2008-05-06 17:18:02 +00:00
Alexandre Emsenhuber
4b453dbb59 * Update some documentation
* Moved ProfilerSimple::debug() to Profiler class so that it can also be used there
2008-05-06 16:03:03 +00:00
Brion Vibber
a849f6fe57 and eat that unneeded table name var 2008-04-30 17:20:27 +00:00
Brion Vibber
91e7548aee use query constructors; passing hostname string raw into SQL gives me the willies, even if it should always be safe 2008-04-30 17:19:55 +00:00
Aaron Schulz
274b9ac0ac * No need to *1000
* Hide div-by-zero messages
* Fix kb factor
2008-04-29 15:42:51 +00:00
Aaron Schulz
81f2c61002 update insert 2008-04-29 12:05:25 +00:00
Aaron Schulz
de4773462d Add pf_memory field 2008-04-29 11:59:10 +00:00
Siebrand Mazeland
79d5225c0e * remove end of line whitespace
* remove empty lines at end of file
* remove "?>" where still present
2008-04-14 07:45:50 +00:00
Aryeh Gregor
a15c419b3d Remove ?>'s from files. They're pointless, and just asking for people to mess with the files and add trailing whitespace. (Yes, I looked over every one and reverted those that were bogus. Slash-enter a million times in less worked well enough, although it was a bit mind-numbing.) 2007-06-29 01:19:14 +00:00
Antoine Musso
9d76d88695 Fix #5375: profiling does not respect read-only mode 2007-05-10 21:05:36 +00:00
Nick Jenkins
f9619da3f0 Yet more doc tweaks:
* Add @addtogroup tags to various classes, to try and group conceptually-related classes together.
* Add brief descriptions to various Special pages, thanks to Phil Boswell.
* Moving some docs to be right above the classes they represent, so that they are picked up.
2007-04-20 08:55:14 +00:00
Nick Jenkins
61678d8a5d * Removing a handful of unused globals.
* $stack is not modified in Profiler::calltreeCount(), no need to pass-by-ref.
* Add FIXME marker to non-cross-platform line.
* A freshly created string does not need to be returned by reference. [Xml::namespaceSelector() and HTMLnamespaceselector() ].
2007-01-23 07:29:58 +00:00
Nick Jenkins
f88c771756 The war on redundant ampersand usage!
* Convert "$dbw =& wfGetDB( DB_MASTER );" --> "$dbw = wfGetDB( DB_MASTER );"
* convert "$skin =& $wgUser->getSkin();" --> "$skin = $wgUser->getSkin();"

For the time being have not changed the function definitions of wfGetDB() or User::getSkin() [i.e. they are still both return-by-ref], so as to ensure the interface does not change for extensions [some of which may still be trying to run on PHP4 environments]. However presumably at some point this can be changed too.

Also includes tiny tweak to newlines in parserTests - will show 1 rather than 2 newlines between the "Reading tests from" strings when in quiet mode.
2007-01-22 23:50:42 +00:00
Antoine Musso
c771fc9c96 Use Doxygen @addtogroup instead of phpdoc @package && @subpackage 2007-01-20 15:09:52 +00:00
Antoine Musso
b144fcb85d Rename constructors to __constructor 2007-01-20 13:34:31 +00:00
Brion Vibber
1a6a78a0aa * (bug 8041) Work around bug with debug_backtrace when Zend Optimizer is
loaded by skipping the function. Use wfDebugBacktrace() wrapper function.
2007-01-02 23:50:56 +00:00
Nick Jenkins
14c53b728f Code housekeeping stuff (and barring any stuff-ups on my behalf, there should be no changes in behaviour whatsoever after this) -
* removing some unused global declarations.
* removing or commenting out or adding comments for unused local vars.
* Adding one or two local var declarations.
* Declaring $matches array passed to preg_match() / preg_match_all() as array() before using [not required, just have a slight preference for the explicitness].
* remove one or two pass-by-reference function declarations where the value is not modified.
* Adding some braces to if-else blocks.
* In Parser.php, stripstrate is now an object rather than an array as per r17820, so we no longer need ask for a reference to it (as in "$x =& $this->mStripState;"), and in fact it's probably just simpler to get rid of $x altogether.
* Moving some preg regexes from "" quoting to '' quoting to stop static analyzer whinging about bad escape sequences.

... up to "LinksUpdate.php" in the includes/ directory.
2006-11-23 08:25:56 +00:00
Domas Mituzas
63307ad99c Move SO::_getCaller() to Profiler::getCaller() 2006-08-02 18:34:01 +00:00
Tim Starling
3ea576aa25 Consolidated web initialisation code into includes/WebStart.php. Moved profiling setup to a hook file "StartProfiler.php", following Brion's suggestion to merge Wikimedia's early profiling patch into subversion. Renamed Profiling.php and logProfilingData(), removed unnecessary wfProfileClose() calls. 2006-07-14 05:35:31 +00:00
Renamed from includes/Profiling.php (Browse further)