diff options
author | Albert Cheng <acheng@hdfgroup.org> | 2002-01-07 20:58:39 (GMT) |
---|---|---|
committer | Albert Cheng <acheng@hdfgroup.org> | 2002-01-07 20:58:39 (GMT) |
commit | 34d711cec574ece7ea89a096e0e032809fd85644 (patch) | |
tree | 9f7dcad62cc4af918a9ca07115a79c49e8650a05 | |
parent | ccf3135df05f97ed720481d4a5687953c6f86800 (diff) | |
download | hdf5-34d711cec574ece7ea89a096e0e032809fd85644.zip hdf5-34d711cec574ece7ea89a096e0e032809fd85644.tar.gz hdf5-34d711cec574ece7ea89a096e0e032809fd85644.tar.bz2 |
[svn-r4792] Purpose:
Extension
Description:
int64_t type is not available everywhere.
#include H5private.h which has platform dependent hooks
to define int64_t to something available.
Platforms tested:
Tflops, modi4 (parallel), eirene(PP)
-rw-r--r-- | perform/mpi-perf.c | 16 | ||||
-rw-r--r-- | perform/perf.c | 1 |
2 files changed, 9 insertions, 8 deletions
diff --git a/perform/mpi-perf.c b/perform/mpi-perf.c index 52f4041..b17ed4b 100644 --- a/perform/mpi-perf.c +++ b/perform/mpi-perf.c @@ -8,7 +8,7 @@ */ #include "hdf5.h" - +#include "H5private.h" #ifdef H5_HAVE_PARALLEL /* mpi-perf.c * @@ -28,7 +28,6 @@ * the processes that make up the parallel job, which isn't always the case. * So if it doesn't work on some platform, that might be why. */ - /* Modifications: * Albert Cheng, Apr 30, 20001 * Changed MPI_File_open to use MPI_COMM_WORLD (was MPI_COMM_SELF). @@ -46,13 +45,14 @@ #include <string.h> #include <sys/time.h> #include <mpi.h> - #ifndef MPI_FILE_NULL /*MPIO may be defined in mpi.h already */ # include <mpio.h> #endif + + /* DEFAULT VALUES FOR OPTIONS */ -long opt_block = 1048576*16; +int64_t opt_block = 1048576*16; int opt_iter = 1; int opt_stripe = -1; int opt_correct = 0; @@ -83,8 +83,8 @@ int main(int argc, char **argv) double max_read_tim, max_write_tim; double min_read_tim, min_write_tim; double ave_read_tim, ave_write_tim; - long iter_jump = 0; - long seek_position = 0; + int64_t iter_jump = 0; + int64_t seek_position = 0; MPI_File fh; MPI_Status status; int nchars; @@ -260,8 +260,8 @@ int main(int argc, char **argv) /* print out the results on one node */ if (mynod == 0) { - read_bw = ((long)(opt_block*nprocs*opt_iter))/(max_read_tim*1000000.0); - write_bw = ((long)(opt_block*nprocs*opt_iter))/(max_write_tim*1000000.0); + read_bw = ((int64_t)(opt_block*nprocs*opt_iter))/(max_read_tim*1000000.0); + write_bw = ((int64_t)(opt_block*nprocs*opt_iter))/(max_write_tim*1000000.0); printf("nr_procs = %d, nr_iter = %d, blk_sz = %ld\n", nprocs, opt_iter, (long)opt_block); diff --git a/perform/perf.c b/perform/perf.c index ece160a..3aaa5ba 100644 --- a/perform/perf.c +++ b/perform/perf.c @@ -8,6 +8,7 @@ */ #include "hdf5.h" +#include "H5private.h" #ifdef H5_HAVE_PARALLEL #include <stdio.h> #include <stdlib.h> |