|   | php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login | 
| 
 PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits              [2015-08-03 12:51 UTC] cmb@php.net
 
-Status:      Open
+Status:      Not a bug
-Assigned To:
+Assigned To: cmb
  [2015-08-03 12:51 UTC] cmb@php.net
  [2015-08-03 12:57 UTC] emilio dot pinn at gmail dot com
  [2015-08-03 13:41 UTC] cmb@php.net
 
-Status: Not a bug
+Status: Feedback
  [2015-08-03 13:41 UTC] cmb@php.net
  [2015-08-03 15:26 UTC] emilio dot pinn at gmail dot com
 
-Status: Feedback
+Status: Assigned
  [2015-08-03 15:26 UTC] emilio dot pinn at gmail dot com
  [2015-08-03 16:58 UTC] cmb@php.net
 
-Status:      Assigned
+Status:      Open
-Assigned To: cmb
+Assigned To:
  [2015-08-03 16:58 UTC] cmb@php.net
  [2015-08-03 17:51 UTC] emilio dot pinn at gmail dot com
 
-Status: Open
+Status: Closed
  [2015-08-03 17:51 UTC] emilio dot pinn at gmail dot com
  [2015-08-03 17:54 UTC] cmb@php.net
 
-Status:      Closed
+Status:      Not a bug
-Assigned To:
+Assigned To: cmb
 | |||||||||||||||||||||||||||
|  Copyright © 2001-2025 The PHP Group All rights reserved. | Last updated: Thu Oct 30 03:00:01 2025 UTC | 
Description: ------------ The following simple profiling script does not work on certain codes, e.g. with the vanilla installation of Joomla v3.4.2. It works with other complex CMS e.g. with WordPress. To easily prepend the profiling PHP script to the application, I used php_value auto_prepend_file "/tmp/instrumentation.php" In the .htaccess in the web root. Then, paste the test script in "/tmp/instrumentation.php". The output you can see in "/var/log/apache2/error.log" is just a series of "NO BACKTRACE" strings. PHP version; PHP 5.5.9-1ubuntu4.11 (cli) (built: Jul 2 2015 15:23:08) Test script: --------------- <?php function printname() { $bt = debug_backtrace(); if (count($bt) <= 1) { error_log('NO BACKTRACE: ' . print_r($bt, true)); } else { error_log('FUNCTION NAME: ' . $bt[1]['function']); } } declare(ticks=1); register_tick_function('printname'); ?> Expected result: ---------------- I expect a result like the following when I open the "/var/log/apache2/error.log" [:error] [pid 9091] [client 127.0.0.1:55726] FUNCTION NAME: function1 [:error] [pid 9091] [client 127.0.0.1:55726] FUNCTION NAME: function2 [:error] [pid 9091] [client 127.0.0.1:55726] FUNCTION NAME: function3 [:error] [pid 9091] [client 127.0.0.1:55726] FUNCTION NAME: function4 ... As this happens using the same test script with other code. Actual result: -------------- [:error] [pid 7555] [client 127.0.0.1:55742] NO BACKTRACE: Array\n(\n [0] => Array\n (\n [file] => /tmp/instrumentation.php\n [line] => 14\n [function] => printname\n [args] => Array\n (\n )\n\n )\n\n) [:error] [pid 7555] [client 127.0.0.1:55742] NO BACKTRACE: Array\n(\n [0] => Array\n (\n [file] => /tmp/instrumentation.php\n [line] => 16\n [function] => printname\n [args] => Array\n (\n )\n\n )\n\n)