Merge pull request #220 from jyvet/outliers

Display outlier host names
master
Julian Kunkel 2020-03-17 15:47:13 +00:00 committed by GitHub
commit 3562a354ad
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 7 additions and 2 deletions

View File

@ -255,8 +255,13 @@ DisplayOutliers(int numTasks,
strcpy(accessString, "read");
}
if (fabs(timerVal - mean) > (double)outlierThreshold) {
fprintf(out_logfile, "WARNING: for task %d, %s %s is %f\n",
rank, accessString, timeString, timerVal);
char hostname[MAX_STR];
int ret = gethostname(hostname, MAX_STR);
if (ret != 0)
strcpy(hostname, "unknown");
fprintf(out_logfile, "WARNING: for %s, task %d, %s %s is %f\n",
hostname, rank, accessString, timeString, timerVal);
fprintf(out_logfile, " (mean=%f, stddev=%f)\n", mean, sd);
fflush(out_logfile);
}