timster - 10:03 pm on Mar 5, 2011 (gmt 0)
Sounds like you are asking for a PHP tracing tool. There is not a built-in trace in PHP, but several extensions exist to accomplish this.
A search for "php tracing" will turn up extensions you could use, including Zend's xdebug and DTrace.
Here's a good intro showing what DTrace can do: