summaryrefslogtreecommitdiffstats
path: root/perform
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2010-05-27 22:57:29 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2010-05-27 22:57:29 (GMT)
commite4246519c9d59a5f837f2b1009471533b729b778 (patch)
tree0ed23bfb58157edccfa11487a6c9f293b9e97670 /perform
parentfc3de1ec794584b1bdc6e615d8d2afc15f5bb5ec (diff)
downloadhdf5-e4246519c9d59a5f837f2b1009471533b729b778.zip
hdf5-e4246519c9d59a5f837f2b1009471533b729b778.tar.gz
hdf5-e4246519c9d59a5f837f2b1009471533b729b778.tar.bz2
[svn-r18920] Description:
Bring r18917 from trunk to 1.8 branch: Bring r18911 (plus some adaptions to match the code on the trunk) from the metadata journaling "merging" branch to the trunk: More general changes to align trunk with eventual changes from metadata journaling branch. Tested on: FreeBSD/32 6.3 (duty) in debug mode FreeBSD/64 6.3 (liberty) w/C++ & FORTRAN, in debug mode Linux/32 2.6 (jam) w/PGI compilers, w/default API=1.8.x, w/C++ & FORTRAN, w/threadsafe, in debug mode Linux/64-amd64 2.6 (amani) w/Intel compilers, w/default API=1.6.x, w/C++ & FORTRAN, in production mode
Diffstat (limited to 'perform')
-rw-r--r--perform/benchpar.c18
1 files changed, 3 insertions, 15 deletions
diff --git a/perform/benchpar.c b/perform/benchpar.c
index 3ebbe6b..035e9d6 100644
--- a/perform/benchpar.c
+++ b/perform/benchpar.c
@@ -167,9 +167,9 @@ int main(int argc, char *argv[])
int curr_arg; /* Current command line argument being processed */
int rank; /* Number of dimensions of the dataset */
hsize_t dim_size; /* Dimension size of each dimension */
- hsize_t *dims; /* Pointer to array of dimensions */
- hssize_t *start; /* Pointer to array of starting locations for hyperslab selection */
- hsize_t *count; /* Pointer to array of counts for hyperslab selection */
+ hsize_t dims[H5S_MAX_RANK]; /* Pointer to array of dimensions */
+ hsize_t start[H5S_MAX_RANK]; /* Pointer to array of starting locations for hyperslab selection */
+ hsize_t count[H5S_MAX_RANK]; /* Pointer to array of counts for hyperslab selection */
unsigned slice_dim; /* Dimension to slice up */
char *file_name=NULL; /* Name of file to put data into */
hid_t fcpl; /* HDF5 File creation property list ID */
@@ -365,8 +365,6 @@ int main(int argc, char *argv[])
assert(ret>=0);
/* Create dataspace for dataset on disk */
- dims=malloc(sizeof(hsize_t)*rank);
- assert(dims);
for(i=0; i<rank; i++)
dims[i]=dim_size;
@@ -394,10 +392,6 @@ int main(int argc, char *argv[])
assert(ret>=0);
/* Select hyperslab for file dataspace */
- start=malloc(sizeof(hssize_t)*rank);
- assert(start);
- count=malloc(sizeof(hsize_t)*rank);
- assert(count);
for(i=0; i<rank; i++) {
start[i]=0;
count[i]=dim_size;
@@ -494,12 +488,6 @@ done:
free(file_name);
if(buf)
free(buf);
- if(dims)
- free(dims);
- if(start)
- free(start);
- if(count)
- free(count);
/* MPI termination */
MPI_Finalize();