Xdebug is just like APD an extension that is used to collect data while executing a script, though the philosophy behind this extension is different. Where APD mainly focuses on profiling, Xdebug also focuses on debugging of scripts, including breakpoints and stepping through code. Profiling with Xdebug can be accomplished in two ways:
By tracing executed scripts to a file
By generating profiling data in the cachegrind format to a file
cachegrind is a profiler for programs written in C, and comes with a very nice front-end for KDE: KCachegrind.
Just like APD, you can install Xdebug (http://xdebug.org) from PECL by running pear install xdebug. After installation, you must load Xdebug into Zend ...