summaryrefslogtreecommitdiffstats
path: root/perform
diff options
context:
space:
mode:
Diffstat (limited to 'perform')
-rw-r--r--perform/pio_engine.c26
-rw-r--r--perform/pio_perf.c8
-rw-r--r--perform/pio_perf.h4
3 files changed, 19 insertions, 19 deletions
diff --git a/perform/pio_engine.c b/perform/pio_engine.c
index cbd77e7..dfcb465 100644
--- a/perform/pio_engine.c
+++ b/perform/pio_engine.c
@@ -147,7 +147,7 @@ do_pio(parameters param)
char fname[FILENAME_MAX];
int maxprocs;
- int nfiles, nf;
+ long nfiles, nf;
long ndsets;
off_t nelmts;
char *buffer = NULL; /*data buffer pointer */
@@ -190,7 +190,7 @@ do_pio(parameters param)
if (nfiles < 0 ) {
fprintf(stderr,
- "number of files must be >= 0 (%d)\n",
+ "number of files must be >= 0 (%ld)\n",
nfiles);
GOTOERROR(FAIL);
}
@@ -253,7 +253,7 @@ do_pio(parameters param)
MPI_Barrier(pio_comm_g);
- sprintf(base_name, "#pio_tmp_%u", nf);
+ sprintf(base_name, "#pio_tmp_%lu", nf);
pio_create_filename(iot, base_name, fname, sizeof(fname));
set_time(res.timers, HDF5_GROSS_WRITE_FIXED_DIMS, START);
@@ -488,7 +488,7 @@ do_write(results *res, file_descr *fd, parameters *parms, long ndsets,
#endif
/* calculate dataset parameters. data type is always native C int */
- dset_size = nelmts * ELMT_SIZE;
+ dset_size = nelmts * (off_t)ELMT_SIZE;
nelmts_in_buf = buf_size/ELMT_SIZE;
/* hdf5 data space setup */
@@ -692,7 +692,7 @@ do_write(results *res, file_descr *fd, parameters *parms, long ndsets,
/* Contiguous pattern */
/* need to (off_t) the elmnts_begin expression because they */
/* may be of smaller sized integer types */
- file_offset = dset_offset + (off_t)(elmts_begin + nelmts_xfer)*ELMT_SIZE;
+ file_offset = dset_offset + (off_t)(elmts_begin + nelmts_xfer)*(off_t)ELMT_SIZE;
/* only care if seek returns error */
rc = POSIXSEEK(fd->posixfd, file_offset) < 0 ? -1 : 0;
@@ -707,7 +707,7 @@ do_write(results *res, file_descr *fd, parameters *parms, long ndsets,
size_t xferred=0;
size_t toxfer=0;
- file_offset = dset_offset + (off_t)(elmts_begin + nelmts_xfer)*ELMT_SIZE;
+ file_offset = dset_offset + (off_t)(elmts_begin + nelmts_xfer)*(off_t)ELMT_SIZE;
if (pio_debug_level >= 4) {
HDprint_rank(output);
HDfprintf(output,
@@ -723,7 +723,7 @@ HDfprintf(output,
toxfer = nelmts_toxfer - xferred;
/* Skip offset over blocks of other processes */
file_offset = dset_offset +
- (off_t)(elmts_begin + (nelmts_xfer+xferred)*pio_mpi_nprocs_g)*ELMT_SIZE;
+ (off_t)(elmts_begin + (nelmts_xfer+xferred)*pio_mpi_nprocs_g)*(off_t)ELMT_SIZE;
if (pio_debug_level >= 4) {
HDprint_rank(output);
HDfprintf(output,
@@ -749,7 +749,7 @@ HDfprintf(output,
break;
case MPIO:
- mpi_offset = dset_offset + (elmts_begin + nelmts_xfer)*ELMT_SIZE;
+ mpi_offset = dset_offset + (elmts_begin + nelmts_xfer)*(off_t)ELMT_SIZE;
mrc = MPI_File_write_at(fd->mpifd, mpi_offset, buffer,
(int)(nelmts_toxfer), ELMT_MPI_TYPE,
&mpi_status);
@@ -872,7 +872,7 @@ do_read(results *res, file_descr *fd, parameters *parms, long ndsets,
#endif
/* calculate dataset parameters. data type is always native C int */
- dset_size = nelmts * ELMT_SIZE;
+ dset_size = nelmts * (off_t)ELMT_SIZE;
nelmts_in_buf = buf_size/ELMT_SIZE;
/* hdf5 data space setup */
@@ -1029,7 +1029,7 @@ do_read(results *res, file_descr *fd, parameters *parms, long ndsets,
/* Contiguous pattern */
/* need to (off_t) the elmnts_begin expression because they */
/* may be of smaller sized integer types */
- file_offset = dset_offset + (off_t)(elmts_begin + nelmts_xfer)*ELMT_SIZE;
+ file_offset = dset_offset + (off_t)(elmts_begin + nelmts_xfer)*(off_t)ELMT_SIZE;
/* only care if seek returns error */
rc = POSIXSEEK(fd->posixfd, file_offset) < 0 ? -1 : 0;
@@ -1044,7 +1044,7 @@ do_read(results *res, file_descr *fd, parameters *parms, long ndsets,
size_t xferred=0;
size_t toxfer=0;
- file_offset = dset_offset + (off_t)(elmts_begin + nelmts_xfer)*ELMT_SIZE;
+ file_offset = dset_offset + (off_t)(elmts_begin + nelmts_xfer)*(off_t)ELMT_SIZE;
if (pio_debug_level >= 4) {
HDprint_rank(output);
HDfprintf(output,
@@ -1060,7 +1060,7 @@ HDfprintf(output,
toxfer = nelmts_toxfer - xferred;
/* Skip offset over blocks of other processes */
file_offset = dset_offset +
- (off_t)(elmts_begin + (nelmts_xfer+xferred)*pio_mpi_nprocs_g)*ELMT_SIZE;
+ (off_t)(elmts_begin + (nelmts_xfer+xferred)*pio_mpi_nprocs_g)*(off_t)ELMT_SIZE;
if (pio_debug_level >= 4) {
HDprint_rank(output);
HDfprintf(output,
@@ -1086,7 +1086,7 @@ HDfprintf(output,
break;
case MPIO:
- mpi_offset = dset_offset + (elmts_begin + nelmts_xfer)*ELMT_SIZE;
+ mpi_offset = dset_offset + (elmts_begin + nelmts_xfer)*(off_t)ELMT_SIZE;
mrc = MPI_File_read_at(fd->mpifd, mpi_offset, buffer,
(int)(nelmts_toxfer), ELMT_MPI_TYPE,
diff --git a/perform/pio_perf.c b/perform/pio_perf.c
index f27cec9..f0b158c 100644
--- a/perform/pio_perf.c
+++ b/perform/pio_perf.c
@@ -246,7 +246,7 @@ struct options {
off_t file_size; /* size of file */
long num_dsets; /* number of datasets */
long num_files; /* number of files */
- long num_iters; /* number of iterations */
+ int num_iters; /* number of iterations */
int max_num_procs; /* maximum number of processes to use */
int min_num_procs; /* minimum number of processes to use */
size_t max_xfer_size; /* maximum transfer buffer size */
@@ -698,7 +698,7 @@ run_test(iotype iot, parameters parms, struct options *opts)
static void
output_all_info(minmax *mm, int count, int indent_level)
{
- register int i;
+ int i;
for (i = 0; i < count; ++i) {
print_indent(indent_level);
@@ -743,7 +743,7 @@ get_minmax(minmax *mm, double val)
static minmax
accumulate_minmax_stuff(minmax *mm, int count)
{
- register int i;
+ int i;
minmax total_mm;
total_mm.sum = 0.0;
@@ -864,7 +864,7 @@ output_results(const struct options *opts, const char *name, minmax *table,
total_mm = accumulate_minmax_stuff(table, table_size);
print_indent(3);
- output_report("%s (%d iteration(s)):\n", name,(int)table_size);
+ output_report("%s (%d iteration(s)):\n", name,table_size);
/* Note: The maximum throughput uses the minimum amount of time & vice versa */
diff --git a/perform/pio_perf.h b/perform/pio_perf.h
index e812f16..b9284df 100644
--- a/perform/pio_perf.h
+++ b/perform/pio_perf.h
@@ -26,10 +26,10 @@ typedef enum iotype_ {
typedef struct parameters_ {
iotype io_type; /* The type of IO test to perform */
int num_procs; /* Maximum number of processes to use */
- int num_files; /* Number of files to create */
+ long num_files; /* Number of files to create */
long num_dsets; /* Number of datasets to create */
off_t num_elmts; /* Number of native ints in each dset */
- int num_iters; /* Number of times to loop doing the IO */
+ int num_iters; /* Number of times to loop doing the IO */
size_t buf_size; /* Buffer size */
size_t block_size; /* interleaved block size */
hsize_t h5_align; /* HDF5 object alignment */