Skip to main content

Profiling PHP Code with Xdebug and KCacheGrind

posted onDecember 30, 2010
by hitbsecnews

In his 1974 paper, "Structured Programming with go to Statements", famed computer scientist Donald Knuth famously proclaimed premature optimization to be "the root of all evil." While it is indeed a good idea to avoid spending too much time on code optimization during the early stages of any project, eventually you'll want to seek out and resolve any bottlenecks in order to ensure your application is operating at its full potential.

Which brings us to the question of how to even go about determining which parts of an application could conceivably be optimized. One common approach involves using a profiler such as Xdebug, which can analyze your code and produce performance reports. These reports can then be reviewed within a profiling visualization tool such as KCacheGrind.

In this article I'll show you how to use Xdebug and KCacheGrind to begin profiling and analyzing your PHP-driven Web applications.

Source

Tags

Software-Programming

You May Also Like

Recent News

Friday, November 29th

Tuesday, November 19th

Friday, November 8th

Friday, November 1st

Tuesday, July 9th

Wednesday, July 3rd

Friday, June 28th

Thursday, June 27th

Thursday, June 13th

Wednesday, June 12th

Tuesday, June 11th