<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	
	>
<channel>
	<title>
	Comments on: How to Check Memory Usage in PHP	</title>
	<atom:link href="https://webrewrite.com/check-memory-usage-php-script/feed/" rel="self" type="application/rss+xml" />
	<link>https://webrewrite.com/check-memory-usage-php-script/</link>
	<description>Technology Blog Where You Find Programming Tips and Tricks</description>
	<lastBuildDate>Sun, 19 Aug 2018 15:57:19 +0000</lastBuildDate>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.9.4</generator>
	<item>
		<title>
		By: Lars Moelleken		</title>
		<link>https://webrewrite.com/check-memory-usage-php-script/#comment-382</link>

		<dc:creator><![CDATA[Lars Moelleken]]></dc:creator>
		<pubDate>Sun, 30 Nov 2014 12:18:00 +0000</pubDate>
		<guid isPermaLink="false">http://webrewrite.com/?p=1524#comment-382</guid>

					<description><![CDATA[take a look at &quot;Xdebug + Profiling&quot; it can&#039;t profile memory but it&#039;s very helpful for debugging &quot;performance issues :)

1.) install &quot;Xdebug&quot;: (http://www.xdebug.org/docs/profiler)

sudo apt-get install php5-xdebug

2.) configure &quot;Xdebug&quot;:

xdebug.profiler_enable_trigger = 1
xdebug.profiler_output_dir = &quot;/tmp&quot;
xdebug.profiler_output_name = &quot;cachegrind.out.%t-%s&quot;
xdebug.remote_enable = 1
xdebug.remote_handler = &quot;dbgp&quot;
xdebug.remote_host = &quot;127.0.0.1&quot;
xdebug.trace_output_dir = &quot;/tmp&quot;
xdebug.remote_port=9000

3.)

send &quot;XDEBUG_PROFILE=1″ via _GET or _POST

4.) use e.g. &quot;QCacheGrind&quot;, &quot;WinCacheGrind&quot; or &quot;KCachegrind&quot; (http://kcachegrind.sourceforge.net/html/Home.html) to visualize the results

PS: and there is also a memory usage profiler for the &quot;Cachegrind&quot;-Tools -&#062; &quot;memprof&quot;(https://github.com/arnaud-lb/php-memory-profiler), but in the most cases XDebug will help you :)]]></description>
			<content:encoded><![CDATA[<p>take a look at &#8220;Xdebug + Profiling&#8221; it can&#8217;t profile memory but it&#8217;s very helpful for debugging &#8220;performance issues 🙂</p>
<p>1.) install &#8220;Xdebug&#8221;: (<a href="http://www.xdebug.org/docs/profiler" rel="nofollow ugc">http://www.xdebug.org/docs/profiler</a>)</p>
<p>sudo apt-get install php5-xdebug</p>
<p>2.) configure &#8220;Xdebug&#8221;:</p>
<p>xdebug.profiler_enable_trigger = 1<br />
xdebug.profiler_output_dir = &#8220;/tmp&#8221;<br />
xdebug.profiler_output_name = &#8220;cachegrind.out.%t-%s&#8221;<br />
xdebug.remote_enable = 1<br />
xdebug.remote_handler = &#8220;dbgp&#8221;<br />
xdebug.remote_host = &#8220;127.0.0.1&#8221;<br />
xdebug.trace_output_dir = &#8220;/tmp&#8221;<br />
xdebug.remote_port=9000</p>
<p>3.)</p>
<p>send &#8220;XDEBUG_PROFILE=1″ via _GET or _POST</p>
<p>4.) use e.g. &#8220;QCacheGrind&#8221;, &#8220;WinCacheGrind&#8221; or &#8220;KCachegrind&#8221; (<a href="http://kcachegrind.sourceforge.net/html/Home.html" rel="nofollow ugc">http://kcachegrind.sourceforge.net/html/Home.html</a>) to visualize the results</p>
<p>PS: and there is also a memory usage profiler for the &#8220;Cachegrind&#8221;-Tools -&gt; &#8220;memprof&#8221;(<a href="https://github.com/arnaud-lb/php-memory-profiler" rel="nofollow ugc">https://github.com/arnaud-lb/php-memory-profiler</a>), but in the most cases XDebug will help you 🙂</p>
]]></content:encoded>
		
			</item>
	</channel>
</rss>
