summaryrefslogtreecommitdiffstats
path: root/perform/pio_engine.c
diff options
context:
space:
mode:
authorBill Wendling <wendling@ncsa.uiuc.edu>2002-01-10 18:45:34 (GMT)
committerBill Wendling <wendling@ncsa.uiuc.edu>2002-01-10 18:45:34 (GMT)
commitd2c8c031d94729e505bfc709265103e1d792404c (patch)
tree8a956792e1ee16d7532a48264adf7e81288f5ec5 /perform/pio_engine.c
parent08926d9f6ed838b232c7536d072adf7c41f0bb85 (diff)
downloadhdf5-d2c8c031d94729e505bfc709265103e1d792404c.zip
hdf5-d2c8c031d94729e505bfc709265103e1d792404c.tar.gz
hdf5-d2c8c031d94729e505bfc709265103e1d792404c.tar.bz2
[svn-r4811]
Purpose: Feature Add Description: Added the time it takes from opening the file to closing the file (over all files). Platforms tested: Linux
Diffstat (limited to 'perform/pio_engine.c')
-rw-r--r--perform/pio_engine.c15
1 files changed, 5 insertions, 10 deletions
diff --git a/perform/pio_engine.c b/perform/pio_engine.c
index cebefe4..e627e21 100644
--- a/perform/pio_engine.c
+++ b/perform/pio_engine.c
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2001
+ * Copyright (C) 2001, 2002
* National Center for Supercomputing Applications
* All rights reserved.
*
@@ -148,7 +148,6 @@ results
do_pio(parameters param)
{
/* return codes */
- int mrc; /*MPI return code */
herr_t ret_code = 0; /*return code */
results res;
@@ -253,6 +252,8 @@ buf_size=MIN(1024*1024, buf_size);
GOTOERROR(FAIL);
}
+ set_time(res.timers, HDF5_FILE_OPENCLOSE, START);
+
for (nf = 1; nf <= nfiles; nf++) {
/*
* Write performance measurement
@@ -268,9 +269,7 @@ fprintf(stderr, "filename=%s\n", fname);
set_time(res.timers, HDF5_GROSS_WRITE_FIXED_DIMS, START);
- set_time(res.timers, HDF5_FILE_OPENCLOSE, START);
hrc = do_fopen(iot, fname, &fd, PIO_CREATE | PIO_WRITE);
- set_time(res.timers, HDF5_FILE_OPENCLOSE, STOP);
VRFY((hrc == SUCCESS), "do_fopen failed");
@@ -281,9 +280,7 @@ fprintf(stderr, "filename=%s\n", fname);
VRFY((hrc == SUCCESS), "do_write failed");
/* Close file for write */
- set_time(res.timers, HDF5_FILE_OPENCLOSE, START);
hrc = do_fclose(iot, &fd);
- set_time(res.timers, HDF5_FILE_OPENCLOSE, STOP);
set_time(res.timers, HDF5_GROSS_WRITE_FIXED_DIMS, STOP);
@@ -295,9 +292,7 @@ fprintf(stderr, "filename=%s\n", fname);
/* Open file for read */
set_time(res.timers, HDF5_GROSS_READ_FIXED_DIMS, START);
- set_time(res.timers, HDF5_FILE_OPENCLOSE, START);
hrc = do_fopen(iot, fname, &fd, PIO_READ);
- set_time(res.timers, HDF5_FILE_OPENCLOSE, STOP);
VRFY((hrc == SUCCESS), "do_fopen failed");
@@ -308,9 +303,7 @@ fprintf(stderr, "filename=%s\n", fname);
VRFY((hrc == SUCCESS), "do_read failed");
/* Close file for read */
- set_time(res.timers, HDF5_FILE_OPENCLOSE, START);
hrc = do_fclose(iot, &fd);
- set_time(res.timers, HDF5_FILE_OPENCLOSE, STOP);
set_time(res.timers, HDF5_GROSS_READ_FIXED_DIMS, STOP);
@@ -319,6 +312,8 @@ fprintf(stderr, "filename=%s\n", fname);
do_cleanupfile(iot, fname);
}
+ set_time(res.timers, HDF5_FILE_OPENCLOSE, STOP);
+
done:
/* clean up */
/* release HDF5 objects */