<?xml version="1.0"?>
<rss version="2.0">
  <channel>
    <title>PHPDeveloper.org</title>
    <link>http://www.phpdeveloper.org</link>
    <description>Up-to-the Minute PHP News, views and community</description>
    <language>en-us</language>
    <pubDate>Sun, 12 Feb 2012 21:38:04 -0600</pubDate>
    <ttl>30</ttl>
    <item>
      <title><![CDATA[Volker Dusch's Blog: Never trust other peoples benchmarks - A recent example (exceptions)]]></title>
      <guid>http://www.phpdeveloper.org/news/17417</guid>
      <link>http://www.phpdeveloper.org/news/17417</link>
      <description><![CDATA[<p>
In response to a <a href="http://phpdeveloper.org/news/17403">previous post</a> benchmarking exceptions, <i>Volker Dusch</i> has posted <a href="http://edorian.posterous.com/never-trust-other-peoples-benchmarks-a-recent">some of his own thoughts</a> and benchmarking results on the same topic.
</p>
<blockquote>
Some days ago there was a blog post regarding php exception performance in 5.4 and the numbers got reported all over the place. The actually numbers are secondary. The main point is: Don't trust "random" stuff on the Internet when thinking about improving your application performance. You always need to measure things for your self and take care doing so! I've initially trusted the benchmark myself and disgraced the whole post saying: "Well yes, exceptions are slower than if statements but nice that they got faster".
</blockquote>
<p>
He includes some results with a bit more standardized testing - one run with both 5.3 and 5.4 using XDebug and another with it turned off for both. His results make sense, if you think about them:
</p>
<blockquote>
So what we learn from that? Running stuff with debugging tools is slower than not doing that. That's why we don't use xDebug in production.
</blockquote>]]></description>
      <pubDate>Thu, 19 Jan 2012 09:20:32 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[DZone.com: Speed Up Your PHP Like Facebook]]></title>
      <guid>http://www.phpdeveloper.org/news/17182</guid>
      <link>http://www.phpdeveloper.org/news/17182</link>
      <description><![CDATA[<p>
On DZone.com <i>John Esposito</i> <a href="http://css.dzone.com/articles/speed-your-php-facebook">reminds you</a> about another technology Facebook has introduced to the world of PHP (besides HipHop) - <a href="https://github.com/facebook/xhprof">XHProf</a>, a PHP profiler.
</p>
<blockquote>
Facebook did more for PHP: they also created XHProf, a PHP profiler with a (supposedly) easy-to-use HTML interface, designed to pinpoint exactly where your bottlenecks are appearing, so that you can optimize at every stage in the pipeline. [...] If you haven't tried XHProf, you might want to <a href="https://github.com/facebook/xhprof">look into it</a>. Installation apparently requires a little nudging, but Nick Lewis just posted a <a href="http://nicklewis.org/node/1087">full, practical guide</a> to benchmarking and performance tuning your PHP and MySQL, using XHProf (as well as other techniques) -- a very nice overview of many common bottlenecks and how to open them up.
</blockquote>
<p>
There's also a link to some <a href="http://groups.drupal.org/node/187209">Drupal 6 benchmarks</a> that shows how it has helped that project (including both small and large improvements).
</p>]]></description>
      <pubDate>Tue, 29 Nov 2011 10:13:03 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[Derick Rethans' Blog: Twig extension]]></title>
      <guid>http://www.phpdeveloper.org/news/17151</guid>
      <link>http://www.phpdeveloper.org/news/17151</link>
      <description><![CDATA[<p>
In a new post from <i>Derick Rethans</i> he talks about <a href="http://derickrethans.nl/twig-extension.html">an extension version</a> of Twig, the popular <a href="http://twig-project.com">templating engine</a> from the creators of the Symfony framework.
</p>
<blockquote>
A while ago, Fabien asked me to have a look at porting one of Twig's slowest methods, TwigTemplate::getAttribute(), into a PHP extension. It is a complex method that does a lot of different checks and look-ups. Fabien's benchmarks showed that this method was responsible for quite a large amount of time. On top of that, it didn't seem that it could be optimised any further as PHP code itself.
</blockquote>
<p>
He points to <a href="https://github.com/derickr/twig-ext">the twig-ext extension</a> that's a reworked version of the "getAttribute" method from the tool and the performance gain (about 15%) it gives. Compiled templates will automatically call this new method in the extension. This update has already been merged into <a href="http://github.com/fabpot/Twig">the main Twig repo</a>.
</p>]]></description>
      <pubDate>Mon, 21 Nov 2011 08:35:39 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[Derick Rethans' Blog: Xdebug's Code Coverage speedup]]></title>
      <guid>http://www.phpdeveloper.org/news/16898</guid>
      <link>http://www.phpdeveloper.org/news/16898</link>
      <description><![CDATA[<p>
<i>Derick Rethans</i> has a new post to his blog today talking about some work that's been done to <a href="http://derickrethans.nl/xdebug-codecoverage-speedup.html">speed up XDebug's code coverage generation</a>. Changes in the coming 2.2 release have some improvements that make things perform better and put less stress on PHP in the process.
</p>
<blockquote>
Code coverage tells you how much of your code base is actually being tested by your unit tests. It's a very useful feature, but sadly, it slows down PHP's execution quite a lot. One part of this slowdown is the overhead to record the information internally, but another part is because I have to overload lots of opcodes. (Opcodes are PHP's internal execution units, similar to <a href="http://en.wikipedia.org/wiki/Assembler_%28computer_programming%29#Assembly_language">assembler</a> instructions) They are always overloaded even if code coverage is not used, because it's only safe to overload them for the whole request.
</blockquote>
<p>
These changes were from a combination of <a href="https://github.com/taavi/xdebug/commits/coverage_line_array">contributions from Taavi Burns</a> and a new ini setting that will allow you to enable or disable the code coverage in XDebug. Benchmarking shows a good amount of time reduction in coverage runs - dropping anywhere from a few seconds to over a minute. He also mentions the idea of "modes", shortcuts to predefined settings for different types of reporting (like "profiling" or "tracing").
</p>]]></description>
      <pubDate>Fri, 23 Sep 2011 09:56:33 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[SkyTechGeek.com: 10 Exceptional Tools For Website Testing]]></title>
      <guid>http://www.phpdeveloper.org/news/16760</guid>
      <link>http://www.phpdeveloper.org/news/16760</link>
      <description><![CDATA[<p>
Sometimes a little (external) testing of your website is in order and <i>Gagan Chhatwal</i> has posted <a href="http://skytechgeek.com/2011/08/10-exceptional-tools-for-website-testing/">his list of ten tools</a> you can use to check everything from  how much load the site can take to what can be done to optimize the load time.
</p>
<blockquote>
When maintaining or running a website , Webmasters need to keep in mind that one of the pertinent issues they will need to focus on is :Website Testing, which is not only vital for the website itself but for the user as well and one should not overlook its importance. [We have] collected some vital and free website testing tools which will help Webmasters in testing their sites thus saving users to conduct time consuming needless searches in finding the best resources pertaining to Web related tools and info.
</blockquote>
<p>Among the tools on the list are services like:</p>
<ul>
<li><a href="http://loadimpact.com/">Load Impact</a>
<li><a href="https://browsermob.com/performance-testing">Browser Mob</a>
<li><a href="http://host-tracker.com/">Host Tracker</a>
<li><a href="http://builtwith.com/">Built With</a>
<li><a href="http://online.htmlvalidator.com/php/onlinevallite.php">CSE HTML validator</a>
</ul>
<p>
Most of these resources are free services, if not then they have a trial where you can see if it's a good fit.
</p>]]></description>
      <pubDate>Tue, 23 Aug 2011 13:25:22 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Fabien Potencier's Blog: The PHP Ternary Operator: Fast or not?]]></title>
      <guid>http://www.phpdeveloper.org/news/16601</guid>
      <link>http://www.phpdeveloper.org/news/16601</link>
      <description><![CDATA[<p>
In a new post <i>Fabien Potencier</i> looks at <a href="http://fabien.potencier.org/article/48/the-php-ternary-operator-fast-or-not">the ternary operator</a> in PHP and wonders which is faster - using it or not (well, sort of...)
</p>
<blockquote>
People like micro-optimizations. They are easy to understand, easy to apply... and useless. But some time ago, while reviewing pull requests for <a href="http://twig-project.org/">Twig</a>, I read an interesting discussion about the performance of the <a href="https://github.com/fabpot/Twig/issues/380">ternary operator</a> in PHP (thanks to <a href="https://github.com/nikic">@nikic</a> for the investigation). Do you know which [example] snippet is the fastest (of course, they do exactly the same)? The right answer is: it depends.
</blockquote>
<p>
He notes that it's all about the data being worked with. As some of his tests show (testing code included) there does end up being a difference between using it on a small and large dataset. After investigation, it was found that the ternary operator copies (copy-on-write) the value versus an "if" that just evaluates. He also mentions the new "?" version of the ternary syntax in PHP 5.3, but notes it still suffers from the same issue.
</p>
]]></description>
      <pubDate>Mon, 18 Jul 2011 10:35:36 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[DevShed: 7 PHP Frameworks Tested For Speed - Benchmarking PHP Frameworks]]></title>
      <guid>http://www.phpdeveloper.org/news/16299</guid>
      <link>http://www.phpdeveloper.org/news/16299</link>
      <description><![CDATA[<p>
In <a href="http://www.devshed.com/c/a/PHP/7-PHP-Frameworks-Tested-For-Speed/">this new post</a> from DevShed today they look at seven different frameworks and compare the speed of how they render a simple request - CakePHP, CodeIgniter, Symfony2, Yii, RainFramework, Doophp and Kohana.
</p>
<blockquote>
There are so many PHP frameworks that it can be hard to keep track of them all. Some are already very popular, while others are relatively new and unknown. [...] Of the seven criteria [of a good framework], this article will examine only the speed and performance. 
</blockquote>
<p>
They <a href="http://www.devshed.com/c/a/PHP/7-PHP-Frameworks-Tested-For-Speed/1/">define their structure</a> for testing - hardware and software - as well as some basic settings like number of connections, disabling of caching and <a href="http://bit.ly/inWQQa">these sample files</a> for each of the frameworks. You'll have a <a href="http://www.devshed.com/c/a/PHP/7-PHP-Frameworks-Tested-For-Speed/2/">see the rest of the post</a> for their results, though.
</p>]]></description>
      <pubDate>Thu, 05 May 2011 10:03:19 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[WebTutor.pl: HipHop for PHP: Benchmark - Revenge of PHP]]></title>
      <guid>http://www.phpdeveloper.org/news/16226</guid>
      <link>http://www.phpdeveloper.org/news/16226</link>
      <description><![CDATA[<p>
On the WebTutor.pl site they've posted the <a href="http://php.webtutor.pl/index.php/2011/04/04/hiphop-for-php-benchmark-revenge-of-php/">second part</a> of their series looking at the benchmark results from their tests running HipHop. You can find their first post with some of the introductory setup and information <a href="http://php.webtutor.pl/index.php/2011/04/02/hiphop-for-php-bechmark-english-version/">here</a>.
</p>
<blockquote>
In <a href="http://php.webtutor.pl/index.php/2011/04/02/hiphop-for-php-bechmark-english-version/">previous article</a> I measured the performance of HipHop for PHP by performing some tests downloaded from the <a href="http://shootout.alioth.debian.org/">shootout.alioth.debian.org</a> website. Unfortunately the test list was incomplete. Only six tests were selected to avoid potential incompatibility issues with the HipHop compiler.
</blockquote>
<p>
In this new post he provides the results for two more tests: regex-dna and k-nucleotide. He outlines the testing platform and shares the results of testing some pretty basic scripts. His <a href="http://php.webtutor.pl/wp-content/uploads/2011/04/graph-sb-en2.png">results</a> were interesting and found that some operations the HipHop compiler actually slowed down.
</p>]]></description>
      <pubDate>Wed, 20 Apr 2011 13:47:50 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[StackOverflow.com: Optimizing Kohana-based Websites for Speed and Scalability]]></title>
      <guid>http://www.phpdeveloper.org/news/15925</guid>
      <link>http://www.phpdeveloper.org/news/15925</link>
      <description><![CDATA[<p>
On StackOverflow a question was asked about how to tweak and tune the performance of a <a href="http://kohanaphp.com">Kohana</a>-powered website. The result was a <a href="http://stackoverflow.com/questions/1260134/optimizing-kohana-based-websites-for-speed-and-scalability/1283195#1283195">detailed answer</a> from <i>Pascal Martin</i> that can be applied to just about any kind of web application out there, not just ones written in PHP.
</p>
<blockquote>
Here are some points that come to my mind when talking about performances, scalability, PHP, ...First of all, there are many aspects/questions that are to consider : configuration of the server (both PHP, MySQL, and system) ; you might get more help about that on serverfault, I suppose, PHP code, database queries, using or not your webserver? Can you use any kind of caching mechanism ? Or do you need always more that up to date data on the website ?
</blockquote>
<p>
He goes on to give tips about using a reverse proxy (like <a href="http://varnish.projects.linpro.no/">Varnish</a>), using an opcode cache, caching data as well, profiling and optimizing SQL queries. He finishes it off with a more specific look at Kohana and how you can use some of its built in tools to accomplish these same goals.
</p>]]></description>
      <pubDate>Fri, 18 Feb 2011 08:39:53 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[Rob Allen's Blog: PHP 5.3 is quicker than PHP 5.2]]></title>
      <guid>http://www.phpdeveloper.org/news/15553</guid>
      <link>http://www.phpdeveloper.org/news/15553</link>
      <description><![CDATA[<p>
<i>Rob Allen</i> has <a href="http://akrabat.com/php/php-5-3-is-quicker-than-php-5-2-2/">shared some of his personal experience</a> in how much faster PHP 5.3 is over the latest version in the PHP 5.2.x series when he tried to change up some view helpers in his Zend Framework application.
</p>
<blockquote>
I was looking at the way view helpers work in ZF2 and thought it would be more convenient if we altered the syntax a little. A side-effect of the change was that we'd have to use call_user_func_array, which is perceived as slow. I thought I'd whip up a simple test to find out how much slower it would be over a direct method call.
</blockquote>
<p>
He includes the sample code he used to benchmark the request times between the two versions measured by <a href="http://php.net/microtime">microtime</a>. In his results he saw a difference of almost five seconds between the same code running on 5.3 versus 5.2 (according to test runs on his laptop).
</p>]]></description>
      <pubDate>Thu, 09 Dec 2010 09:09:07 -0600</pubDate>
    </item>
  </channel>
</rss>

