6
6
655362017-09-07 13:38:03
PHP
65536, 2017-09-07 13:38:03

Why XDebug slows down even disabled?

Installed Debian 9, PHP 7, XDebug 2.5.
Before that was Ubuntu 14.04, PHP 5.5.9, and some previous XDebug.
I copied and pasted the old config, before everything was as it should be. All autostarts, enablees, etc. have been disabled. It slowed down only if it was turned on by a trigger (a cookie was sent from the browser).
Now it slows down on its own, it doesn't slow down if you disable the extension altogether. On the example of one page:
- the extension is disabled: 500 ms
- enabled: 2.3 sec - enabled and the cookie
is sent: 4.4 sec
read in the documentation about each new one. I found only xdebug.coverage_enable = On, turned it off, it turned out:
- enabled: 1.9 sec
- enabled and the cookie is sent: 3.8 sec
The config turned out like this:

zend_extension = xdebug.so

xdebug.auto_trace = Off
xdebug.cli_color = 0
xdebug.collect_assignments = Off
xdebug.collect_includes = On
xdebug.collect_params = 0
xdebug.collect_return = Off
xdebug.collect_vars = Off
xdebug.coverage_enable = Off
xdebug.default_enable = Off
;xdebug.dump.COOKIE =
;xdebug.dump.ENV =
;xdebug.dump.FILES =
;xdebug.dump.GET =
;xdebug.dump.POST =
;xdebug.dump.REQUEST =
;xdebug.dump.SERVER	=
;xdebug.dump.SESSION =
xdebug.dump_globals = On
xdebug.dump_once = On
xdebug.dump_undefined = Off
xdebug.extended_info = On
;xdebug.file_link_format =
xdebug.force_display_errors = Off
xdebug.force_error_reporting = 0
xdebug.halt_level = 0
xdebug.idekey = PHPSTORM
xdebug.max_nesting_level = 250
xdebug.max_stack_frames = -1
xdebug.overload_var_dump = 2

xdebug.profiler_aggregate = Off
xdebug.profiler_append = Off
xdebug.profiler_enable = Off
xdebug.profiler_enable_trigger = On
;xdebug.profiler_enable_trigger_value =
xdebug.profiler_output_dir = /home/fed/xdebug
xdebug.profiler_output_name = cachegrind.out.%H%R

;xdebug.remote_addr_header =
xdebug.remote_autostart = Off
xdebug.remote_connect_back = Off
xdebug.remote_cookie_expire_time = 3600
xdebug.remote_enable = On
xdebug.remote_handler = dbgp
xdebug.remote_host = 192.168.1.2
xdebug.remote_log = /home/fed/xdebug/log
xdebug.remote_mode = req
xdebug.remote_port = 9000

xdebug.scream = Off
xdebug.show_error_trace = Off
xdebug.show_exception_trace = Off
xdebug.show_local_vars = Off
xdebug.show_mem_delta = Off

xdebug.trace_enable_trigger = On
;xdebug.trace_enable_trigger_value =
xdebug.trace_format = 0
xdebug.trace_options = 0
xdebug.trace_output_dir = /home/fed/xdebug
xdebug.trace_output_name = trace.%H%R
xdebug.var_display_max_children = 128
xdebug.var_display_max_data = 512
xdebug.var_display_max_depth = 3

1.9 sec is almost 4 times more than 500, apparently something else is happening. What could be?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
P
Papa, 2017-09-07
Stifflera @PapaStifflera

The first one is that when you add debugging behavior to your server, the debug engine "attaches" to the PHP process and receive messages of the engine to stop at breakpoints, and this is BAD, because introduces a high performance blow to have another process stopping or "retaining" the PHP parser.

https://stackoverflow.com/questions/3522182/will-e...

E
Evgeny Petrov, 2017-09-07
@EvgenZZ

debug.profiler_enable_trigger = on disable

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question