Add time prints in benchmark output

This commit is contained in:
Ashwin Sekhar T K 2016-07-14 13:48:13 +05:30
parent 925d4e1dc6
commit 8d86d14d3f
10 changed files with 20 additions and 20 deletions

View File

@ -183,9 +183,9 @@ int main(int argc, char *argv[]){
timeg /= loops; timeg /= loops;
#ifdef COMPLEX #ifdef COMPLEX
fprintf(stderr, " %10.2f MFlops\n", 4. * (double)m / timeg * 1.e-6); fprintf(stderr, " %10.2f MFlops %10.6f sec\n", 4. * (double)m / timeg * 1.e-6, timeg);
#else #else
fprintf(stderr, " %10.2f MFlops\n", 2. * (double)m / timeg * 1.e-6); fprintf(stderr, " %10.2f MFlops %10.6f sec\n", 2. * (double)m / timeg * 1.e-6, timeg);
#endif #endif
} }

View File

@ -190,8 +190,8 @@ int main(int argc, char *argv[]){
timeg /= loops; timeg /= loops;
fprintf(stderr, fprintf(stderr,
" %10.2f MFlops\n", " %10.2f MFlops %10.6f sec\n",
COMPSIZE * COMPSIZE * 2. * (double)m / timeg * 1.e-6); COMPSIZE * COMPSIZE * 2. * (double)m / timeg * 1.e-6, timeg);
} }

View File

@ -190,8 +190,8 @@ int main(int argc, char *argv[]){
timeg /= loops; timeg /= loops;
fprintf(stderr, fprintf(stderr,
" %10.2f MBytes\n", " %10.2f MBytes %10.6f sec\n",
COMPSIZE * sizeof(FLOAT) * 1. * (double)m / timeg * 1.e-6); COMPSIZE * sizeof(FLOAT) * 1. * (double)m / timeg * 1.e-6, timeg);
} }

View File

@ -184,8 +184,8 @@ int main(int argc, char *argv[]){
timeg /= loops; timeg /= loops;
fprintf(stderr, fprintf(stderr,
" %10.2f MFlops\n", " %10.2f MFlops %10.6f sec\n",
COMPSIZE * COMPSIZE * 2. * (double)m / timeg * 1.e-6); COMPSIZE * COMPSIZE * 2. * (double)m / timeg * 1.e-6, timeg);
} }

View File

@ -221,7 +221,7 @@ int main(int argc, char *argv[]){
timeg /= loops; timeg /= loops;
fprintf(stderr, " %10.2f MFlops\n", COMPSIZE * COMPSIZE * 2. * (double)m * (double)n / timeg * 1.e-6); fprintf(stderr, " %10.2f MFlops %10.6f sec\n", COMPSIZE * COMPSIZE * 2. * (double)m * (double)n / timeg * 1.e-6, timeg);
} }
} }
@ -258,7 +258,7 @@ int main(int argc, char *argv[]){
timeg /= loops; timeg /= loops;
fprintf(stderr, " %10.2f MFlops\n", COMPSIZE * COMPSIZE * 2. * (double)m * (double)n / timeg * 1.e-6); fprintf(stderr, " %10.2f MFlops %10.6f sec\n", COMPSIZE * COMPSIZE * 2. * (double)m * (double)n / timeg * 1.e-6, timeg);
} }
} }

View File

@ -186,8 +186,8 @@ int main(int argc, char *argv[]){
timeg /= loops; timeg /= loops;
fprintf(stderr, fprintf(stderr,
" %10.2f MFlops\n", " %10.2f MFlops %10.6f sec\n",
COMPSIZE * COMPSIZE * 6. * (double)m / timeg * 1.e-6); COMPSIZE * COMPSIZE * 6. * (double)m / timeg * 1.e-6, timeg);
} }

View File

@ -189,9 +189,9 @@ int main(int argc, char *argv[]){
timeg /= loops; timeg /= loops;
#ifdef COMPLEX #ifdef COMPLEX
fprintf(stderr, " %10.2f MFlops\n", 6. * (double)m / timeg * 1.e-6); fprintf(stderr, " %10.2f MFlops %10.6f sec\n", 6. * (double)m / timeg * 1.e-6, timeg);
#else #else
fprintf(stderr, " %10.2f MFlops\n", 1. * (double)m / timeg * 1.e-6); fprintf(stderr, " %10.2f MFlops %10.6f sec\n", 1. * (double)m / timeg * 1.e-6, timeg);
#endif #endif
} }

View File

@ -190,8 +190,8 @@ int main(int argc, char *argv[]){
timeg /= loops; timeg /= loops;
fprintf(stderr, fprintf(stderr,
" %10.2f MBytes\n", " %10.2f MBytes %10.6f sec\n",
COMPSIZE * sizeof(FLOAT) * 1. * (double)m / timeg * 1.e-6); COMPSIZE * sizeof(FLOAT) * 1. * (double)m / timeg * 1.e-6, timeg);
} }

View File

@ -191,8 +191,8 @@ int main(int argc, char *argv[]){
gettimeofday( &start, (struct timezone *)0); gettimeofday( &start, (struct timezone *)0);
fprintf(stderr, fprintf(stderr,
" %10.2f MFlops\n", " %10.2f MFlops %10.6f sec\n",
COMPSIZE * COMPSIZE * 1. * (double)m * (double)m * (double)m / time1 * 1.e-6); COMPSIZE * COMPSIZE * 1. * (double)m * (double)m * (double)m / time1 * 1.e-6, time1);
} }

View File

@ -184,8 +184,8 @@ int main(int argc, char *argv[]){
timeg /= loops; timeg /= loops;
fprintf(stderr, fprintf(stderr,
" %10.2f MFlops\n", " %10.2f MFlops %10.6f sec\n",
COMPSIZE * COMPSIZE * 2. * (double)m / timeg * 1.e-6); COMPSIZE * COMPSIZE * 2. * (double)m / timeg * 1.e-6, timeg);
} }