function xhprof_pc_info in XHProf 6
Same name and namespace in other branches
- 7 xhprof.inc \xhprof_pc_info()
Print info for a parent or child function xhprof_in the parent & children report.
@author Kannan
1 call to xhprof_pc_info()
File
- ./
xhprof.inc, line 1010
Code
function xhprof_pc_info($info, $base_ct, $base_info, $parent) {
global $sort_col;
global $metrics;
global $format_cbk;
global $display_calls;
$type = $parent ? "Parent" : "Child";
if ($display_calls) {
$mouseoverct = xhprof_get_tooltip_attributes($type, "ct");
// Call count.
$row = array(
xhprof_print_num($info["ct"], $format_cbk["ct"], $sort_col == "ct", $mouseoverct),
);
$row[] = xhprof_print_pct($info["ct"], $base_ct, $sort_col == "ct", $mouseoverct);
}
// Inclusive metric values.
foreach ($metrics as $metric) {
$row[] = xhprof_print_num($info[$metric], $format_cbk[$metric], $sort_col == $metric, xhprof_get_tooltip_attributes($type, $metric));
$row[] = xhprof_print_pct($info[$metric], $base_info[$metric], $sort_col == $metric, xhprof_get_tooltip_attributes($type, $metric));
}
return $row;
}