diff options
author | Michael Larabel <michael@phx-laptop.(none)> | 2008-09-11 20:31:35 -0400 |
---|---|---|
committer | Michael Larabel <michael@phx-laptop.(none)> | 2008-09-11 20:31:35 -0400 |
commit | 71c09d5de03b0113fb38f0511a9bbc4f36f02826 (patch) | |
tree | 445071e6a58e86cdb27c3c41772828efb0ddb627 /pts-core/functions/pts-functions_system_cpu.php | |
parent | c8f344bd0a30abb7faad158982292363b1f9d2c0 (diff) | |
download | phoronix-test-suite-upstream-71c09d5de03b0113fb38f0511a9bbc4f36f02826.tar.gz phoronix-test-suite-upstream-71c09d5de03b0113fb38f0511a9bbc4f36f02826.tar.xz phoronix-test-suite-upstream-71c09d5de03b0113fb38f0511a9bbc4f36f02826.zip |
pts-core: Improve formatting for systems with multiple CPUs but of
different models
Diffstat (limited to 'pts-core/functions/pts-functions_system_cpu.php')
-rw-r--r-- | pts-core/functions/pts-functions_system_cpu.php | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/pts-core/functions/pts-functions_system_cpu.php b/pts-core/functions/pts-functions_system_cpu.php index f4afbb2..bf8cf48 100644 --- a/pts-core/functions/pts-functions_system_cpu.php +++ b/pts-core/functions/pts-functions_system_cpu.php @@ -80,12 +80,13 @@ function processor_string() $current_id = -1; $current_string = $cpu_strings[0]; $current_count = 0; + $cpus = array(); for($i = 0; $i < count($physical_cpu_ids); $i++) { if($current_string != $cpu_strings[$i] || $i == (count($physical_cpu_ids) - 1)) { - $info .= $current_count . " x " . append_processor_frequency(pts_clean_information_string($current_string), $i); + array_push($cpus, $current_count . " x " . append_processor_frequency(pts_clean_information_string($current_string), $i)); $current_string = $cpu_strings[$i]; $current_count = 0; @@ -97,6 +98,7 @@ function processor_string() $current_id = $physical_cpu_ids[$i]; } } + $info = implode(", ", $cpus); } } |