Skip to content
spcsser edited this page Dec 16, 2011 · 12 revisions

Omniscient Debugger

An Omniscient Debugger allows in contrast to a classical debugger to analyse the runtime data of a program independent from breakpoints and back-in-time. The PHP Omniscient Debugger consists of two components: For collecting the data, a modified xdebug extension and for analyzing the saved data an Eclipse plugin.

PHODebugger Screenshot

Xdebug Settings

The Xdebug extension needs to be build from source: https://github.com/spcsser/xdebug

To get the data in correct format set the following setting:

xdebug.trace_format = 11

To set the filepath the following two entries are necessary, see http://xdebug.org/docs/execution_trace for details, if not set output will be sent to /tmp:

xdebug.trace_output_dir = <dirname>
xdebug.trace_output_name = <filename>

To enable a trace start by sending the query parameter XDEBUG_TRACE in the URL:

xdebug.trace_enable_trigger = 1

Otherwise you can start recording by calling xdebug_start_trace(<filepath>) and xdebug_stop_trace() to stop.

Eclipe Plugin Settings

The Eclipse plugin may need path mapping adjustment, depending on your setup. Can be found in the PHOD Preferences.

(Current) Known Limitations

  • Eclipse needs depending on the trace size loooots of memory, min. 1.5 Gigabyte recommended 3 Gigabyte. It's due to the concept, alternative has been thought about and is waiting for implementation ;)
  • Some variables after some assignments (+=, -=, ...) lack the correct value.
  • ... plus some more I just can't remember