diff options
author | Bill Wendling <wendling@ncsa.uiuc.edu> | 2002-05-02 21:06:10 (GMT) |
---|---|---|
committer | Bill Wendling <wendling@ncsa.uiuc.edu> | 2002-05-02 21:06:10 (GMT) |
commit | 143d6a5347d5ef2c5bcd4364c1331de14b3f6b75 (patch) | |
tree | 67102b918e654128f3db8f92c541a68d30d8facb /perform | |
parent | 344165d711f43310ff399102d8d3574c1b4a524f (diff) | |
download | hdf5-143d6a5347d5ef2c5bcd4364c1331de14b3f6b75.zip hdf5-143d6a5347d5ef2c5bcd4364c1331de14b3f6b75.tar.gz hdf5-143d6a5347d5ef2c5bcd4364c1331de14b3f6b75.tar.bz2 |
[svn-r5332] Purpose:
Fix
Description:
Needed to throw a few more fixes in there to get the time reporting
down.
Solution:
The time reporting is available from debugging level 4. It'll show
all the information per processor.
Platforms tested:
Linux
Diffstat (limited to 'perform')
-rw-r--r-- | perform/pio_engine.c | 55 | ||||
-rw-r--r-- | perform/pio_perf.c | 6 |
2 files changed, 28 insertions, 33 deletions
diff --git a/perform/pio_engine.c b/perform/pio_engine.c index e0d19ac..5b6bcc3 100644 --- a/perform/pio_engine.c +++ b/perform/pio_engine.c @@ -164,6 +164,10 @@ do_pio(FILE *output, parameters param) /* HDF5 variables */ herr_t hrc; /*HDF5 return code */ + int myrank; + + MPI_Comm_rank(pio_comm_g, &myrank); + /* Sanity check parameters */ /* IO type */ @@ -252,6 +256,11 @@ buf_size=MIN(1024*1024, buf_size); GOTOERROR(FAIL); } + if (pio_debug_level == 4) { + /* output all of the times for all iterations */ + output_report(output, "Timer details:\n"); + } + for (nf = 1; nf <= nfiles; nf++) { /* * Write performance measurement @@ -267,19 +276,12 @@ buf_size=MIN(1024*1024, buf_size); fprintf(stderr, "filename=%s\n", fname); #endif - if (pio_debug_level == 4) { - /* output all of the times for all iterations */ - print_indent(output, 3); - output_report(output, "Timer details:\n"); - } - set_time(res.timers, HDF5_GROSS_WRITE_FIXED_DIMS, START); if (pio_debug_level == 4) { /* output all of the times for all iterations */ - print_indent(output, 4); - output_report(output, "Gross Write Start: %.2f\n", - get_time(res.timers, HDF5_GROSS_WRITE_FIXED_DIMS)); + fprintf(output, " Proc %d: Gross Write Start: %.2f\n", + myrank, get_time(res.timers, HDF5_GROSS_WRITE_FIXED_DIMS)); } hrc = do_fopen(iot, fname, &fd, PIO_CREATE | PIO_WRITE); @@ -290,9 +292,8 @@ fprintf(stderr, "filename=%s\n", fname); if (pio_debug_level == 4) { /* output all of the times for all iterations */ - print_indent(output, 4); - output_report(output, "Fine Write Start: %.2f\n", - get_time(res.timers, HDF5_FINE_WRITE_FIXED_DIMS)); + fprintf(output, " Proc %d: Fine Write Start: %.2f\n", + myrank, get_time(res.timers, HDF5_FINE_WRITE_FIXED_DIMS)); } hrc = do_write(&fd, iot, ndsets, nelmts, buf_size, buffer); @@ -300,9 +301,8 @@ fprintf(stderr, "filename=%s\n", fname); if (pio_debug_level == 4) { /* output all of the times for all iterations */ - print_indent(output, 4); - output_report(output, "Fine Write Stop: %.2f\n", - get_time(res.timers, HDF5_FINE_WRITE_FIXED_DIMS)); + fprintf(output, " Proc %d: Fine Write Stop: %.2f\n", + myrank, get_time(res.timers, HDF5_FINE_WRITE_FIXED_DIMS)); } VRFY((hrc == SUCCESS), "do_write failed"); @@ -314,9 +314,8 @@ fprintf(stderr, "filename=%s\n", fname); if (pio_debug_level == 4) { /* output all of the times for all iterations */ - print_indent(output, 4); - output_report(output, "Gross Write Stop: %.2f\n", - get_time(res.timers, HDF5_GROSS_WRITE_FIXED_DIMS)); + fprintf(output, " Proc %d: Gross Write Stop: %.2f\n", + myrank, get_time(res.timers, HDF5_GROSS_WRITE_FIXED_DIMS)); } VRFY((hrc == SUCCESS), "do_fclose failed"); @@ -331,9 +330,8 @@ fprintf(stderr, "filename=%s\n", fname); if (pio_debug_level == 4) { /* output all of the times for all iterations */ - print_indent(output, 4); - output_report(output, "Gross Read Start: %.2f\n", - get_time(res.timers, HDF5_GROSS_READ_FIXED_DIMS)); + fprintf(output, " Proc %d: Gross Read Start: %.2f\n", + myrank, get_time(res.timers, HDF5_GROSS_READ_FIXED_DIMS)); } hrc = do_fopen(iot, fname, &fd, PIO_READ); @@ -344,9 +342,8 @@ fprintf(stderr, "filename=%s\n", fname); if (pio_debug_level == 4) { /* output all of the times for all iterations */ - print_indent(output, 4); - output_report(output, "Fine Read Start: %.2f\n", - get_time(res.timers, HDF5_FINE_READ_FIXED_DIMS)); + fprintf(output, " Proc %d: Fine Read Start: %.2f\n", + myrank, get_time(res.timers, HDF5_FINE_READ_FIXED_DIMS)); } hrc = do_read(&fd, iot, ndsets, nelmts, buf_size, buffer); @@ -354,9 +351,8 @@ fprintf(stderr, "filename=%s\n", fname); if (pio_debug_level == 4) { /* output all of the times for all iterations */ - print_indent(output, 4); - output_report(output, "Fine Read Stop: %.2f\n", - get_time(res.timers, HDF5_FINE_READ_FIXED_DIMS)); + fprintf(output, " Proc %d: Fine Read Stop: %.2f\n", + myrank, get_time(res.timers, HDF5_FINE_READ_FIXED_DIMS)); } VRFY((hrc == SUCCESS), "do_read failed"); @@ -368,9 +364,8 @@ fprintf(stderr, "filename=%s\n", fname); if (pio_debug_level == 4) { /* output all of the times for all iterations */ - print_indent(output, 4); - output_report(output, "Gross Read Stop: %.2f\n", - get_time(res.timers, HDF5_GROSS_READ_FIXED_DIMS)); + fprintf(output, " Proc %d: Gross Read Stop: %.2f\n", + myrank, get_time(res.timers, HDF5_GROSS_READ_FIXED_DIMS)); } VRFY((hrc == SUCCESS), "do_fclose failed"); diff --git a/perform/pio_perf.c b/perform/pio_perf.c index 8cee29f..de47dc1 100644 --- a/perform/pio_perf.c +++ b/perform/pio_perf.c @@ -471,7 +471,7 @@ run_test(FILE *output, iotype iot, parameters parms) double t; MPI_Barrier(pio_comm_g); - res = do_pio(parms); + res = do_pio(output, parms); /* gather all of the "write" times */ t = get_time(res.timers, HDF5_FINE_WRITE_FIXED_DIMS); @@ -833,8 +833,8 @@ parse_command_line(int argc, char *argv[]) case 'D': pio_debug_level = strtol(opt_arg, NULL, 10); - if (pio_debug_level > 3) - pio_debug_level = 3; + if (pio_debug_level > 4) + pio_debug_level = 4; else if (pio_debug_level < 0) pio_debug_level = 0; |