GPU list script: fix bug, and include anonymous platform hosts

This commit is contained in:
David Anderson 2014-10-19 22:35:17 -07:00
parent a26f310f1e
commit 3136342575
1 changed files with 11 additions and 3 deletions

View File

@ -45,7 +45,7 @@ function get_gpu_model($x, $vendor) {
function add_model($model, $r, $wu, &$models) { function add_model($model, $r, $wu, &$models) {
if (array_key_exists($model, $models)) { if (array_key_exists($model, $models)) {
$models[$model]->count++; $models[$model]->count++;
$models[$model]->time += $r->elapsed_time; $models[$model]->time += $r->elapsed_time/$wu->rsc_fpops_est;
} else { } else {
$x = new StdClass; $x = new StdClass;
$x->count = 1; $x->count = 1;
@ -76,7 +76,15 @@ function get_gpu_list($vendor, $alt_vendor=null) {
foreach($avs as $av) { foreach($avs as $av) {
$av_ids .= "$av->id, "; $av_ids .= "$av->id, ";
} }
$av_ids .= "0"; if ($vendor == "cuda") {
$av_ids .= "-3";
} else if ($vendor == "ati") {
$av_ids .= "-4";
} else if ($vendor == "intel_gpu") {
$av_ids .= "-5";
} else {
$av_ids .= "0";
}
$t = time() - 30*86400; $t = time() - 30*86400;
//echo "start enum $vendor $av_ids\n"; //echo "start enum $vendor $av_ids\n";
@ -196,7 +204,7 @@ if ($d) {
} }
page_head(tra("Top GPU models")); page_head(tra("Top GPU models"));
echo tra("The following lists show the most productive GPU models on different platforms. Relative speeds are shown in parentheses."); echo tra("The following lists show the most productive GPU models on different platforms. Relative speeds, measured by average elapsed time of tasks, are shown in parentheses.");
show_vendor("NVIDIA", $data->cuda); show_vendor("NVIDIA", $data->cuda);
show_vendor("ATI/AMD", $data->ati); show_vendor("ATI/AMD", $data->ati);
show_vendor("Intel", $data->intel_gpu); show_vendor("Intel", $data->intel_gpu);