4
Looking to profile my web app, I have added the following settings to my Applications php.ini file:


zend_extension                  = "C:\hqp\xampp_1.7.4\php\ext\php_xdebug.dll"
xdebug.profiler_append          = 0
xdebug.profiler_enable          = 1 
xdebug.profiler_output_dir      = "c:\hqp\xampp_1.7.4\tmp\profiles"
xdebug.profiler_output_name     = "cachegrind.out.%s"
xdebug.profiler_enable_trigger  = 1

In the httpd.conf file, a file is auto_prepended using the php value auto_prepend. The cachegrind.out.* file generated bears the name of this file (%s modifier in xdebug.profiler_output_name) and not the file that I actually looking to profile (for example the index.php file does not have a corresponding cachegrind.out.filepath_index.php)

Any idea what I am missing here?

Parijat Kalia
  • 4,929
  • 10
  • 50
  • 77

1 Answers1

1

It might be that you are producing two files, and the second one overwrites the first.

You can change following parameters in your php.ini :

xdebug.profiler_append=1

This should append both calls in the same file. source : https://xdebug.org/docs/profiler

xdebug.profiler_output_name = cachegrind.out.%u.%p.%r

This should make sure that if there are 2 files, their names should be different.

https://xdebug.org/docs/all_settings#trace_output_name for other modifiers.

hsibboni
  • 433
  • 2
  • 8