<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://docs.moodle.org/dev/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Harryf</id>
	<title>MoodleDocs - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://docs.moodle.org/dev/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Harryf"/>
	<link rel="alternate" type="text/html" href="https://docs.moodle.org/dev/Special:Contributions/Harryf"/>
	<updated>2026-06-23T03:56:45Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.43.5</generator>
	<entry>
		<id>https://docs.moodle.org/dev/index.php?title=Profiling_PHP&amp;diff=18465</id>
		<title>Profiling PHP</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/dev/index.php?title=Profiling_PHP&amp;diff=18465"/>
		<updated>2010-11-10T20:24:55Z</updated>

		<summary type="html">&lt;p&gt;Harryf: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;PHP has two significant profilers...&lt;br /&gt;
&lt;br /&gt;
One is [http://www.xdebug.org/docs/profiler XDebug] - this is well known and understood and it&#039;s trace output is supported by tools like [http://kcachegrind.sourceforge.net/html/Home.html KCachegrind].&lt;br /&gt;
&lt;br /&gt;
The other is [http://pecl.php.net/package/xhprof xhprof], a profiler released by facebook&#039;s engineering team, designed for capturing profile traces on live servers. Compared to XDebug, xhprof aims to have the minimum impact on execution times and require relatively little space to store a trace, so you can run it live without a noticeable impact on users and without filling disks. The trade off with xhprof is in &#039;&#039;slightly&#039;&#039; less detail and a trace format that needs it&#039;s own GUI to visualize (which ships with xhprof). The reason you&#039;d want to profile in a live environments (vs. on development) is certain categories of problem may only been seen live, e.g. (data related) what happens when the user table grows 100 times, the impact on &amp;quot;login.php&amp;quot;  or (service related) server to server HTTP requests. Did a presentation once [https://docs.google.com/present/view?id=dcbkgbgf_45fbg3rnmk XHProf - facebooks PHP profiler] which explains in more detail - Penny saw the talk which is how I ended up writing this.&lt;br /&gt;
&lt;br /&gt;
==See also==&lt;br /&gt;
&lt;br /&gt;
* [http://moodle.org/mod/forum/discuss.php?d=162045 Forum thread about profiling Moodle 2.0]&lt;br /&gt;
* [https://docs.google.com/present/view?id=dcbkgbgf_45fbg3rnmk&amp;amp; presentation about xhprof]&lt;br /&gt;
* http://techportal.ibuildings.com/2009/12/01/profiling-with-xhprof/&lt;br /&gt;
&lt;br /&gt;
{{CategoryDeveloper}}&lt;/div&gt;</summary>
		<author><name>Harryf</name></author>
	</entry>
</feed>