|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2012-06-12 18:01 UTC] sixd@php.net
-Assigned To:
+Assigned To: scottmac
[2017-10-24 06:13 UTC] kalle@php.net
-Status: Assigned
+Status: Open
-Assigned To: scottmac
+Assigned To:
[2017-10-24 08:24 UTC] kalle@php.net
-Status: Open
+Status: Suspended
[2017-10-24 08:24 UTC] kalle@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Tue Oct 28 03:00:02 2025 UTC |
Description: ------------ One of the greatest feature of xhprof is PHP script compilation time logging. So I could notice how much time PHP was compiling my code. But overall statistics about compilation time is not displayed. Below is the patch which displays "Compilation time" value within the top "Overall Summary" block. I'll be pleased if you apply it in a next version. Index: xhprof_lib/display/xhprof.php =================================================================== --- xhprof_lib/display/xhprof.php (revision 14556) +++ xhprof_lib/display/xhprof.php (working copy) @@ -938,6 +938,19 @@ } if ($display_calls) { + $time = 0; + foreach ($symbol_tab as $k => $sym) { + if (0 === strpos($k, 'load::')) { + $time += floatval($sym['wt']); + } + } + echo "<tr>"; + echo "<td style='text-align:right; font-weight:bold'>Compilation Time:</td>"; + echo "<td>" . number_format($time) . " microsecs</td>"; + echo "</tr>"; + } + + if ($display_calls) { echo "<tr>"; echo "<td style='text-align:right; font-weight:bold'>Number of Function Calls:</td>"; echo "<td>" . number_format($totals['ct']) . "</td>"; "</td>";