summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--c++/src/H5DataType.cpp2
-rw-r--r--c++/src/H5DcreatProp.cpp12
-rw-r--r--c++/src/H5IdComponent.cpp2
-rw-r--r--c++/src/Makefile.am2
-rw-r--r--c++/test/Makefile.am6
-rw-r--r--c++/test/tattr.cpp2
-rw-r--r--fortran/src/H5match_types.c8
-rw-r--r--fortran/src/Makefile.am2
-rw-r--r--fortran/test/t.c4
-rw-r--r--hl/c++/src/Makefile.am2
-rw-r--r--hl/c++/test/Makefile.am2
-rw-r--r--hl/examples/ex_ds1.c4
-rw-r--r--hl/examples/ex_image1.c16
-rw-r--r--hl/examples/ex_image2.c12
-rw-r--r--hl/examples/ex_lite1.c10
-rw-r--r--hl/examples/ex_lite2.c10
-rw-r--r--hl/examples/ex_lite3.c12
-rw-r--r--hl/examples/ex_table_01.c36
-rw-r--r--hl/examples/ex_table_02.c28
-rw-r--r--hl/examples/ex_table_03.c42
-rw-r--r--hl/examples/ex_table_04.c58
-rw-r--r--hl/examples/ex_table_05.c56
-rw-r--r--hl/examples/ex_table_06.c22
-rw-r--r--hl/examples/ex_table_07.c34
-rw-r--r--hl/examples/ex_table_08.c42
-rw-r--r--hl/examples/ex_table_09.c46
-rw-r--r--hl/examples/ex_table_10.c44
-rw-r--r--hl/examples/ex_table_11.c40
-rw-r--r--hl/examples/ex_table_12.c36
-rw-r--r--hl/fortran/src/Makefile.am6
-rw-r--r--hl/src/H5DS.c50
-rw-r--r--hl/src/H5LT.c54
-rw-r--r--hl/src/H5LTanalyze.c20
-rw-r--r--hl/src/H5LTparse.c50
-rw-r--r--hl/src/H5LTprivate.h4
-rw-r--r--hl/src/H5PTprivate.h2
-rw-r--r--hl/src/H5TB.c34
-rw-r--r--hl/test/test_lite.c170
-rw-r--r--perform/benchpar.c6
-rw-r--r--perform/pio_engine.c32
-rw-r--r--perform/pio_perf.c8
-rw-r--r--perform/pio_standalone.c2
-rw-r--r--perform/pio_timer.c12
-rw-r--r--src/H5.c6
-rw-r--r--src/H5A.c4
-rw-r--r--src/H5AC.c316
-rw-r--r--src/H5ACpkg.h110
-rw-r--r--src/H5ACprivate.h4
-rw-r--r--src/H5ACpublic.h30
-rw-r--r--src/H5B2private.h2
-rw-r--r--src/H5Bprivate.h2
-rw-r--r--src/H5C.c306
-rw-r--r--src/H5CS.c8
-rw-r--r--src/H5Cpkg.h48
-rw-r--r--src/H5Cprivate.h38
-rw-r--r--src/H5D.c2
-rw-r--r--src/H5Dcompact.c6
-rw-r--r--src/H5Dcontig.c4
-rw-r--r--src/H5Dio.c20
-rw-r--r--src/H5Distore.c26
-rw-r--r--src/H5Dmpio.c276
-rw-r--r--src/H5Doh.c2
-rw-r--r--src/H5E.c26
-rw-r--r--src/H5Eterm.h266
-rw-r--r--src/H5F.c6
-rw-r--r--src/H5FDfamily.c2
-rw-r--r--src/H5FDmpi.h4
-rw-r--r--src/H5FDmpio.c36
-rw-r--r--src/H5FDmpiposix.c10
-rw-r--r--src/H5FDmulti.c2
-rw-r--r--src/H5FS.c2
-rw-r--r--src/H5FSprivate.h2
-rw-r--r--src/H5G.c40
-rw-r--r--src/H5Gloc.c2
-rw-r--r--src/H5Gname.c2
-rw-r--r--src/H5Gnode.c6
-rw-r--r--src/H5Gobj.c4
-rw-r--r--src/H5Gpublic.h2
-rw-r--r--src/H5HFcache.c4
-rw-r--r--src/H5HFhdr.c2
-rw-r--r--src/H5HFiter.c2
-rw-r--r--src/H5HFprivate.h2
-rw-r--r--src/H5HL.c20
-rw-r--r--src/H5O.c122
-rw-r--r--src/H5Oattr.c32
-rw-r--r--src/H5Ocont.c8
-rw-r--r--src/H5Odtype.c4
-rw-r--r--src/H5Oefl.c8
-rw-r--r--src/H5Olayout.c10
-rw-r--r--src/H5Olinfo.c2
-rw-r--r--src/H5Olink.c16
-rw-r--r--src/H5Opkg.h6
-rw-r--r--src/H5Opline.c4
-rw-r--r--src/H5Oprivate.h6
-rw-r--r--src/H5Oshared.c12
-rw-r--r--src/H5Ostab.c18
-rwxr-xr-xsrc/H5Pocpl.c14
-rw-r--r--src/H5Shyper.c12
-rw-r--r--src/H5Stest.c6
-rw-r--r--src/H5T.c34
-rw-r--r--src/H5Tconv.c42
-rw-r--r--src/H5Tpkg.h24
-rw-r--r--src/H5Vprivate.h10
-rw-r--r--src/H5private.h2
-rw-r--r--test/Makefile.am2
-rw-r--r--test/cache.c116
-rw-r--r--test/cache_api.c2
-rw-r--r--test/cache_common.c62
-rw-r--r--test/cache_common.h8
-rwxr-xr-xtest/cross_read.c4
-rw-r--r--test/dt_arith.c48
-rw-r--r--test/dtypes.c22
-rw-r--r--test/enum.c4
-rw-r--r--test/fheap.c38
-rw-r--r--test/h5test.c6
-rw-r--r--test/links.c2
-rwxr-xr-xtest/objcopy.c480
-rw-r--r--test/stab.c8
-rw-r--r--test/testframe.c4
-rw-r--r--test/tfile.c18
-rw-r--r--test/tselect.c152
-rw-r--r--test/ttsafe_acreate.c2
-rw-r--r--test/ttsafe_cancel.c4
-rw-r--r--test/tvltypes.c4
-rw-r--r--testpar/t_cache.c550
-rw-r--r--testpar/t_chunk_alloc.c34
-rw-r--r--testpar/t_coll_chunk.c110
-rw-r--r--testpar/t_mpi.c18
-rw-r--r--testpar/t_posix_compliant.c90
-rw-r--r--testpar/t_span_tree.c54
-rw-r--r--testpar/testphdf5.c8
-rw-r--r--tools/h5diff/Makefile.am2
-rw-r--r--tools/h5diff/h5diff_common.c32
-rw-r--r--tools/h5diff/h5diff_main.c10
-rw-r--r--tools/h5diff/h5diffgentest.c22
-rw-r--r--tools/h5dump/h5dump.c20
-rw-r--r--tools/h5dump/h5dumpgentest.c14
-rw-r--r--tools/h5ls/h5ls.c6
-rw-r--r--tools/h5repack/h5repack.c2
-rw-r--r--tools/h5repack/h5repack.h8
-rw-r--r--tools/h5repack/h5repack_copy.c22
-rw-r--r--tools/h5repack/h5repack_filters.c18
-rw-r--r--tools/h5repack/h5repack_list.c2
-rw-r--r--tools/h5repack/h5repack_parse.c4
-rw-r--r--tools/lib/h5diff.c264
-rw-r--r--tools/lib/h5diff_array.c838
-rw-r--r--tools/lib/h5diff_attr.c52
-rw-r--r--tools/lib/h5diff_dset.c20
-rw-r--r--tools/lib/h5diff_util.c14
-rw-r--r--tools/lib/h5tools.c8
-rw-r--r--tools/misc/h5stat.c30
151 files changed, 3162 insertions, 3162 deletions
diff --git a/c++/src/H5DataType.cpp b/c++/src/H5DataType.cpp
index af05632..609e2f9 100644
--- a/c++/src/H5DataType.cpp
+++ b/c++/src/H5DataType.cpp
@@ -198,7 +198,7 @@ void DataType::commit(CommonFG& loc, const H5std_string& name) const
// Function: DataType::committed
///\brief Determines whether a datatype is a named type or a
/// transient type.
-///\return \c true if the datatype is a named type, and \c false,
+///\return \c true if the datatype is a named type, and \c false,
/// otherwise.
///\exception H5::DataTypeIException
// Programmer Binh-Minh Ribler - 2000
diff --git a/c++/src/H5DcreatProp.cpp b/c++/src/H5DcreatProp.cpp
index 5f5bceb..bc9fb03 100644
--- a/c++/src/H5DcreatProp.cpp
+++ b/c++/src/H5DcreatProp.cpp
@@ -262,7 +262,7 @@ H5D_fill_value_t DSetCreatPropList::isFillValueDefined()
/// and the filter fails then the entire I/O operation fails.
// Programmer Binh-Minh Ribler - 2000
//--------------------------------------------------------------------------
-void DSetCreatPropList::setFilter( H5Z_filter_t filter_id, unsigned int flags,
+void DSetCreatPropList::setFilter( H5Z_filter_t filter_id, unsigned int flags,
size_t cd_nelmts, const unsigned int cd_values[] ) const
{
herr_t ret_value = H5Pset_filter( id, filter_id, flags, cd_nelmts, cd_values );
@@ -329,8 +329,8 @@ int DSetCreatPropList::getNfilters() const
///\par Description
/// Failure occurs when \a filter_number is out of range.
//--------------------------------------------------------------------------
-H5Z_filter_t DSetCreatPropList::getFilter(int filter_number,
- unsigned int &flags, size_t &cd_nelmts, unsigned int* cd_values,
+H5Z_filter_t DSetCreatPropList::getFilter(int filter_number,
+ unsigned int &flags, size_t &cd_nelmts, unsigned int* cd_values,
size_t namelen, char name[], unsigned int& filter_config) const
{
H5Z_filter_t filter_id;
@@ -360,8 +360,8 @@ H5Z_filter_t DSetCreatPropList::getFilter(int filter_number,
///\exception H5::PropListIException
// Programmer Binh-Minh Ribler - 2000
//--------------------------------------------------------------------------
-void DSetCreatPropList::getFilterById(H5Z_filter_t filter_id,
- unsigned int &flags, size_t &cd_nelmts, unsigned int* cd_values,
+void DSetCreatPropList::getFilterById(H5Z_filter_t filter_id,
+ unsigned int &flags, size_t &cd_nelmts, unsigned int* cd_values,
size_t namelen, char name[], unsigned int &filter_config) const
{
herr_t ret_value = H5Pget_filter_by_id(id, filter_id, &flags, &cd_nelmts,
@@ -394,7 +394,7 @@ void DSetCreatPropList::getFilterById(H5Z_filter_t filter_id,
/// and the filter fails then the entire I/O operation fails.
// Programmer Binh-Minh Ribler - 2000
//--------------------------------------------------------------------------
-void DSetCreatPropList::modifyFilter( H5Z_filter_t filter_id, unsigned int
+void DSetCreatPropList::modifyFilter( H5Z_filter_t filter_id, unsigned int
flags, size_t cd_nelmts, const unsigned int cd_values[] ) const
{
herr_t ret_value = H5Pmodify_filter(id, filter_id, flags, cd_nelmts, cd_values);
diff --git a/c++/src/H5IdComponent.cpp b/c++/src/H5IdComponent.cpp
index 86f34d1..03c7809 100644
--- a/c++/src/H5IdComponent.cpp
+++ b/c++/src/H5IdComponent.cpp
@@ -255,7 +255,7 @@ H5std_string IdComponent::inMemFunc(const char* func_name) const
{
#ifdef H5_VMS
H5std_string full_name = fromClass();
- full_name.append("::");
+ full_name.append("::");
full_name.append(func_name);
#else
H5std_string full_name = func_name;
diff --git a/c++/src/Makefile.am b/c++/src/Makefile.am
index 924d25c..411b4f5 100644
--- a/c++/src/Makefile.am
+++ b/c++/src/Makefile.am
@@ -15,7 +15,7 @@
## Run automake to generate a Makefile.in from this file.
#
# HDF5-C++ Makefile(.in)
-#
+#
include $(top_srcdir)/config/commence.am
diff --git a/c++/test/Makefile.am b/c++/test/Makefile.am
index 35de101..814c7eb 100644
--- a/c++/test/Makefile.am
+++ b/c++/test/Makefile.am
@@ -15,7 +15,7 @@
## Run automake to generate a Makefile.in from this file.
#
# HDF5-C++ Makefile(.in)
-#
+#
include $(top_srcdir)/config/commence.am
@@ -42,10 +42,10 @@ testhdf5_SOURCES=testhdf5.cpp tattr.cpp tfile.cpp th5s.cpp h5cpputil.cpp
# Tell conclude.am that these are C++ tests.
HDF_CXX=yes
-# Some C++ compilers/linkers (PGI?) create a directory named "ii_files" that
+# Some C++ compilers/linkers (PGI?) create a directory named "ii_files" that
# holds *.ii files, which are template entity instantiations.
# This entire directory should be cleaned.
-mostlyclean-local:
+mostlyclean-local:
@if test -d ii_files; then \
$(RM) -rf ii_files; \
fi
diff --git a/c++/test/tattr.cpp b/c++/test/tattr.cpp
index e327493..7402e30 100644
--- a/c++/test/tattr.cpp
+++ b/c++/test/tattr.cpp
@@ -1012,7 +1012,7 @@ test_attr_delete(void)
/****************************************************************
**
-** test_attr_dtype_shared(): Test code for using shared datatypes
+** test_attr_dtype_shared(): Test code for using shared datatypes
** in attributes.
**
****************************************************************/
diff --git a/fortran/src/H5match_types.c b/fortran/src/H5match_types.c
index 597f467..7d969ad 100644
--- a/fortran/src/H5match_types.c
+++ b/fortran/src/H5match_types.c
@@ -160,7 +160,7 @@ int main()
/* First, define c_int_x */
-#if defined H5_FORTRAN_HAS_INTEGER_1
+#if defined H5_FORTRAN_HAS_INTEGER_1
if(sizeof(long_long) == 1)
writeTypedef("long_long", 1);
else if(sizeof(long) == 1)
@@ -176,7 +176,7 @@ int main()
* is as close as we can get. */
#endif /*H5_FORTRAN_HAS_INTEGER_1 */
-#if defined H5_FORTRAN_HAS_INTEGER_2
+#if defined H5_FORTRAN_HAS_INTEGER_2
if(sizeof(long_long) == 2)
writeTypedef("long_long", 2);
else if(sizeof(long) == 2)
@@ -189,7 +189,7 @@ int main()
writeTypedefDefault(2);
#endif /*H5_FORTRAN_HAS_INTEGER_2 */
-#if defined H5_FORTRAN_HAS_INTEGER_4
+#if defined H5_FORTRAN_HAS_INTEGER_4
if(sizeof(long_long) == 4)
writeTypedef("long_long", 4);
else if(sizeof(long) == 4)
@@ -202,7 +202,7 @@ int main()
writeTypedefDefault(4);
#endif /*H5_FORTRAN_HAS_INTEGER_4 */
-#if defined H5_FORTRAN_HAS_INTEGER_8
+#if defined H5_FORTRAN_HAS_INTEGER_8
if(sizeof(long_long) == 8)
writeTypedef("long_long", 8);
else if(sizeof(long) == 8)
diff --git a/fortran/src/Makefile.am b/fortran/src/Makefile.am
index 2dee250..07f7b84 100644
--- a/fortran/src/Makefile.am
+++ b/fortran/src/Makefile.am
@@ -89,7 +89,7 @@ uninstall-local:
# Also install and uninstall (uninstall-local above) h5fc script
install-exec-local:
- @$(INSTALL) h5fc $(bindir)/$(H5FC_NAME)
+ @$(INSTALL) h5fc $(bindir)/$(H5FC_NAME)
# Install libhdf5_fortran.settings in lib directory
settingsdir=$(libdir)
diff --git a/fortran/test/t.c b/fortran/test/t.c
index 9eede1a..5c4286c 100644
--- a/fortran/test/t.c
+++ b/fortran/test/t.c
@@ -132,7 +132,7 @@ nh5_exit_c(int_f *status)
/*----------------------------------------------------------------------------
* Name: h5_group_revision_c
* Purpose: Checks if H5_GROUP_REVISION variable defined
- * Inputs:
+ * Inputs:
* Returns: 1 if defines, 0 otherwise
* Programmer: Elena Pourmal
* Saturday, May 13, 2006
@@ -142,7 +142,7 @@ int_f
nh5_group_revision_c()
{
int_f ret =0;
-#ifdef H5_GROUP_REVISION
+#ifdef H5_GROUP_REVISION
ret = 1;
#endif
return ret;
diff --git a/hl/c++/src/Makefile.am b/hl/c++/src/Makefile.am
index 63e95b6..32ea8e9 100644
--- a/hl/c++/src/Makefile.am
+++ b/hl/c++/src/Makefile.am
@@ -15,7 +15,7 @@
## Run automake to generate a Makefile.in from this file.
#
# HDF5-C++ Makefile(.in)
-#
+#
include $(top_srcdir)/config/commence.am
diff --git a/hl/c++/test/Makefile.am b/hl/c++/test/Makefile.am
index d438e41..95917f0 100644
--- a/hl/c++/test/Makefile.am
+++ b/hl/c++/test/Makefile.am
@@ -15,7 +15,7 @@
## Run automake to generate a Makefile.in from this file.
#
# HDF5-C++ Makefile(.in)
-#
+#
include $(top_srcdir)/config/commence.am
diff --git a/hl/examples/ex_ds1.c b/hl/examples/ex_ds1.c
index 096a452..e89564d 100644
--- a/hl/examples/ex_ds1.c
+++ b/hl/examples/ex_ds1.c
@@ -59,7 +59,7 @@ int main(void)
if (H5LTmake_dataset_int(fid,DS_2_NAME,rankds,s2_dim,s2_wbuf)<0)
goto out;
-
+
/*-------------------------------------------------------------------------
* attach the DS_1_NAME dimension scale to DSET_NAME at dimension 0
*-------------------------------------------------------------------------
@@ -100,7 +100,7 @@ int main(void)
/* close file */
H5Fclose(fid);
-
+
return 0;
out:
diff --git a/hl/examples/ex_image1.c b/hl/examples/ex_image1.c
index ec7b4c2..a68a5ca 100644
--- a/hl/examples/ex_image1.c
+++ b/hl/examples/ex_image1.c
@@ -37,7 +37,7 @@ int main( void )
252,252,84, /* yellow */
252,168,0, /* orange */
252,0,0}; /* red */
-
+
/* create an image of 9 values divided evenly by the array */
space = WIDTH*HEIGHT / PAL_ENTRIES;
for (i=0, j=0, n=0; i < WIDTH*HEIGHT; i++, j++ )
@@ -50,22 +50,22 @@ int main( void )
}
if (n>PAL_ENTRIES-1) n=0;
}
-
+
/* create a new HDF5 file using default properties. */
file_id = H5Fcreate( "ex_image1.h5", H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT );
-
+
/* make the image */
status = H5IMmake_image_8bit( file_id, "image1", WIDTH, HEIGHT, buf );
-
+
/* make a palette */
status = H5IMmake_palette( file_id, "pallete", pal_dims, pal );
-
+
/* attach the palette to the image */
status = H5IMlink_palette( file_id, "image1", "pallete" );
-
+
/* close the file. */
status = H5Fclose( file_id );
-
+
return 0;
-
+
}
diff --git a/hl/examples/ex_image2.c b/hl/examples/ex_image2.c
index 0b7876d..94b05a5 100644
--- a/hl/examples/ex_image2.c
+++ b/hl/examples/ex_image2.c
@@ -25,7 +25,7 @@
#define PAL_ENTRIES 256
static int read_data(const char* file_name, hsize_t *width, hsize_t *height );
-unsigned char *gbuf = 0; /* global buffer for image data */
+unsigned char *gbuf = 0; /* global buffer for image data */
int main( void )
{
@@ -34,20 +34,20 @@ int main( void )
hsize_t height; /* height of image */
unsigned char pal[ PAL_ENTRIES * 3 ]; /* palette array */
hsize_t pal_dims[2] = {PAL_ENTRIES,3}; /* palette dimensions */
- herr_t status, i, n;
-
+ herr_t status, i, n;
+
/* create a new HDF5 file using default properties. */
file_id = H5Fcreate( "ex_image2.h5", H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT );
/* read first data file */
if (read_data(DATA_FILE1,&width,&height)<0)
goto out;
-
+
/* make the image */
status=H5IMmake_image_8bit( file_id, IMAGE1_NAME, width, height, gbuf );
/*-------------------------------------------------------------------------
- * define a palette, blue to red tones
+ * define a palette, blue to red tones
*-------------------------------------------------------------------------
*/
for ( i=0, n=0; i<PAL_ENTRIES*3; i+=3, n++)
@@ -71,7 +71,7 @@ int main( void )
/* read second data file */
if (read_data(DATA_FILE2,&width,&height)<0)
goto out;
-
+
/* make dataset */
status=H5IMmake_image_24bit( file_id, IMAGE2_NAME, width, height, "INTERLACE_PIXEL", gbuf );
diff --git a/hl/examples/ex_lite1.c b/hl/examples/ex_lite1.c
index 35abb2c..1346036 100644
--- a/hl/examples/ex_lite1.c
+++ b/hl/examples/ex_lite1.c
@@ -21,17 +21,17 @@
int main( void )
{
- hid_t file_id;
+ hid_t file_id;
hsize_t dims[RANK]={2,3};
int data[6]={1,2,3,4,5,6};
herr_t status;
-
+
/* create a HDF5 file */
- file_id = H5Fcreate ("ex_lite1.h5", H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT);
-
+ file_id = H5Fcreate ("ex_lite1.h5", H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT);
+
/* create and write an integer type dataset named "dset" */
status = H5LTmake_dataset(file_id,"/dset",RANK,dims,H5T_NATIVE_INT,data);
-
+
/* close file */
status = H5Fclose (file_id);
diff --git a/hl/examples/ex_lite2.c b/hl/examples/ex_lite2.c
index fcb1c9d..2816843 100644
--- a/hl/examples/ex_lite2.c
+++ b/hl/examples/ex_lite2.c
@@ -17,21 +17,21 @@
int main( void )
{
- hid_t file_id;
+ hid_t file_id;
int data[6];
hsize_t dims[2];
herr_t status;
hsize_t i, j, nrow, n_values;
-
+
/* open file from ex_lite1.c */
- file_id = H5Fopen ("ex_lite1.h5", H5F_ACC_RDONLY, H5P_DEFAULT);
+ file_id = H5Fopen ("ex_lite1.h5", H5F_ACC_RDONLY, H5P_DEFAULT);
/* read dataset */
status = H5LTread_dataset_int(file_id,"/dset",data);
/* get the dimensions of the dataset */
status = H5LTget_dataset_info(file_id,"/dset",dims,NULL,NULL);
-
+
/* print it by rows */
n_values = dims[0] * dims[1];
nrow = dims[1];
@@ -41,7 +41,7 @@ int main( void )
printf (" %d", data[i*nrow + j]);
printf ("\n");
}
-
+
/* close file */
status = H5Fclose (file_id);
diff --git a/hl/examples/ex_lite3.c b/hl/examples/ex_lite3.c
index cc6e591..069f56a 100644
--- a/hl/examples/ex_lite3.c
+++ b/hl/examples/ex_lite3.c
@@ -20,16 +20,16 @@
int main( void )
{
- hid_t file_id;
+ hid_t file_id;
hid_t dset_id;
- hid_t space_id;
+ hid_t space_id;
hsize_t dims[1] = { ATTR_SIZE };
int data[ATTR_SIZE] = {1,2,3,4,5};
- herr_t status;
+ herr_t status;
int i;
-
+
/* create a file */
- file_id = H5Fcreate ("ex_lite3.h5", H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT);
+ file_id = H5Fcreate ("ex_lite3.h5", H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT);
/* create a data space */
space_id = H5Screate_simple(1,dims,NULL);
@@ -45,7 +45,7 @@ int main( void )
* example of H5LTset_attribute_int
*-------------------------------------------------------------------------
*/
-
+
/* create and write the attribute "attr1" on the dataset "dset" */
status = H5LTset_attribute_int(file_id,"dset","attr1",data,ATTR_SIZE);
diff --git a/hl/examples/ex_table_01.c b/hl/examples/ex_table_01.c
index b3771f4..ba1ff57 100644
--- a/hl/examples/ex_table_01.c
+++ b/hl/examples/ex_table_01.c
@@ -19,7 +19,7 @@
/*-------------------------------------------------------------------------
* Table API example
*
- * H5TBmake_table
+ * H5TBmake_table
* H5TBread_table
*
*-------------------------------------------------------------------------
@@ -32,17 +32,17 @@
int main( void )
{
- typedef struct Particle
+ typedef struct Particle
{
char name[16];
int lati;
int longi;
float pressure;
- double temperature;
+ double temperature;
} Particle;
Particle dst_buf[NRECORDS];
-
+
/* Calculate the size and the offsets of our struct members in memory */
size_t dst_size = sizeof( Particle );
size_t dst_offset[NFIELDS] = { HOFFSET( Particle, name ),
@@ -56,10 +56,10 @@ int main( void )
sizeof( dst_buf[0].longi),
sizeof( dst_buf[0].pressure),
sizeof( dst_buf[0].temperature)};
-
-
+
+
/* Define an array of Particles */
- Particle p_data[NRECORDS] = {
+ Particle p_data[NRECORDS] = {
{"zero",0,0, 0.0f, 0.0},
{"one",10,10, 1.0f, 10.0},
{"two", 20,20, 2.0f, 20.0},
@@ -71,7 +71,7 @@ int main( void )
};
/* Define field information */
- const char *field_names[NFIELDS] =
+ const char *field_names[NFIELDS] =
{ "Name","Latitude", "Longitude", "Pressure", "Temperature" };
hid_t field_type[NFIELDS];
hid_t string_type;
@@ -79,7 +79,7 @@ int main( void )
hsize_t chunk_size = 10;
int *fill_data = NULL;
int compress = 0;
- herr_t status;
+ herr_t status;
int i;
/* Initialize field_type */
@@ -90,21 +90,21 @@ int main( void )
field_type[2] = H5T_NATIVE_INT;
field_type[3] = H5T_NATIVE_FLOAT;
field_type[4] = H5T_NATIVE_DOUBLE;
-
+
/* Create a new file using default properties. */
file_id = H5Fcreate( "ex_table_01.h5", H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT );
/*-------------------------------------------------------------------------
- * H5TBmake_table
+ * H5TBmake_table
*-------------------------------------------------------------------------
*/
- status=H5TBmake_table( "Table Title", file_id, TABLE_NAME,NFIELDS,NRECORDS,
- dst_size,field_names, dst_offset, field_type,
+ status=H5TBmake_table( "Table Title", file_id, TABLE_NAME,NFIELDS,NRECORDS,
+ dst_size,field_names, dst_offset, field_type,
chunk_size, fill_data, compress, p_data );
-
+
/*-------------------------------------------------------------------------
- * H5TBread_table
+ * H5TBread_table
*-------------------------------------------------------------------------
*/
@@ -112,7 +112,7 @@ int main( void )
/* print it by rows */
for (i=0; i<NRECORDS; i++) {
- printf ("%-5s %-5d %-5d %-5f %-5f",
+ printf ("%-5s %-5d %-5d %-5f %-5f",
dst_buf[i].name,
dst_buf[i].lati,
dst_buf[i].longi,
@@ -120,12 +120,12 @@ int main( void )
dst_buf[i].temperature);
printf ("\n");
}
-
+
/*-------------------------------------------------------------------------
* end
*-------------------------------------------------------------------------
*/
-
+
/* Close the file. */
H5Fclose( file_id );
diff --git a/hl/examples/ex_table_02.c b/hl/examples/ex_table_02.c
index acefef3..3580151 100644
--- a/hl/examples/ex_table_02.c
+++ b/hl/examples/ex_table_02.c
@@ -31,19 +31,19 @@
int main( void )
{
- typedef struct Particle
+ typedef struct Particle
{
char name[16];
int lati;
int longi;
float pressure;
- double temperature;
+ double temperature;
} Particle;
Particle dst_buf[NRECORDS+NRECORDS_ADD];
/* Define an array of Particles */
- Particle p_data[NRECORDS] = {
+ Particle p_data[NRECORDS] = {
{"zero",0,0, 0.0f, 0.0},
{"one",10,10, 1.0f, 10.0},
{"two", 20,20, 2.0f, 20.0},
@@ -67,9 +67,9 @@ int main( void )
sizeof( p_data[0].longi),
sizeof( p_data[0].pressure),
sizeof( p_data[0].temperature)};
-
+
/* Define field information */
- const char *field_names[NFIELDS] =
+ const char *field_names[NFIELDS] =
{ "Name","Latitude", "Longitude", "Pressure", "Temperature" };
hid_t field_type[NFIELDS];
hid_t string_type;
@@ -77,11 +77,11 @@ int main( void )
hsize_t chunk_size = 10;
int *fill_data = NULL;
int compress = 0;
- herr_t status;
+ herr_t status;
int i;
- /* Append particles */
- Particle particle_in[ NRECORDS_ADD ] =
+ /* Append particles */
+ Particle particle_in[ NRECORDS_ADD ] =
{{ "eight",80,80, 8.0f, 80.0},
{"nine",90,90, 9.0f, 90.0} };
@@ -93,17 +93,17 @@ int main( void )
field_type[2] = H5T_NATIVE_INT;
field_type[3] = H5T_NATIVE_FLOAT;
field_type[4] = H5T_NATIVE_DOUBLE;
-
+
/* Create a new file using default properties. */
file_id = H5Fcreate( "ex_table_02.h5", H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT );
/* make a table */
- status=H5TBmake_table( "Table Title",file_id,TABLE_NAME,NFIELDS,NRECORDS,
- dst_size, field_names, dst_offset, field_type,
+ status=H5TBmake_table( "Table Title",file_id,TABLE_NAME,NFIELDS,NRECORDS,
+ dst_size, field_names, dst_offset, field_type,
chunk_size, fill_data, compress, p_data );
/* append two records */
- status=H5TBappend_records(file_id, TABLE_NAME,NRECORDS_ADD, dst_size, dst_offset, dst_sizes,
+ status=H5TBappend_records(file_id, TABLE_NAME,NRECORDS_ADD, dst_size, dst_offset, dst_sizes,
&particle_in );
/* read the table */
@@ -111,7 +111,7 @@ int main( void )
/* print it by rows */
for (i=0; i<NRECORDS+NRECORDS_ADD; i++) {
- printf ("%-5s %-5d %-5d %-5f %-5f",
+ printf ("%-5s %-5d %-5d %-5f %-5f",
dst_buf[i].name,
dst_buf[i].lati,
dst_buf[i].longi,
@@ -119,7 +119,7 @@ int main( void )
dst_buf[i].temperature);
printf ("\n");
}
-
+
/* Close the file. */
H5Fclose( file_id );
diff --git a/hl/examples/ex_table_03.c b/hl/examples/ex_table_03.c
index 7357dd2..fe4f401 100644
--- a/hl/examples/ex_table_03.c
+++ b/hl/examples/ex_table_03.c
@@ -32,13 +32,13 @@
int main( void )
{
- typedef struct Particle
+ typedef struct Particle
{
char name[16];
int lati;
int longi;
float pressure;
- double temperature;
+ double temperature;
} Particle;
Particle dst_buf[NRECORDS];
@@ -50,19 +50,19 @@ int main( void )
HOFFSET( Particle, longi ),
HOFFSET( Particle, pressure ),
HOFFSET( Particle, temperature )};
-
+
Particle p = {"zero",0,0, 0.0f, 0.0};
size_t dst_sizes[NFIELDS] = { sizeof( p.name),
sizeof( p.lati),
sizeof( p.longi),
sizeof( p.pressure),
sizeof( p.temperature)};
-
+
/* Define field information */
- const char *field_names[NFIELDS] =
+ const char *field_names[NFIELDS] =
{ "Name","Latitude", "Longitude", "Pressure", "Temperature" };
- /* Fill value particle */
- Particle fill_data[1] =
+ /* Fill value particle */
+ Particle fill_data[1] =
{ {"no data",-1,-1, -99.0f, -99.0} };
hid_t field_type[NFIELDS];
hid_t string_type;
@@ -73,8 +73,8 @@ int main( void )
herr_t status;
int i;
- /* Define 2 new particles to write */
- Particle particle_in[NRECORDS_WRITE] =
+ /* Define 2 new particles to write */
+ Particle particle_in[NRECORDS_WRITE] =
{ {"zero",0,0, 0.0f, 0.0},
{"one",10,10, 1.0f, 10.0} };
@@ -95,21 +95,21 @@ int main( void )
file_id,
TABLE_NAME,
NFIELDS,
- NRECORDS,
- dst_size,
- field_names,
- dst_offset,
- field_type,
- chunk_size,
- fill_data,
+ NRECORDS,
+ dst_size,
+ field_names,
+ dst_offset,
+ field_type,
+ chunk_size,
+ fill_data,
0, /* no compression */
NULL ); /* no data written */
/* Overwrite 2 records starting at record 0 */
- start = 0;
- nrecords = NRECORDS_WRITE;
- status=H5TBwrite_records( file_id, TABLE_NAME, start, nrecords, dst_size, dst_offset,
+ start = 0;
+ nrecords = NRECORDS_WRITE;
+ status=H5TBwrite_records( file_id, TABLE_NAME, start, nrecords, dst_size, dst_offset,
dst_sizes, particle_in);
/* read the table */
@@ -117,7 +117,7 @@ int main( void )
/* print it by rows */
for (i=0; i<NRECORDS; i++) {
- printf ("%-5s %-5d %-5d %-5f %-5f",
+ printf ("%-5s %-5d %-5d %-5f %-5f",
dst_buf[i].name,
dst_buf[i].lati,
dst_buf[i].longi,
@@ -125,7 +125,7 @@ int main( void )
dst_buf[i].temperature);
printf ("\n");
}
-
+
/* Close the file. */
H5Fclose( file_id );
diff --git a/hl/examples/ex_table_04.c b/hl/examples/ex_table_04.c
index c9559ef..55f4ee8 100644
--- a/hl/examples/ex_table_04.c
+++ b/hl/examples/ex_table_04.c
@@ -30,24 +30,24 @@
int main( void )
{
- typedef struct Particle
+ typedef struct Particle
{
char name[16];
int lati;
int longi;
float pressure;
- double temperature;
+ double temperature;
} Particle;
/* Define a subset of Particle, with latitude and longitude fields */
- typedef struct Position
+ typedef struct Position
{
int lati;
int longi;
} Position;
/* Define a subset of Particle, with name and pressure fields */
- typedef struct NamePressure
+ typedef struct NamePressure
{
char name[16];
float pressure;
@@ -76,12 +76,12 @@ int main( void )
hid_t string_type;
hid_t file_id;
hsize_t chunk_size = 10;
- Particle fill_data[1] =
- { {"no data",-1,-1, -99.0f, -99.0} }; /* Fill value particle */
+ Particle fill_data[1] =
+ { {"no data",-1,-1, -99.0f, -99.0} }; /* Fill value particle */
hsize_t start; /* Record to start reading/writing */
hsize_t nrecords; /* Number of records to read/write */
int compress = 0;
- herr_t status;
+ herr_t status;
int i;
Particle *p_data = NULL; /* Initially no data */
float pressure_in [NRECORDS] = /* Define new values for the field "Pressure" */
@@ -89,21 +89,21 @@ int main( void )
Position position_in[NRECORDS] = { /* Define new values for "Latitude,Longitude" */
{0,0},
{10,10},
- {20,20},
- {30,30},
+ {20,20},
+ {30,30},
{40,40},
- {50,50},
- {60,60},
+ {50,50},
+ {60,60},
{70,70} };
NamePressure namepre_in[NRECORDS] = /* Define new values for "Name,Pressure" */
{ {"zero",0.0f},
- {"one", 1.0f},
- {"two", 2.0f},
- {"three", 3.0f},
+ {"one", 1.0f},
+ {"two", 2.0f},
+ {"three", 3.0f},
{"four", 4.0f},
{"five", 5.0f},
- {"six", 6.0f},
- {"seven", 7.0f},
+ {"six", 6.0f},
+ {"seven", 7.0f},
};
size_t field_sizes_pos[2]=
{
@@ -111,12 +111,12 @@ int main( void )
sizeof(position_in[0].lati)
};
size_t field_sizes_namepre[2]=
- {
+ {
sizeof(namepre_in[0].name),
sizeof(namepre_in[0].pressure)
};
size_t field_sizes_pre[1]=
- {
+ {
sizeof(namepre_in[0].pressure)
};
@@ -133,20 +133,20 @@ int main( void )
file_id = H5Fcreate( "ex_table_04.h5", H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT );
/* Make the table */
- status=H5TBmake_table( "Table Title",file_id,TABLE_NAME,NFIELDS,NRECORDS,
- dst_size,field_names, dst_offset, field_type,
+ status=H5TBmake_table( "Table Title",file_id,TABLE_NAME,NFIELDS,NRECORDS,
+ dst_size,field_names, dst_offset, field_type,
chunk_size, fill_data, compress, p_data );
/* Write the pressure field starting at record 2 */
- start = 2;
- nrecords = 3;
- status=H5TBwrite_fields_name( file_id, TABLE_NAME, "Pressure", start, nrecords,
+ start = 2;
+ nrecords = 3;
+ status=H5TBwrite_fields_name( file_id, TABLE_NAME, "Pressure", start, nrecords,
sizeof( float ), 0, field_sizes_pre, pressure_in );
/* Write the new longitude and latitude information starting at record 2 */
- start = 2;
- nrecords = 3;
- status=H5TBwrite_fields_name( file_id, TABLE_NAME, "Latitude,Longitude", start, nrecords,
+ start = 2;
+ nrecords = 3;
+ status=H5TBwrite_fields_name( file_id, TABLE_NAME, "Latitude,Longitude", start, nrecords,
sizeof( Position ), field_offset_pos, field_sizes_pos, position_in );
/* read the table */
@@ -154,7 +154,7 @@ int main( void )
/* print it by rows */
for (i=0; i<NRECORDS; i++) {
- printf ("%-5s %-5d %-5d %-5f %-5f",
+ printf ("%-5s %-5d %-5d %-5f %-5f",
dst_buf[i].name,
dst_buf[i].lati,
dst_buf[i].longi,
@@ -162,12 +162,12 @@ int main( void )
dst_buf[i].temperature);
printf ("\n");
}
-
+
/*-------------------------------------------------------------------------
* end
*-------------------------------------------------------------------------
*/
-
+
/* Close the file. */
H5Fclose( file_id );
diff --git a/hl/examples/ex_table_05.c b/hl/examples/ex_table_05.c
index 62c231d..b39ef1d 100644
--- a/hl/examples/ex_table_05.c
+++ b/hl/examples/ex_table_05.c
@@ -31,29 +31,29 @@
int main( void )
{
- typedef struct Particle
+ typedef struct Particle
{
char name[16];
int lati;
int longi;
float pressure;
- double temperature;
+ double temperature;
} Particle;
/* Define a subset of Particle, with latitude and longitude fields */
- typedef struct Position
+ typedef struct Position
{
int lati;
int longi;
} Position;
/* Define a subset of Particle, with name and pressure fields */
- typedef struct NamePressure
+ typedef struct NamePressure
{
char name[16];
float pressure;
} NamePressure;
-
+
/* Calculate the type_size and the offsets of our struct members */
Particle dst_buf[NRECORDS];
size_t dst_size = sizeof( Particle );
@@ -70,28 +70,28 @@ int main( void )
size_t field_offset_pos[2] = { HOFFSET( Position, lati ),
HOFFSET( Position, longi )};
-
+
/* Initially no data */
Particle *p_data = NULL;
/* Define field information */
- const char *field_names[NFIELDS] =
+ const char *field_names[NFIELDS] =
{ "Name","Latitude", "Longitude", "Pressure", "Temperature" };
hid_t field_type[NFIELDS];
hid_t string_type;
hid_t file_id;
hsize_t chunk_size = 10;
- Particle fill_data[1] =
- { {"no data",-1,-1, -99.0f, -99.0} }; /* Fill value particle */
+ Particle fill_data[1] =
+ { {"no data",-1,-1, -99.0f, -99.0} }; /* Fill value particle */
int compress = 0;
hsize_t nfields;
hsize_t start; /* Record to start reading/writing */
hsize_t nrecords; /* Number of records to read/write */
- herr_t status;
+ herr_t status;
int i;
/* Define new values for the field "Pressure" */
- float pressure_in [NRECORDS] =
+ float pressure_in [NRECORDS] =
{ 0.0f,1.0f,2.0f,3.0f,4.0f,5.0f,6.0f,7.0f };
int field_index_pre[1] = { 3 };
@@ -100,11 +100,11 @@ int main( void )
/* Define new values for the fields "Latitude,Longitude" */
Position position_in[NRECORDS] = { {0,0},
{10,10},
- {20,20},
- {30,30},
+ {20,20},
+ {30,30},
{40,40},
- {50,50},
- {60,60},
+ {50,50},
+ {60,60},
{70,70} };
size_t field_sizes_pos[2]=
@@ -112,9 +112,9 @@ int main( void )
sizeof(position_in[0].longi),
sizeof(position_in[0].lati)
};
-
+
size_t field_sizes_pre[1]=
- {
+ {
sizeof(float)
};
@@ -126,27 +126,27 @@ int main( void )
field_type[2] = H5T_NATIVE_INT;
field_type[3] = H5T_NATIVE_FLOAT;
field_type[4] = H5T_NATIVE_DOUBLE;
-
+
/* Create a new file using default properties. */
file_id = H5Fcreate( "ex_table_05.h5", H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT );
/* Make the table */
- status=H5TBmake_table( "Table Title", file_id, TABLE_NAME,NFIELDS,NRECORDS,
- dst_size,field_names, dst_offset, field_type,
+ status=H5TBmake_table( "Table Title", file_id, TABLE_NAME,NFIELDS,NRECORDS,
+ dst_size,field_names, dst_offset, field_type,
chunk_size, fill_data, compress, p_data );
/* Write the pressure field starting at record 2 */
nfields = 1;
- start = 2;
- nrecords = 3;
- status=H5TBwrite_fields_index( file_id, TABLE_NAME, nfields, field_index_pre, start, nrecords,
+ start = 2;
+ nrecords = 3;
+ status=H5TBwrite_fields_index( file_id, TABLE_NAME, nfields, field_index_pre, start, nrecords,
sizeof( float ), 0, field_sizes_pre, pressure_in );
/* Write the new longitude and latitude information starting at record 2 */
nfields = 2;
- start = 2;
- nrecords = 3;
- status=H5TBwrite_fields_index( file_id, TABLE_NAME, nfields, field_index_pos, start, nrecords,
+ start = 2;
+ nrecords = 3;
+ status=H5TBwrite_fields_index( file_id, TABLE_NAME, nfields, field_index_pos, start, nrecords,
sizeof( Position ), field_offset_pos, field_sizes_pos, position_in );
/* read the table */
@@ -154,7 +154,7 @@ int main( void )
/* print it by rows */
for (i=0; i<NRECORDS; i++) {
- printf ("%-5s %-5d %-5d %-5f %-5f",
+ printf ("%-5s %-5d %-5d %-5f %-5f",
dst_buf[i].name,
dst_buf[i].lati,
dst_buf[i].longi,
@@ -162,7 +162,7 @@ int main( void )
dst_buf[i].temperature);
printf ("\n");
}
-
+
/* Close the file. */
H5Fclose( file_id );
diff --git a/hl/examples/ex_table_06.c b/hl/examples/ex_table_06.c
index 377afc3..a0d6017 100644
--- a/hl/examples/ex_table_06.c
+++ b/hl/examples/ex_table_06.c
@@ -30,13 +30,13 @@
int main( void )
{
- typedef struct Particle
+ typedef struct Particle
{
char name[16];
int lati;
int longi;
float pressure;
- double temperature;
+ double temperature;
} Particle;
/* Calculate the size and the offsets of our struct members in memory */
@@ -46,20 +46,20 @@ int main( void )
HOFFSET( Particle, longi ),
HOFFSET( Particle, pressure ),
HOFFSET( Particle, temperature )};
-
+
/* Define field information */
- const char *field_names[NFIELDS] =
+ const char *field_names[NFIELDS] =
{ "Name","Latitude", "Longitude", "Pressure", "Temperature" };
hid_t field_type[NFIELDS];
hid_t string_type;
hid_t file_id;
hsize_t chunk_size = 10;
- Particle fill_data[1] =
- { {"no data",-1,-1, -99.0f, -99.0} }; /* Fill value particle */
+ Particle fill_data[1] =
+ { {"no data",-1,-1, -99.0f, -99.0} }; /* Fill value particle */
int compress = 0;
hsize_t nfields_out;
hsize_t nrecords_out;
- herr_t status;
+ herr_t status;
/* Initialize field_type */
string_type = H5Tcopy( H5T_C_S1 );
@@ -69,13 +69,13 @@ int main( void )
field_type[2] = H5T_NATIVE_INT;
field_type[3] = H5T_NATIVE_FLOAT;
field_type[4] = H5T_NATIVE_DOUBLE;
-
+
/* Create a new file using default properties. */
file_id = H5Fcreate( "ex_table_06.h5", H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT );
/* Make a table */
- status=H5TBmake_table( "Table Title",file_id,TABLE_NAME,NFIELDS,NRECORDS,dst_size,
- field_names, dst_offset, field_type,
+ status=H5TBmake_table( "Table Title",file_id,TABLE_NAME,NFIELDS,NRECORDS,dst_size,
+ field_names, dst_offset, field_type,
chunk_size, fill_data, compress, NULL);
/* Get table info */
@@ -83,7 +83,7 @@ int main( void )
/* print */
printf ("Table has %d fields and %d records\n",(int)nfields_out,(int)nrecords_out);
-
+
/* Close the file. */
H5Fclose( file_id );
diff --git a/hl/examples/ex_table_07.c b/hl/examples/ex_table_07.c
index eb365b2..2d80967 100644
--- a/hl/examples/ex_table_07.c
+++ b/hl/examples/ex_table_07.c
@@ -30,13 +30,13 @@
int main( void )
{
- typedef struct Particle
+ typedef struct Particle
{
char name[16];
int lati;
int longi;
float pressure;
- double temperature;
+ double temperature;
} Particle;
/* Calculate the size and the offsets of our struct members in memory */
@@ -46,9 +46,9 @@ int main( void )
HOFFSET( Particle, longi ),
HOFFSET( Particle, pressure ),
HOFFSET( Particle, temperature )};
-
+
/* Define an array of Particles */
- Particle p_data[NRECORDS] = {
+ Particle p_data[NRECORDS] = {
{"zero",0,0, 0.0f, 0.0},
{"one",10,10, 1.0f, 10.0},
{"two", 20,20, 2.0f, 20.0},
@@ -66,14 +66,14 @@ int main( void )
hid_t file_id;
hsize_t chunk_size = 10;
int compress = 0;
- Particle fill_data[1] =
+ Particle fill_data[1] =
{ {"no data",-1,-1, -99.0f, -99.0} };
hsize_t start; /* Record to start reading */
hsize_t nrecords; /* Number of records to insert/delete */
hsize_t nfields_out;
hsize_t nrecords_out;
- herr_t status;
-
+ herr_t status;
+
/* Initialize the field field_type */
string_type = H5Tcopy( H5T_C_S1 );
H5Tset_size( string_type, 16 );
@@ -82,18 +82,18 @@ int main( void )
field_type[2] = H5T_NATIVE_INT;
field_type[3] = H5T_NATIVE_FLOAT;
field_type[4] = H5T_NATIVE_DOUBLE;
-
+
/* Create a new file using default properties. */
file_id = H5Fcreate( "ex_table_07.h5", H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT );
-
+
/* Make the table */
- status=H5TBmake_table( "Table Title",file_id,TABLE_NAME,NFIELDS,NRECORDS,
- dst_size,field_names, dst_offset, field_type,
+ status=H5TBmake_table( "Table Title",file_id,TABLE_NAME,NFIELDS,NRECORDS,
+ dst_size,field_names, dst_offset, field_type,
chunk_size, fill_data, compress, p_data );
-
+
/* Delete records */
- start = 3;
- nrecords = 3;
+ start = 3;
+ nrecords = 3;
status=H5TBdelete_record( file_id, TABLE_NAME, start, nrecords );
/* Get table info */
@@ -101,11 +101,11 @@ int main( void )
/* print */
printf ("Table has %d fields and %d records\n",(int)nfields_out,(int)nrecords_out);
-
+
/* Close the file. */
H5Fclose( file_id );
-
+
return 0;
-
+
}
diff --git a/hl/examples/ex_table_08.c b/hl/examples/ex_table_08.c
index 8ce2881..fb6cab9 100644
--- a/hl/examples/ex_table_08.c
+++ b/hl/examples/ex_table_08.c
@@ -31,19 +31,19 @@
int main( void )
{
- typedef struct Particle
+ typedef struct Particle
{
char name[16];
int lati;
int longi;
float pressure;
- double temperature;
+ double temperature;
} Particle;
Particle dst_buf[ NRECORDS + NRECORDS_INS ];
/* Define an array of Particles */
- Particle p_data[NRECORDS] = {
+ Particle p_data[NRECORDS] = {
{"zero",0,0, 0.0f, 0.0},
{"one",10,10, 1.0f, 10.0},
{"two", 20,20, 2.0f, 20.0},
@@ -53,7 +53,7 @@ int main( void )
{"six", 60,60, 6.0f, 60.0},
{"seven",70,70, 7.0f, 70.0}
};
-
+
/* Calculate the size and the offsets of our struct members in memory */
size_t dst_size = sizeof( Particle );
size_t dst_offset[NFIELDS] = { HOFFSET( Particle, name ),
@@ -66,15 +66,15 @@ int main( void )
sizeof( p_data[0].longi),
sizeof( p_data[0].pressure),
sizeof( p_data[0].temperature)};
-
+
/* Define an array of Particles to insert */
- Particle p_data_insert[NRECORDS_INS] =
+ Particle p_data_insert[NRECORDS_INS] =
{ {"new",30,30, 3.0f, 30.0},
{"new",40,40, 4.0f, 40.0}
};
-
+
/* Define field information */
- const char *field_names[NFIELDS] =
+ const char *field_names[NFIELDS] =
{ "Name","Latitude", "Longitude", "Pressure", "Temperature" };
hid_t field_type[NFIELDS];
hid_t string_type;
@@ -88,7 +88,7 @@ int main( void )
hsize_t nfields_out;
hsize_t nrecords_out;
int i;
-
+
/* Initialize the field field_type */
string_type = H5Tcopy( H5T_C_S1 );
H5Tset_size( string_type, 16 );
@@ -97,19 +97,19 @@ int main( void )
field_type[2] = H5T_NATIVE_INT;
field_type[3] = H5T_NATIVE_FLOAT;
field_type[4] = H5T_NATIVE_DOUBLE;
-
+
/* Create a new file using default properties. */
file_id = H5Fcreate( "ex_table_08.h5", H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT );
-
+
/* Make the table */
- status=H5TBmake_table( "Table Title",file_id,TABLE_NAME,NFIELDS,NRECORDS,
- dst_size,field_names, dst_offset, field_type,
+ status=H5TBmake_table( "Table Title",file_id,TABLE_NAME,NFIELDS,NRECORDS,
+ dst_size,field_names, dst_offset, field_type,
chunk_size, fill_data, compress, p_data );
/* Insert records */
- start = 3;
- nrecords = NRECORDS_INS;
- status=H5TBinsert_record( file_id, TABLE_NAME, start, nrecords, dst_size, dst_offset,
+ start = 3;
+ nrecords = NRECORDS_INS;
+ status=H5TBinsert_record( file_id, TABLE_NAME, start, nrecords, dst_size, dst_offset,
dst_sizes, p_data_insert );
/* read the table */
@@ -120,10 +120,10 @@ int main( void )
/* print */
printf ("Table has %d fields and %d records\n",(int)nfields_out,(int)nrecords_out);
-
+
/* print it by rows */
for (i=0; i<nrecords_out; i++) {
- printf ("%-5s %-5d %-5d %-5f %-5f",
+ printf ("%-5s %-5d %-5d %-5f %-5f",
dst_buf[i].name,
dst_buf[i].lati,
dst_buf[i].longi,
@@ -131,12 +131,12 @@ int main( void )
dst_buf[i].temperature);
printf ("\n");
}
-
+
/* Close the file. */
H5Fclose( file_id );
-
+
return 0;
-
+
}
diff --git a/hl/examples/ex_table_09.c b/hl/examples/ex_table_09.c
index 21d1813..b02568c 100644
--- a/hl/examples/ex_table_09.c
+++ b/hl/examples/ex_table_09.c
@@ -32,13 +32,13 @@
int main( void )
{
- typedef struct Particle
+ typedef struct Particle
{
char name[16];
int lati;
int longi;
float pressure;
- double temperature;
+ double temperature;
} Particle;
Particle dst_buf[ NRECORDS + NRECORDS_INS ];
@@ -57,7 +57,7 @@ int main( void )
sizeof( dst_buf[0].temperature)};
/* Define an array of Particles */
- Particle p_data[NRECORDS] = {
+ Particle p_data[NRECORDS] = {
{"zero",0,0, 0.0f, 0.0},
{"one",10,10, 1.0f, 10.0},
{"two", 20,20, 2.0f, 20.0},
@@ -69,15 +69,15 @@ int main( void )
};
/* Define field information */
- const char *field_names[NFIELDS] =
+ const char *field_names[NFIELDS] =
{ "Name","Latitude", "Longitude", "Pressure", "Temperature" };
hid_t field_type[NFIELDS];
hid_t string_type;
hid_t file_id;
hsize_t chunk_size = 10;
int compress = 0;
- Particle fill_data[1] =
- { {"no data",-1,-1, -99.0f, -99.0} }; /* Fill value particle */
+ Particle fill_data[1] =
+ { {"no data",-1,-1, -99.0f, -99.0} }; /* Fill value particle */
hsize_t start1; /* Record to start reading from 1st table */
hsize_t nrecords; /* Number of records to insert */
hsize_t start2; /* Record to start writing in 2nd table */
@@ -85,7 +85,7 @@ int main( void )
int i;
hsize_t nfields_out;
hsize_t nrecords_out;
-
+
/* Initialize the field field_type */
string_type = H5Tcopy( H5T_C_S1 );
H5Tset_size( string_type, 16 );
@@ -94,24 +94,24 @@ int main( void )
field_type[2] = H5T_NATIVE_INT;
field_type[3] = H5T_NATIVE_FLOAT;
field_type[4] = H5T_NATIVE_DOUBLE;
-
+
/* Create a new file using default properties. */
file_id = H5Fcreate( "ex_table_09.h5", H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT );
-
+
/* Make 2 tables: TABLE2_NAME is empty */
- status=H5TBmake_table( "Table Title",file_id,TABLE1_NAME,NFIELDS,NRECORDS,
- dst_size,field_names, dst_offset, field_type,
+ status=H5TBmake_table( "Table Title",file_id,TABLE1_NAME,NFIELDS,NRECORDS,
+ dst_size,field_names, dst_offset, field_type,
chunk_size, fill_data, compress, p_data );
-
- status=H5TBmake_table( "Table Title",file_id,TABLE2_NAME,NFIELDS,NRECORDS,
- dst_size,field_names, dst_offset, field_type,
+
+ status=H5TBmake_table( "Table Title",file_id,TABLE2_NAME,NFIELDS,NRECORDS,
+ dst_size,field_names, dst_offset, field_type,
chunk_size, fill_data, compress, NULL );
-
-
+
+
/* Add 2 records from TABLE1_NAME to TABLE2_NAME */
- start1 = 3;
- nrecords = NRECORDS_INS;
- start2 = 6;
+ start1 = 3;
+ nrecords = NRECORDS_INS;
+ start2 = 6;
status=H5TBadd_records_from( file_id, TABLE1_NAME, start1, nrecords, TABLE2_NAME, start2 );
/* read TABLE2_NAME: it should have 2 more records now */
@@ -122,10 +122,10 @@ int main( void )
/* print */
printf ("Table has %d fields and %d records\n",(int)nfields_out,(int)nrecords_out);
-
+
/* print it by rows */
for (i=0; i<nrecords_out; i++) {
- printf ("%-5s %-5d %-5d %-5f %-5f",
+ printf ("%-5s %-5d %-5d %-5f %-5f",
dst_buf[i].name,
dst_buf[i].lati,
dst_buf[i].longi,
@@ -133,10 +133,10 @@ int main( void )
dst_buf[i].temperature);
printf ("\n");
}
-
+
/* Close the file. */
H5Fclose( file_id );
-
+
return 0;
}
diff --git a/hl/examples/ex_table_10.c b/hl/examples/ex_table_10.c
index 5483d52..5e87914 100644
--- a/hl/examples/ex_table_10.c
+++ b/hl/examples/ex_table_10.c
@@ -32,17 +32,17 @@
int main( void )
{
- typedef struct Particle
+ typedef struct Particle
{
char name[16];
int lati;
int longi;
float pressure;
- double temperature;
+ double temperature;
} Particle;
/* Define an array of Particles */
- Particle p_data[NRECORDS] = {
+ Particle p_data[NRECORDS] = {
{"zero",0,0, 0.0f, 0.0},
{"one",10,10, 1.0f, 10.0},
{"two", 20,20, 2.0f, 20.0},
@@ -66,10 +66,10 @@ int main( void )
sizeof( dst_buf[0].longi),
sizeof( dst_buf[0].pressure),
sizeof( dst_buf[0].temperature)};
-
-
+
+
/* Define field information */
- const char *field_names[NFIELDS] =
+ const char *field_names[NFIELDS] =
{ "Name","Latitude", "Longitude", "Pressure", "Temperature" };
hid_t field_type[NFIELDS];
hid_t string_type;
@@ -77,11 +77,11 @@ int main( void )
hsize_t chunk_size = 10;
int compress = 0;
int *fill_data = NULL;
- herr_t status;
+ herr_t status;
hsize_t nfields_out;
hsize_t nrecords_out;
int i;
-
+
/* Initialize the field field_type */
string_type = H5Tcopy( H5T_C_S1 );
H5Tset_size( string_type, 16 );
@@ -90,34 +90,34 @@ int main( void )
field_type[2] = H5T_NATIVE_INT;
field_type[3] = H5T_NATIVE_FLOAT;
field_type[4] = H5T_NATIVE_DOUBLE;
-
+
/* Create a new file using default properties. */
file_id = H5Fcreate( "ex_table_10.h5", H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT );
-
+
/* Make two tables */
- status=H5TBmake_table( "Table Title",file_id,TABLE1_NAME,NFIELDS,NRECORDS,
- dst_size,field_names, dst_offset, field_type,
+ status=H5TBmake_table( "Table Title",file_id,TABLE1_NAME,NFIELDS,NRECORDS,
+ dst_size,field_names, dst_offset, field_type,
chunk_size, fill_data, compress, p_data );
-
- status=H5TBmake_table( "Table Title",file_id,TABLE2_NAME,NFIELDS,NRECORDS,
- dst_size,field_names, dst_offset, field_type,
+
+ status=H5TBmake_table( "Table Title",file_id,TABLE2_NAME,NFIELDS,NRECORDS,
+ dst_size,field_names, dst_offset, field_type,
chunk_size, fill_data, compress, p_data );
-
+
/* Combine the two tables into a third in the same file */
status=H5TBcombine_tables( file_id, TABLE1_NAME, file_id, TABLE2_NAME, TABLE3_NAME );
/* read the combined table */
status=H5TBread_table( file_id, TABLE3_NAME, dst_size, dst_offset, dst_sizes, dst_buf );
-
+
/* Get table info */
status=H5TBget_table_info (file_id,TABLE3_NAME, &nfields_out, &nrecords_out );
-
+
/* print */
printf ("Table has %d fields and %d records\n",(int)nfields_out,(int)nrecords_out);
-
+
/* print it by rows */
for (i=0; i<nrecords_out; i++) {
- printf ("%-5s %-5d %-5d %-5f %-5f",
+ printf ("%-5s %-5d %-5d %-5f %-5f",
dst_buf[i].name,
dst_buf[i].lati,
dst_buf[i].longi,
@@ -125,10 +125,10 @@ int main( void )
dst_buf[i].temperature);
printf ("\n");
}
-
+
/* Close the file */
H5Fclose( file_id );
-
+
return 0;
}
diff --git a/hl/examples/ex_table_11.c b/hl/examples/ex_table_11.c
index d082f65..52aa922 100644
--- a/hl/examples/ex_table_11.c
+++ b/hl/examples/ex_table_11.c
@@ -30,17 +30,17 @@
int main( void )
{
- typedef struct Particle1
+ typedef struct Particle1
{
char name[16];
int lati;
int longi;
float pressure;
- double temperature;
+ double temperature;
} Particle1;
-
+
/* Define an array of Particles */
- Particle1 p_data[NRECORDS] = {
+ Particle1 p_data[NRECORDS] = {
{"zero",0,0, 0.0f, 0.0},
{"one",10,10, 1.0f, 10.0},
{"two", 20,20, 2.0f, 20.0},
@@ -50,7 +50,7 @@ int main( void )
{"six", 60,60, 6.0f, 60.0},
{"seven",70,70, 7.0f, 70.0}
};
-
+
/* Calculate the size and the offsets of our struct members in memory */
size_t dst_size1 = sizeof( Particle1 );
size_t dst_offset1[NFIELDS] = { HOFFSET( Particle1, name ),
@@ -58,9 +58,9 @@ int main( void )
HOFFSET( Particle1, longi ),
HOFFSET( Particle1, pressure ),
HOFFSET( Particle1, temperature )};
-
+
/* Define field information */
- const char *field_names[NFIELDS] =
+ const char *field_names[NFIELDS] =
{ "Name","Latitude", "Longitude", "Pressure", "Temperature" };
hid_t field_type[NFIELDS];
hid_t string_type;
@@ -70,14 +70,14 @@ int main( void )
Particle1 fill_data[1] = { "no data",-1,-1, -99.0f, -99.0 };
int fill_data_new[1] = { -100 };
hsize_t position;
- herr_t status;
+ herr_t status;
hsize_t nfields_out;
hsize_t nrecords_out;
-
+
/* Define the inserted field information */
hid_t field_type_new = H5T_NATIVE_INT;
int data[NRECORDS] = { 0,1,2,3,4,5,6,7 };
-
+
/* Initialize the field type */
string_type = H5Tcopy( H5T_C_S1 );
H5Tset_size( string_type, 16 );
@@ -86,18 +86,18 @@ int main( void )
field_type[2] = H5T_NATIVE_INT;
field_type[3] = H5T_NATIVE_FLOAT;
field_type[4] = H5T_NATIVE_DOUBLE;
-
+
/* Create a new file using default properties. */
file_id = H5Fcreate( "ex_table_11.h5", H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT );
-
+
/* Make the table */
- status=H5TBmake_table( "Table Title",file_id,TABLE_NAME,NFIELDS,NRECORDS,
- dst_size1,field_names, dst_offset1, field_type,
+ status=H5TBmake_table( "Table Title",file_id,TABLE_NAME,NFIELDS,NRECORDS,
+ dst_size1,field_names, dst_offset1, field_type,
chunk_size, fill_data, compress, p_data );
-
+
/* Insert the new field at the end of the field list */
position = NFIELDS;
- status=H5TBinsert_field( file_id, TABLE_NAME, "New Field", field_type_new, position,
+ status=H5TBinsert_field( file_id, TABLE_NAME, "New Field", field_type_new, position,
fill_data_new, data );
/* Get table info */
@@ -105,12 +105,12 @@ int main( void )
/* print */
printf ("Table has %d fields and %d records\n",(int)nfields_out,(int)nrecords_out);
-
+
/* Close the file. */
H5Fclose( file_id );
-
+
return 0;
-
-
+
+
}
diff --git a/hl/examples/ex_table_12.c b/hl/examples/ex_table_12.c
index 9ec3054..26e238f 100644
--- a/hl/examples/ex_table_12.c
+++ b/hl/examples/ex_table_12.c
@@ -30,15 +30,15 @@
int main( void )
{
- typedef struct Particle
+ typedef struct Particle
{
char name[16];
int lati;
int longi;
float pressure;
- double temperature;
+ double temperature;
} Particle;
-
+
/* Calculate the size and the offsets of our struct members in memory */
size_t dst_size = sizeof( Particle );
size_t dst_offset[NFIELDS] = { HOFFSET( Particle, name ),
@@ -46,9 +46,9 @@ int main( void )
HOFFSET( Particle, longi ),
HOFFSET( Particle, pressure ),
HOFFSET( Particle, temperature )};
-
+
/* Define an array of Particles */
- Particle p_data[NRECORDS] = {
+ Particle p_data[NRECORDS] = {
{"zero",0,0, 0.0f, 0.0},
{"one",10,10, 1.0f, 10.0},
{"two", 20,20, 2.0f, 20.0},
@@ -58,21 +58,21 @@ int main( void )
{"six", 60,60, 6.0f, 60.0},
{"seven",70,70, 7.0f, 70.0}
};
-
+
/* Define field information */
- const char *field_names[NFIELDS] =
+ const char *field_names[NFIELDS] =
{ "Name","Latitude", "Longitude", "Pressure", "Temperature" };
hid_t field_type[NFIELDS];
hid_t string_type;
hid_t file_id;
hsize_t chunk_size = 10;
int compress = 0;
- Particle fill_data[1] =
+ Particle fill_data[1] =
{ {"no data",-1,-1, -99.0f, -99.0} };
- herr_t status;
+ herr_t status;
hsize_t nfields_out;
hsize_t nrecords_out;
-
+
/* Initialize the field type */
string_type = H5Tcopy( H5T_C_S1 );
H5Tset_size( string_type, 16 );
@@ -81,15 +81,15 @@ int main( void )
field_type[2] = H5T_NATIVE_INT;
field_type[3] = H5T_NATIVE_FLOAT;
field_type[4] = H5T_NATIVE_DOUBLE;
-
+
/* Create a new file using default properties. */
file_id = H5Fcreate( "ex_table_12.h5", H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT );
-
+
/* Make a table */
- status=H5TBmake_table( "Table Title", file_id, TABLE_NAME, NFIELDS, NRECORDS, dst_size,
- field_names, dst_offset, field_type,
+ status=H5TBmake_table( "Table Title", file_id, TABLE_NAME, NFIELDS, NRECORDS, dst_size,
+ field_names, dst_offset, field_type,
chunk_size, fill_data, compress, p_data );
-
+
/* Delete the field */
status=H5TBdelete_field( file_id, TABLE_NAME, "Pressure" );
@@ -98,11 +98,11 @@ int main( void )
/* print */
printf ("Table has %d fields and %d records\n",(int)nfields_out,(int)nrecords_out);
-
+
/* Close the file. */
H5Fclose( file_id );
-
+
return 0;
-
+
}
diff --git a/hl/fortran/src/Makefile.am b/hl/fortran/src/Makefile.am
index 6ee69cf..c341031 100644
--- a/hl/fortran/src/Makefile.am
+++ b/hl/fortran/src/Makefile.am
@@ -41,7 +41,7 @@ endif
#endif
libhdf5hl_fortran_la_SOURCES=H5LTfc.c H5IMfc.c H5IMcc.c H5TBfc.c H5LTff.f90 \
- H5IMff.f90 H5TBff.f90
+ H5IMff.f90 H5TBff.f90
# Fortran module files can have different extensions and different names
# (e.g., different capitalizations) on different platforms. Write rules
@@ -70,8 +70,8 @@ uninstall-local:
# determining this automagically (like we do with the C files). So, when
# doing a parallel make, some modules could be made way before the
# modules they depend upon are actually made. *sigh*
-H5LTff.lo: $(srcdir)/H5LTff.f90
+H5LTff.lo: $(srcdir)/H5LTff.f90
H5IMff.lo: $(srcdir)/H5IMff.f90
-H5TBff.lo: $(srcdir)/H5TBff.f90
+H5TBff.lo: $(srcdir)/H5TBff.f90
include $(top_srcdir)/config/conclude.am
diff --git a/hl/src/H5DS.c b/hl/src/H5DS.c
index 254f7df..fa158a5 100644
--- a/hl/src/H5DS.c
+++ b/hl/src/H5DS.c
@@ -25,11 +25,11 @@
/*-------------------------------------------------------------------------
* Function: H5DSset_scale
*
- * Purpose: The dataset DSID is converted to a Dimension Scale dataset.
- * Creates the CLASS attribute, set to the value "DIMENSION_SCALE"
- * and an empty REFERENCE_LIST attribute.
- * If DIMNAME is specified, then an attribute called NAME is created,
- * with the value DIMNAME.
+ * Purpose: The dataset DSID is converted to a Dimension Scale dataset.
+ * Creates the CLASS attribute, set to the value "DIMENSION_SCALE"
+ * and an empty REFERENCE_LIST attribute.
+ * If DIMNAME is specified, then an attribute called NAME is created,
+ * with the value DIMNAME.
*
* Return: Success: SUCCEED, Failure: FAIL
*
@@ -95,17 +95,17 @@ herr_t H5DSset_scale(hid_t dsid,
/*-------------------------------------------------------------------------
* Function: H5DSattach_scale
*
- * Purpose: Define Dimension Scale DSID to be associated with dimension IDX
- * of Dataset DID. Entries are created in the DIMENSION_LIST and
- * REFERENCE_LIST attributes.
+ * Purpose: Define Dimension Scale DSID to be associated with dimension IDX
+ * of Dataset DID. Entries are created in the DIMENSION_LIST and
+ * REFERENCE_LIST attributes.
*
* Return:
* Success: SUCCEED
* Failure: FAIL
*
- * Fails if: Bad arguments
- * If DSID is not a Dimension Scale
- * If DID is a Dimension Scale (A Dimension Scale cannot have scales)
+ * Fails if: Bad arguments
+ * If DSID is not a Dimension Scale
+ * If DID is a Dimension Scale (A Dimension Scale cannot have scales)
*
* Programmer: pvn@ncsa.uiuc.edu
*
@@ -556,20 +556,20 @@ out:
/*-------------------------------------------------------------------------
* Function: H5DSdetach_scale
*
- * Purpose: If possible, deletes association of Dimension Scale DSID with
- * dimension IDX of Dataset DID. This deletes the entries in the
- * DIMENSION_LIST and REFERENCE_LIST attributes.
+ * Purpose: If possible, deletes association of Dimension Scale DSID with
+ * dimension IDX of Dataset DID. This deletes the entries in the
+ * DIMENSION_LIST and REFERENCE_LIST attributes.
*
* Return:
* Success: SUCCEED
* Failure: FAIL
*
- * Fails if: Bad arguments
- * The dataset DID or DSID do not exist.
- * The DSID is not a Dimension Scale
- * DSID is not attached to DID.
- * Note that a scale may be associated with more than dimension of the same dataset.
- * If so, the detach operation only deletes one of the associations, for DID.
+ * Fails if: Bad arguments
+ * The dataset DID or DSID do not exist.
+ * The DSID is not a Dimension Scale
+ * DSID is not attached to DID.
+ * Note that a scale may be associated with more than dimension of the same dataset.
+ * If so, the detach operation only deletes one of the associations, for DID.
*
* Programmer: pvn@ncsa.uiuc.edu
*
@@ -934,9 +934,9 @@ out:
* 0: one of them or both do not match
* FAIL (-1): error
*
- * Fails if: Bad arguments
- * If DSID is not a Dimension Scale
- * If DID is a Dimension Scale (A Dimension Scale cannot have scales)
+ * Fails if: Bad arguments
+ * If DSID is not a Dimension Scale
+ * If DID is a Dimension Scale (A Dimension Scale cannot have scales)
*
* Programmer: pvn@ncsa.uiuc.edu
*
@@ -1209,7 +1209,7 @@ out:
*
* hid_t DID; IN: the dataset
* unsigned int dim; IN: the dimension of the dataset
- * int *idx; IN/OUT: input the index to start iterating, output the
+ * int *idx; IN/OUT: input the index to start iterating, output the
* next index to visit. If NULL, start at the first position.
* H5DS_iterate_t visitor; IN: the visitor function
* void *visitor_data; IN: arbitrary data to pass to the visitor function.
@@ -1964,7 +1964,7 @@ int H5DSget_num_scales(hid_t did,
*-------------------------------------------------------------------------
*/
- else
+ else
{
if ((aid = H5Aopen_name(did,DIMENSION_LIST))<0)
goto out;
diff --git a/hl/src/H5LT.c b/hl/src/H5LT.c
index acc30b8..5db6cd4 100644
--- a/hl/src/H5LT.c
+++ b/hl/src/H5LT.c
@@ -985,11 +985,11 @@ herr_t H5LTget_dataset_info( hid_t loc_id,
/* get the dataspace handle */
if ( (sid = H5Dget_space( did )) < 0 )
goto out;
-
+
/* get dimensions */
if ( H5Sget_simple_extent_dims( sid, dims, NULL) < 0 )
goto out;
-
+
/* terminate access to the dataspace */
if ( H5Sclose( sid ) < 0 )
goto out;
@@ -1756,7 +1756,7 @@ static herr_t find_attr( hid_t loc_id, const char *name, void *op_data)
/*-------------------------------------------------------------------------
* Function: H5LTfind_attribute
*
- * Purpose: Inquires if an attribute named attr_name exists attached to
+ * Purpose: Inquires if an attribute named attr_name exists attached to
* the object loc_id.
*
* Programmer: Pedro Vicente, pvn@ncsa.uiuc.edu
@@ -2039,7 +2039,7 @@ out:
hid_t H5LTtext_to_dtype(const char *text, H5LT_lang_t lang_type)
{
extern int yyparse(void);
- hid_t type_id;
+ hid_t type_id;
if(lang_type <= H5LT_LANG_ERR || lang_type >= H5LT_NO_LANG)
goto out;
@@ -2048,7 +2048,7 @@ hid_t H5LTtext_to_dtype(const char *text, H5LT_lang_t lang_type)
fprintf(stderr, "only DDL is supported for now.\n");
goto out;
}
-
+
input_len = strlen(text);
myinput = strdup(text);
@@ -2118,17 +2118,17 @@ print_enum(hid_t type, char* str, int indt)
size_t dst_size; /*destination value type size */
int i;
herr_t ret = SUCCEED;
-
+
if((nmembs = H5Tget_nmembers(type))==0)
goto out;
assert(nmembs>0);
if((super = H5Tget_super(type))<0)
goto out;
-
+
/* Use buffer of INT or UNSIGNED INT to print enum values because
* we don't expect these values to be so big that INT or UNSIGNED
* INT can't hold.
- */
+ */
if (H5T_SGN_NONE == H5Tget_sign(super)) {
native = H5T_NATIVE_UINT;
} else {
@@ -2137,7 +2137,7 @@ print_enum(hid_t type, char* str, int indt)
super_size = H5Tget_size(super);
dst_size = H5Tget_size(native);
-
+
/* Get the names and raw values of all members */
name = (char**)calloc((size_t)nmembs, sizeof(char *));
value = (unsigned char*)calloc((size_t)nmembs, MAX(dst_size, super_size));
@@ -2154,7 +2154,7 @@ print_enum(hid_t type, char* str, int indt)
if(H5Tconvert(super, native, (size_t)nmembs, value, NULL, H5P_DEFAULT)<0)
goto out;
}
-
+
/*
* Sort members by increasing value
* ***not implemented yet***
@@ -2167,7 +2167,7 @@ print_enum(hid_t type, char* str, int indt)
strcat(str, tmp_str);
sprintf(tmp_str, "%*s ", MAX(0, 16 - nchars), "");
strcat(str, tmp_str);
-
+
if (H5T_SGN_NONE == H5Tget_sign(native)) {
/*On SGI Altix(cobalt), wrong values were printed out with "value+i*dst_size"
*strangely, unless use another pointer "copy".*/
@@ -2226,7 +2226,7 @@ herr_t H5LTdtype_to_text(hid_t dtype, char *str, H5LT_lang_t lang_type, size_t *
size_t str_len = INCREMENT;
char *text_str;
herr_t ret = -1;
-
+
if(lang_type <= H5LT_LANG_ERR || lang_type >= H5LT_NO_LANG)
goto out;
@@ -2265,7 +2265,7 @@ out:
*
*-------------------------------------------------------------------------
*/
-herr_t H5LT_dtype_to_text(hid_t dtype, char **dt_str, H5LT_lang_t lang, size_t *slen,
+herr_t H5LT_dtype_to_text(hid_t dtype, char **dt_str, H5LT_lang_t lang, size_t *slen,
hbool_t no_user_buf)
{
H5T_class_t tcls;
@@ -2282,15 +2282,15 @@ herr_t H5LT_dtype_to_text(hid_t dtype, char **dt_str, H5LT_lang_t lang, size_t *
*dt_str = tmp;
}
}
-
+
if(lang != H5LT_DDL) {
sprintf(*dt_str, "only DDL is supported for now");
goto out;
}
-
+
if((tcls = H5Tget_class(dtype))<0)
goto out;
-
+
switch (tcls) {
case H5T_INTEGER:
if (H5Tequal(dtype, H5T_STD_I8BE)) {
@@ -2451,7 +2451,7 @@ herr_t H5LT_dtype_to_text(hid_t dtype, char **dt_str, H5LT_lang_t lang, size_t *
if (H5Tequal(tmp_type, str_type)) {
strcat(*dt_str, "CTYPE H5T_C_S1;\n");
goto next;
- }
+ }
/* Change the endianness and see if they're equal. */
if((order = H5Tget_order(tmp_type))<0)
@@ -2463,7 +2463,7 @@ herr_t H5LT_dtype_to_text(hid_t dtype, char **dt_str, H5LT_lang_t lang, size_t *
if(H5Tset_order(str_type, H5T_ORDER_BE)<0)
goto out;
}
-
+
if (H5Tequal(tmp_type, str_type)) {
strcat(*dt_str, "H5T_C_S1;\n");
goto next;
@@ -2481,7 +2481,7 @@ herr_t H5LT_dtype_to_text(hid_t dtype, char **dt_str, H5LT_lang_t lang, size_t *
goto out;
if(H5Tset_strpad(str_type, str_pad)<0)
goto out;
-
+
/* Are the two types equal? */
if (H5Tequal(tmp_type, str_type)) {
strcat(*dt_str, "CTYPE H5T_FORTRAN_S1;\n");
@@ -2523,7 +2523,7 @@ next:
/* Print lead-in */
sprintf(*dt_str, "H5T_OPAQUE {\n");
indent += COL;
-
+
indentation(indent + COL, *dt_str);
sprintf(tmp_str, "OPQ_SIZE %lu;\n", (unsigned long)H5Tget_size(dtype));
strcat(*dt_str, tmp_str);
@@ -2531,7 +2531,7 @@ next:
indentation(indent + COL, *dt_str);
sprintf(tmp_str, "OPQ_TAG \"%s\";\n", H5Tget_tag(dtype));
strcat(*dt_str, tmp_str);
-
+
/* Print closing */
indent -= COL;
indentation(indent + COL, *dt_str);
@@ -2548,14 +2548,14 @@ next:
sprintf(*dt_str, "H5T_ENUM {\n");
indent += COL;
indentation(indent + COL, *dt_str);
-
+
if((super = H5Tget_super(dtype))<0)
goto out;
if(H5LTdtype_to_text(super, NULL, lang, &super_len)<0)
goto out;
stmp = (char*)calloc(super_len, sizeof(char));
if(H5LTdtype_to_text(super, stmp, lang, &super_len)<0)
- goto out;
+ goto out;
strcat(*dt_str, stmp);
free(stmp);
strcat(*dt_str, ";\n");
@@ -2588,7 +2588,7 @@ next:
goto out;
stmp = (char*)calloc(super_len, sizeof(char));
if(H5LTdtype_to_text(super, stmp, lang, &super_len)<0)
- goto out;
+ goto out;
strcat(*dt_str, stmp);
free(stmp);
strcat(*dt_str, "\n");
@@ -2633,7 +2633,7 @@ next:
goto out;
stmp = (char*)calloc(super_len, sizeof(char));
if(H5LTdtype_to_text(super, stmp, lang, &super_len)<0)
- goto out;
+ goto out;
strcat(*dt_str, stmp);
free(stmp);
strcat(*dt_str, "\n");
@@ -2655,7 +2655,7 @@ next:
size_t mlen;
char* mtmp;
int nmembs;
-
+
if((nmembs = H5Tget_nmembers(dtype))<0)
goto out;
@@ -2679,7 +2679,7 @@ next:
goto out;
mtmp = (char*)calloc(mlen, sizeof(char));
if(H5LTdtype_to_text(mtype, mtmp, lang, &mlen)<0)
- goto out;
+ goto out;
strcat(*dt_str, mtmp);
free(mtmp);
diff --git a/hl/src/H5LTanalyze.c b/hl/src/H5LTanalyze.c
index 2b31f11..2b2603c 100644
--- a/hl/src/H5LTanalyze.c
+++ b/hl/src/H5LTanalyze.c
@@ -829,7 +829,7 @@ hbool_t first_quote = 1;
/* For Lex and Yacc */
/*int input_len;
char *myinput;*/
-
+
#define TAG_STRING 1
#line 815 "H5LTanalyze.c"
@@ -1268,17 +1268,17 @@ YY_RULE_SETUP
case 40:
YY_RULE_SETUP
#line 120 "H5LTanalyze.l"
-{return token(H5T_STR_NULLTERM_TOKEN);}
+{return token(H5T_STR_NULLTERM_TOKEN);}
YY_BREAK
case 41:
YY_RULE_SETUP
#line 121 "H5LTanalyze.l"
-{return token(H5T_STR_NULLPAD_TOKEN);}
+{return token(H5T_STR_NULLPAD_TOKEN);}
YY_BREAK
case 42:
YY_RULE_SETUP
#line 122 "H5LTanalyze.l"
-{return token(H5T_STR_SPACEPAD_TOKEN);}
+{return token(H5T_STR_SPACEPAD_TOKEN);}
YY_BREAK
case 43:
YY_RULE_SETUP
@@ -1343,12 +1343,12 @@ YY_RULE_SETUP
case 55:
YY_RULE_SETUP
#line 138 "H5LTanalyze.l"
-{
- if( is_str_size || (is_enum && is_enum_memb) ||
+{
+ if( is_str_size || (is_enum && is_enum_memb) ||
is_opq_size || (asindex>-1 && arr_stack[asindex].is_dim) ||
(csindex>-1 && cmpd_stack[csindex].is_field) ) {
yylval.ival = atoi(yytext);
- return NUMBER;
+ return NUMBER;
} else
REJECT;
}
@@ -1358,7 +1358,7 @@ YY_RULE_SETUP
#line 148 "H5LTanalyze.l"
{
/*if it's first quote, and is a compound field name or an enum symbol*/
- if((is_opq_tag || is_enum || (csindex>-1 && cmpd_stack[csindex].is_field))
+ if((is_opq_tag || is_enum || (csindex>-1 && cmpd_stack[csindex].is_field))
&& first_quote) {
first_quote = 0;
BEGIN TAG_STRING;
@@ -2302,8 +2302,8 @@ int main()
int my_yyinput(char *buf, int max_size)
{
int ret;
-
- memcpy(buf, myinput, input_len);
+
+ memcpy(buf, myinput, input_len);
ret = input_len;
return ret;
}
diff --git a/hl/src/H5LTparse.c b/hl/src/H5LTparse.c
index 4867d5a..32258d0 100644
--- a/hl/src/H5LTparse.c
+++ b/hl/src/H5LTparse.c
@@ -17,7 +17,7 @@
*/
#ifndef lint
-static char const
+static char const
yyrcsid[] = "$FreeBSD: src/usr.bin/yacc/skeleton.c,v 1.28 2000/01/17 02:04:06 bde Exp $";
#endif
#include <stdlib.h>
@@ -65,7 +65,7 @@ struct arr_info {
};
/*stack for nested array type*/
struct arr_info arr_stack[STACK_SIZE];
-int asindex = -1; /*pointer to the top of array stack*/
+int asindex = -1; /*pointer to the top of array stack*/
hbool_t is_str_size = 0; /*flag to lexer for string size*/
hbool_t is_str_pad = 0; /*flag to lexer for string padding*/
@@ -73,7 +73,7 @@ H5T_pad_t str_pad; /*variable for string padding*/
H5T_cset_t str_cset; /*variable for string character set*/
hbool_t is_variable = 0; /*variable for variable-length string*/
size_t str_size; /*variable for string size*/
-
+
hid_t enum_id; /*type ID*/
hbool_t is_enum = 0; /*flag to lexer for enum type*/
hbool_t is_enum_memb = 0; /*flag to lexer for enum member*/
@@ -796,9 +796,9 @@ case 46:
break;
case 47:
#line 155 "H5LTparse.y"
-{ yyval.ival = cmpd_stack[csindex].id;
+{ yyval.ival = cmpd_stack[csindex].id;
cmpd_stack[csindex].id = 0;
- cmpd_stack[csindex].first_memb = 1;
+ cmpd_stack[csindex].first_memb = 1;
csindex--;
}
break;
@@ -808,7 +808,7 @@ case 50:
break;
case 51:
#line 166 "H5LTparse.y"
-{
+{
size_t origin_size, new_size;
hid_t dtype_id = cmpd_stack[csindex].id;
@@ -822,7 +822,7 @@ case 51:
cmpd_stack[csindex].first_memb = 0;
} else {
origin_size = H5Tget_size(dtype_id);
-
+
if(yyvsp[-1].ival == 0) {
new_size = origin_size + H5Tget_size(yyvsp[-6].ival);
H5Tset_size(dtype_id, new_size);
@@ -833,10 +833,10 @@ case 51:
H5Tinsert(dtype_id, yyvsp[-3].sval, yyvsp[-1].ival, yyvsp[-6].ival);
}
}
-
+
cmpd_stack[csindex].is_field = 0;
H5Tclose(yyvsp[-6].ival);
-
+
new_size = H5Tget_size(dtype_id);
}
break;
@@ -860,7 +860,7 @@ case 56:
break;
case 57:
#line 212 "H5LTparse.y"
-{
+{
yyval.ival = H5Tarray_create(yyvsp[-1].ival, arr_stack[asindex].ndims, arr_stack[asindex].dims, NULL);
arr_stack[asindex].ndims = 0;
asindex--;
@@ -874,9 +874,9 @@ break;
case 61:
#line 223 "H5LTparse.y"
{ int ndims = arr_stack[asindex].ndims;
- arr_stack[asindex].dims[ndims] = (hsize_t)yylval.ival;
+ arr_stack[asindex].dims[ndims] = (hsize_t)yylval.ival;
arr_stack[asindex].ndims++;
- arr_stack[asindex].is_dim = 0;
+ arr_stack[asindex].is_dim = 0;
}
break;
case 64:
@@ -889,10 +889,10 @@ case 65:
break;
case 66:
#line 240 "H5LTparse.y"
-{
+{
size_t size = (size_t)yylval.ival;
yyval.ival = H5Tcreate(H5T_OPAQUE, size);
- is_opq_size = 0;
+ is_opq_size = 0;
}
break;
case 67:
@@ -901,7 +901,7 @@ case 67:
break;
case 68:
#line 246 "H5LTparse.y"
-{
+{
H5Tset_tag(yyvsp[-6].ival, yylval.sval);
is_opq_tag = 0;
}
@@ -916,12 +916,12 @@ case 72:
break;
case 73:
#line 259 "H5LTparse.y"
-{
+{
if(yyvsp[-1].ival == H5T_VARIABLE_TOKEN)
is_variable = 1;
- else
+ else
str_size = yylval.ival;
- is_str_size = 0;
+ is_str_size = 0;
}
break;
case 74:
@@ -937,7 +937,7 @@ case 74:
break;
case 75:
#line 276 "H5LTparse.y"
-{
+{
if(yyvsp[-1].ival == H5T_CSET_ASCII_TOKEN)
str_cset = H5T_CSET_ASCII;
else if(yyvsp[-1].ival == H5T_CSET_UTF8_TOKEN)
@@ -955,7 +955,7 @@ case 76:
break;
case 77:
#line 290 "H5LTparse.y"
-{
+{
hid_t str_id = yyvsp[-1].ival;
/*set string size*/
@@ -964,12 +964,12 @@ case 77:
is_variable = 0;
} else
H5Tset_size(str_id, str_size);
-
+
/*set string padding and character set*/
H5Tset_strpad(str_id, str_pad);
H5Tset_cset(str_id, str_cset);
- yyval.ival = str_id;
+ yyval.ival = str_id;
}
break;
case 78:
@@ -1016,7 +1016,7 @@ case 91:
#line 329 "H5LTparse.y"
{
is_enum_memb = 1; /*indicate member of enum*/
- enum_memb_symbol = strdup(yylval.sval);
+ enum_memb_symbol = strdup(yylval.sval);
}
break;
case 92:
@@ -1029,7 +1029,7 @@ case 92:
long_long llong_val=(long_long)yylval.ival;
hid_t super = H5Tget_super(enum_id);
hid_t native = H5Tget_native_type(super, H5T_DIR_ASCEND);
-
+
if(is_enum && is_enum_memb) { /*if it's an enum member*/
/*To handle machines of different endianness*/
if(H5Tequal(native, H5T_NATIVE_SCHAR) || H5Tequal(native, H5T_NATIVE_UCHAR))
@@ -1043,7 +1043,7 @@ case 92:
else if(H5Tequal(native, H5T_NATIVE_LLONG) || H5Tequal(native, H5T_NATIVE_ULLONG))
H5Tenum_insert(enum_id, enum_memb_symbol, &llong_val);
- is_enum_memb = 0;
+ is_enum_memb = 0;
if(enum_memb_symbol) free(enum_memb_symbol);
}
diff --git a/hl/src/H5LTprivate.h b/hl/src/H5LTprivate.h
index 426c223..6e54c54 100644
--- a/hl/src/H5LTprivate.h
+++ b/hl/src/H5LTprivate.h
@@ -19,7 +19,7 @@
#include "H5HLprivate2.h"
/* public LT prototypes */
-#include "H5LTpublic.h"
+#include "H5LTpublic.h"
/*-------------------------------------------------------------------------
* Private functions
@@ -49,7 +49,7 @@ H5_HLDLL herr_t H5LT_set_attribute_string( hid_t dset_id,
H5_HLDLL herr_t H5LT_find_attribute( hid_t loc_id, const char *name );
-H5_HLDLL herr_t H5LT_dtype_to_text(hid_t dtype, char **dt_str, H5LT_lang_t lang,
+H5_HLDLL herr_t H5LT_dtype_to_text(hid_t dtype, char **dt_str, H5LT_lang_t lang,
size_t *slen, hbool_t no_user_buf);
diff --git a/hl/src/H5PTprivate.h b/hl/src/H5PTprivate.h
index 3bba9d2..4c36813 100644
--- a/hl/src/H5PTprivate.h
+++ b/hl/src/H5PTprivate.h
@@ -19,7 +19,7 @@
#include "H5HLprivate2.h"
/* public LT prototypes */
-#include "H5PTpublic.h"
+#include "H5PTpublic.h"
#endif
diff --git a/hl/src/H5TB.c b/hl/src/H5TB.c
index d9579c3..7cbd5c4 100644
--- a/hl/src/H5TB.c
+++ b/hl/src/H5TB.c
@@ -3686,40 +3686,40 @@ herr_t H5TB_common_append_records( hid_t dataset_id,
hid_t mem_space_id = H5I_BADID;
hsize_t dims[1];
hsize_t mem_dims[1];
-
+
/* Extend the dataset */
dims[0] = nrecords + orig_table_size;
if ( H5Dextend ( dataset_id, dims ) < 0 )
goto out;
-
+
/* Create a simple memory data space */
mem_dims[0]=nrecords;
if ( (mem_space_id = H5Screate_simple( 1, mem_dims, NULL )) < 0 )
goto out;
-
+
/* Get a copy of the new file data space for writing */
if ( (space_id = H5Dget_space( dataset_id )) < 0 )
goto out;
-
+
/* Define a hyperslab in the dataset */
offset[0] = orig_table_size;
count[0] = nrecords;
if ( H5Sselect_hyperslab( space_id, H5S_SELECT_SET, offset, NULL, count, NULL)<0)
goto out;
-
+
/* Write the records */
if ( H5Dwrite( dataset_id, mem_type_id, mem_space_id, space_id, H5P_DEFAULT, data )<0)
goto out;
-
+
/* Terminate access to the dataspace */
if ( H5Sclose( mem_space_id ) < 0 )
goto out;
-
+
if ( H5Sclose( space_id ) < 0 )
goto out;
-
+
return 0;
-
+
out:
H5E_BEGIN_TRY
H5Sclose(mem_space_id);
@@ -3760,38 +3760,38 @@ herr_t H5TB_common_read_records( hid_t dataset_id,
hid_t space_id = H5I_BADID;
hid_t mem_space_id = H5I_BADID;
hsize_t mem_size[1];
-
+
/* Make sure the read request is in bounds */
if ( start + nrecords > table_size )
goto out;
-
+
/* Get the dataspace handle */
if ( (space_id = H5Dget_space( dataset_id )) < 0 )
goto out;
-
+
/* Define a hyperslab in the dataset of the size of the records */
offset[0] = start;
count[0] = nrecords;
if ( H5Sselect_hyperslab( space_id, H5S_SELECT_SET, offset, NULL, count, NULL) < 0 )
goto out;
-
+
/* Create a memory dataspace handle */
mem_size[0] = count[0];
if ((mem_space_id = H5Screate_simple( 1, mem_size, NULL )) < 0 )
goto out;
if ((H5Dread( dataset_id, mem_type_id, mem_space_id, space_id, H5P_DEFAULT, data))<0)
goto out;
-
+
/* Terminate access to the memory dataspace */
if ( H5Sclose( mem_space_id ) < 0 )
goto out;
-
+
/* Terminate access to the dataspace */
if ( H5Sclose( space_id ) < 0 )
goto out;
-
+
return 0;
-
+
out:
H5E_BEGIN_TRY
H5Sclose(space_id);
diff --git a/hl/test/test_lite.c b/hl/test/test_lite.c
index 07002e0..19d772f 100644
--- a/hl/test/test_lite.c
+++ b/hl/test/test_lite.c
@@ -1057,31 +1057,31 @@ static int test_integers(void)
size_t str_len;
TESTING3("\n text for integer types");
-
+
if((dtype = H5LTtext_to_dtype("H5T_NATIVE_INT\n", H5LT_DDL))<0)
goto out;
if(!H5Tequal(dtype, H5T_NATIVE_INT))
goto out;
if(H5Tclose(dtype)<0)
goto out;
-
+
if((dtype = H5LTtext_to_dtype("H5T_STD_I8BE\n", H5LT_DDL))<0)
goto out;
if(!H5Tequal(dtype, H5T_STD_I8BE))
goto out;
-
+
if(H5LTdtype_to_text(dtype, NULL, H5LT_DDL, &str_len)<0)
- goto out;
+ goto out;
dt_str = (char*)calloc(str_len, sizeof(char));
if(H5LTdtype_to_text(dtype, dt_str, H5LT_DDL, &str_len)<0)
- goto out;
+ goto out;
if(strcmp(dt_str, "H5T_STD_I8BE"))
goto out;
free(dt_str);
if(H5Tclose(dtype)<0)
goto out;
-
+
if((dtype = H5LTtext_to_dtype("H5T_STD_U16LE\n", H5LT_DDL))<0)
goto out;
if(!H5Tequal(dtype, H5T_STD_U16LE))
@@ -1108,31 +1108,31 @@ static int test_fps(void)
size_t str_len;
TESTING3(" text for floating-point types");
-
+
if((dtype = H5LTtext_to_dtype("H5T_NATIVE_LDOUBLE\n", H5LT_DDL))<0)
goto out;
if(!H5Tequal(dtype, H5T_NATIVE_LDOUBLE))
goto out;
if(H5Tclose(dtype)<0)
goto out;
-
+
if((dtype = H5LTtext_to_dtype("H5T_IEEE_F32BE\n", H5LT_DDL))<0)
goto out;
if(!H5Tequal(dtype, H5T_IEEE_F32BE))
goto out;
-
+
if(H5LTdtype_to_text(dtype, NULL, H5LT_DDL, &str_len)<0)
- goto out;
+ goto out;
dt_str = (char*)calloc(str_len, sizeof(char));
if(H5LTdtype_to_text(dtype, dt_str, H5LT_DDL, &str_len)<0)
- goto out;
+ goto out;
if(strcmp(dt_str, "H5T_IEEE_F32BE"))
goto out;
free(dt_str);
if(H5Tclose(dtype)<0)
goto out;
-
+
if((dtype = H5LTtext_to_dtype("H5T_IEEE_F64LE\n", H5LT_DDL))<0)
goto out;
if(!H5Tequal(dtype, H5T_IEEE_F64LE))
@@ -1161,12 +1161,12 @@ static int test_strings(void)
H5T_class_t type_class;
char* dt_str;
size_t str_len;
-
+
TESTING3(" text for string types");
-
+
if((dtype = H5LTtext_to_dtype("H5T_STRING { STRSIZE 13; STRPAD H5T_STR_NULLTERM; CSET H5T_CSET_ASCII; CTYPE H5T_C_S1; }", H5LT_DDL))<0)
goto out;
-
+
if((type_class = H5Tget_class(dtype))<0)
goto out;
if(type_class != H5T_STRING)
@@ -1175,57 +1175,57 @@ static int test_strings(void)
str_size = H5Tget_size(dtype);
if(str_size != 13)
goto out;
-
+
str_pad = H5Tget_strpad(dtype);
if(str_pad != H5T_STR_NULLTERM)
goto out;
-
+
str_cset = H5Tget_cset(dtype);
if(str_cset != H5T_CSET_ASCII)
goto out;
-
+
if(H5LTdtype_to_text(dtype, NULL, H5LT_DDL, &str_len)<0)
- goto out;
+ goto out;
dt_str = (char*)calloc(str_len, sizeof(char));
if(H5LTdtype_to_text(dtype, dt_str, H5LT_DDL, &str_len)<0)
- goto out;
+ goto out;
if(strcmp(dt_str, "H5T_STRING {\n STRSIZE 13;\n STRPAD H5T_STR_NULLTERM;\n CSET H5T_CSET_ASCII;\n CTYPE H5T_C_S1;\n }")) {
printf("dt=\n%s\n", dt_str);
goto out;
}
free(dt_str);
-
+
if(H5Tclose(dtype)<0)
goto out;
-
+
if((dtype = H5LTtext_to_dtype("H5T_STRING { STRSIZE H5T_VARIABLE; STRPAD H5T_STR_NULLPAD; CSET H5T_CSET_ASCII; CTYPE H5T_C_S1; }", H5LT_DDL))<0)
goto out;
-
+
if(!H5Tis_variable_str(dtype))
goto out;
-
+
str_pad = H5Tget_strpad(dtype);
if(str_pad != H5T_STR_NULLPAD)
goto out;
-
+
str_cset = H5Tget_cset(dtype);
if(str_cset != H5T_CSET_ASCII)
goto out;
if(H5LTdtype_to_text(dtype, NULL, H5LT_DDL, &str_len)<0)
- goto out;
+ goto out;
dt_str = (char*)calloc(str_len, sizeof(char));
if(H5LTdtype_to_text(dtype, dt_str, H5LT_DDL, &str_len)<0)
- goto out;
+ goto out;
if(strcmp(dt_str, "H5T_STRING {\n STRSIZE H5T_VARIABLE;\n STRPAD H5T_STR_NULLPAD;\n CSET H5T_CSET_ASCII;\n CTYPE H5T_C_S1;\n }")) {
printf("dt=\n%s\n", dt_str);
goto out;
}
free(dt_str);
-
+
if(H5Tclose(dtype)<0)
goto out;
-
+
PASSED();
return 0;
@@ -1247,25 +1247,25 @@ static int test_opaques(void)
size_t str_len;
TESTING3(" text for opaque types");
-
+
if((dtype = H5LTtext_to_dtype("H5T_OPAQUE { OPQ_SIZE 19; OPQ_TAG \"This is a tag for opaque type\"; }", H5LT_DDL))<0)
goto out;
-
+
if((type_class = H5Tget_class(dtype))<0)
goto out;
if(type_class != H5T_OPAQUE)
goto out;
-
+
if((opq_size = H5Tget_size(dtype)) == 0)
goto out;
if(opq_size != 19)
goto out;
-
+
if(H5LTdtype_to_text(dtype, NULL, H5LT_DDL, &str_len)<0)
- goto out;
+ goto out;
dt_str = (char*)calloc(str_len, sizeof(char));
if(H5LTdtype_to_text(dtype, dt_str, H5LT_DDL, &str_len)<0)
- goto out;
+ goto out;
if(strcmp(dt_str, "H5T_OPAQUE {\n OPQ_SIZE 19;\n OPQ_TAG \"This is a tag for opaque type\";\n }")) {
printf("dt=\n%s\n", dt_str);
goto out;
@@ -1274,7 +1274,7 @@ static int test_opaques(void)
if(H5Tclose(dtype)<0)
goto out;
-
+
PASSED();
return 0;
@@ -1298,12 +1298,12 @@ static int test_enums(void)
H5T_class_t type_class;
char* dt_str;
size_t str_len;
-
+
TESTING3(" text for enum types");
-
+
if((dtype = H5LTtext_to_dtype("H5T_ENUM { H5T_STD_I32LE; \"RED\" 5; \"GREEN\" 6; \"BLUE\" 7; \"WHITE\" 8; }", H5LT_DDL))<0)
goto out;
-
+
if((type_class = H5Tget_class(dtype))<0)
goto out;
if(type_class != H5T_ENUM)
@@ -1312,27 +1312,27 @@ static int test_enums(void)
if(H5Tenum_nameof(dtype, &value1, name1, size)<0)
goto out;
if(strcmp(name1, "BLUE"))
- goto out;
-
+ goto out;
+
if(H5Tenum_valueof(dtype, name2, &value2)<0)
goto out;
if(value2 != 8)
goto out;
-
+
if(H5LTdtype_to_text(dtype, NULL, H5LT_DDL, &str_len)<0)
- goto out;
+ goto out;
dt_str = (char*)calloc(str_len, sizeof(char));
if(H5LTdtype_to_text(dtype, dt_str, H5LT_DDL, &str_len)<0)
- goto out;
+ goto out;
/*if(strcmp(dt_str, "H5T_ENUM {\n H5T_STD_I32LE;\n \"RED\" 5;\n \"GREEN\" 6;\n \"BLUE\" 7;\n \"WHITE\" 8;\n }")) {
printf("dt=\n%s\n", dt_str);
goto out;
}*/
free(dt_str);
-
+
if(H5Tclose(dtype)<0)
goto out;
-
+
PASSED();
return 0;
@@ -1351,34 +1351,34 @@ static int test_variables(void)
H5T_class_t type_class;
char* dt_str;
size_t str_len;
-
+
TESTING3(" text for variable types");
-
+
if((dtype = H5LTtext_to_dtype("H5T_VLEN { H5T_NATIVE_CHAR }\n", H5LT_DDL))<0)
goto out;
-
+
if((type_class = H5Tget_class(dtype))<0)
goto out;
if(type_class != H5T_VLEN)
goto out;
-
+
if(H5Tis_variable_str(dtype))
goto out;
if(H5Tclose(dtype)<0)
goto out;
-
+
if((dtype = H5LTtext_to_dtype("H5T_VLEN { H5T_VLEN { H5T_STD_I32BE } }", H5LT_DDL))<0)
goto out;
-
+
if(H5Tis_variable_str(dtype))
goto out;
if(H5LTdtype_to_text(dtype, NULL, H5LT_DDL, &str_len)<0)
- goto out;
+ goto out;
dt_str = (char*)calloc(str_len, sizeof(char));
if(H5LTdtype_to_text(dtype, dt_str, H5LT_DDL, &str_len)<0)
- goto out;
+ goto out;
if(strcmp(dt_str, "H5T_VLEN {\n H5T_VLEN {\n H5T_STD_I32BE\n }\n }")) {
printf("dt=\n%s\n", dt_str);
goto out;
@@ -1387,7 +1387,7 @@ static int test_variables(void)
if(H5Tclose(dtype)<0)
goto out;
-
+
PASSED();
return 0;
@@ -1410,19 +1410,19 @@ static int test_arrays(void)
size_t str_len;
TESTING3(" text for array types");
-
+
if((dtype = H5LTtext_to_dtype("H5T_ARRAY { [5][7][13] H5T_ARRAY { [17][19] H5T_COMPOUND { H5T_STD_I8BE \"arr_compound_1\"; H5T_STD_I32BE \"arr_compound_2\"; } } }", H5LT_DDL))<0)
goto out;
-
+
if((type_class = H5Tget_class(dtype))<0)
goto out;
if(type_class != H5T_ARRAY)
goto out;
-
+
if((ndims = H5Tget_array_ndims(dtype))<0)
goto out;
if(ndims != 3)
- goto out;
+ goto out;
if(H5Tget_array_dims(dtype, dims, NULL)<0)
goto out;
@@ -1430,10 +1430,10 @@ static int test_arrays(void)
goto out;
if(H5LTdtype_to_text(dtype, NULL, H5LT_DDL, &str_len)<0)
- goto out;
+ goto out;
dt_str = (char*)calloc(str_len, sizeof(char));
if(H5LTdtype_to_text(dtype, dt_str, H5LT_DDL, &str_len)<0)
- goto out;
+ goto out;
/*if(strcmp(dt_str, "H5T_ARRAY { [5][7][13] H5T_ARRAY { [17][19] H5T_COMPOUND { H5T_STD_I8BE \"arr_compound_1\"; H5T_STD_I32BE \"arr_compound_2\"; } } }")) {
printf("dt=\n%s\n", dt_str);
goto out;
@@ -1442,7 +1442,7 @@ static int test_arrays(void)
if(H5Tclose(dtype)<0)
goto out;
-
+
PASSED();
return 0;
@@ -1464,12 +1464,12 @@ static int test_compounds(void)
H5T_class_t type_class;
char* dt_str;
size_t str_len;
-
+
TESTING3(" text for compound types");
-
+
if((dtype = H5LTtext_to_dtype("H5T_COMPOUND { H5T_STD_I16BE \"one_field\" : 2; H5T_STD_U8LE \"two_field\" : 6; }", H5LT_DDL))<0)
goto out;
-
+
if((type_class = H5Tget_class(dtype))<0)
goto out;
if(type_class != H5T_COMPOUND)
@@ -1481,26 +1481,26 @@ static int test_compounds(void)
goto out;
if(H5LTdtype_to_text(dtype, NULL, H5LT_DDL, &str_len)<0)
- goto out;
+ goto out;
dt_str = (char*)calloc(str_len, sizeof(char));
if(H5LTdtype_to_text(dtype, dt_str, H5LT_DDL, &str_len)<0)
- goto out;
+ goto out;
if(strcmp(dt_str, "H5T_COMPOUND {\n H5T_STD_I16BE \"one_field\" : 2;\n H5T_STD_U8LE \"two_field\" : 6;\n }")) {
printf("dt=\n%s\n", dt_str);
goto out;
}
free(dt_str);
-
+
if(H5Tclose(dtype)<0)
goto out;
-
+
if((dtype = H5LTtext_to_dtype("H5T_COMPOUND { H5T_STD_I32BE \"i32_field\"; H5T_STD_I16BE \"i16_field\"; H5T_COMPOUND { H5T_STD_I16BE \"sec_field\"; H5T_COMPOUND { H5T_STD_I32BE \"thd_field\"; } \"grandchild\"; } \"child_compound\"; H5T_STD_I8BE \"i8_field\"; }", H5LT_DDL))<0)
goto out;
-
+
if((memb_name = H5Tget_member_name(dtype, 1)) == NULL)
- goto out;
+ goto out;
if(strcmp(memb_name, "i16_field"))
- goto out;
+ goto out;
free(memb_name);
if((memb_class = H5Tget_member_class(dtype, 2))<0)
@@ -1531,7 +1531,7 @@ static int test_complicated_compound(void)
int size = 1024;
char *srcdir = getenv("srcdir"); /* the source directory */
char filename[1024]="";
-
+
TESTING3(" text for complicated compound types");
/* compose the name of the file to open, using the srcdir, if appropriate */
@@ -1550,8 +1550,8 @@ static int test_complicated_compound(void)
goto out;
}
- /* This part reads in the input as a string in a slow manner. GNU C
- * Library has convenient function getline() but isn't available on
+ /* This part reads in the input as a string in a slow manner. GNU C
+ * Library has convenient function getline() but isn't available on
* all machines.
*/
if((line = (char*)calloc(size, sizeof(char)))==NULL)
@@ -1574,13 +1574,13 @@ static int test_complicated_compound(void)
if((dtype = H5LTtext_to_dtype(line, H5LT_DDL))<0)
goto out;
-
+
if((type_class = H5Tget_class(dtype))<0)
goto out;
if(type_class != H5T_COMPOUND)
goto out;
- /* There should be 101 compound members */
+ /* There should be 101 compound members */
if((nmembs = H5Tget_nmembers(dtype))<0)
goto out;
if(nmembs != 101)
@@ -1601,7 +1601,7 @@ out:
* test H5LTtext_to_dtype function
*-------------------------------------------------------------------------
*/
-static int test_text_dtype(void)
+static int test_text_dtype(void)
{
TESTING("H5LTtext_to_dtype");
@@ -1613,22 +1613,22 @@ static int test_text_dtype(void)
if(test_strings()<0)
goto out;
-
+
if(test_opaques()<0)
goto out;
-
+
if(test_enums()<0)
goto out;
-
+
if(test_variables()<0)
goto out;
-
+
if(test_arrays()<0)
goto out;
-
+
if(test_compounds()<0)
goto out;
-
+
if(test_complicated_compound()<0)
goto out;
@@ -1651,7 +1651,7 @@ int main( void )
/* test attribute functions */
nerrors += test_attr();
-
+
/* test text-dtype functions */
nerrors += test_text_dtype();
diff --git a/perform/benchpar.c b/perform/benchpar.c
index 947a20c..517e4e0 100644
--- a/perform/benchpar.c
+++ b/perform/benchpar.c
@@ -23,15 +23,15 @@
/* Local macros */
-/*
+/*
* HDF Boolean type.
*/
#ifndef FALSE
# define FALSE 0
#endif
#ifndef TRUE
-# define TRUE 1
-#endif
+# define TRUE 1
+#endif
/* defines for type of VFL driver to use */
#define FACC_DEFAULT 0
diff --git a/perform/pio_engine.c b/perform/pio_engine.c
index 8b0a7d0..833eabd 100644
--- a/perform/pio_engine.c
+++ b/perform/pio_engine.c
@@ -652,12 +652,12 @@ do_write(results *res, file_descr *fd, parameters *parms, long ndsets,
} /* end if */
/* 2D dataspace */
else {
- /* Build partial buffer derived type for contiguous access */
+ /* Build partial buffer derived type for contiguous access */
mrc = MPI_Type_contiguous((int)buf_size, MPI_BYTE,
&contig_cont);
VRFY((mrc==MPI_SUCCESS), "MPIO_TYPE_CREATE");
- /* Build contiguous file's derived type */
+ /* Build contiguous file's derived type */
mrc = MPI_Type_vector((int)blk_size, (int)1, (int)(snbytes/buf_size),
contig_cont, &mpi_cont_type);
VRFY((mrc==MPI_SUCCESS), "MPIO_TYPE_CREATE");
@@ -666,12 +666,12 @@ do_write(results *res, file_descr *fd, parameters *parms, long ndsets,
mrc = MPI_Type_commit(&mpi_cont_type);
VRFY((mrc==MPI_SUCCESS), "MPIO_TYPE_COMMIT");
- /* Build partial buffer derived type for interleaved access */
+ /* Build partial buffer derived type for interleaved access */
mrc = MPI_Type_contiguous((int)blk_size, MPI_BYTE,
&contig_inter);
VRFY((mrc==MPI_SUCCESS), "MPIO_TYPE_CREATE");
- /* Build interleaved file's derived type */
+ /* Build interleaved file's derived type */
mrc = MPI_Type_vector((int)buf_size, (int)1, (int)(snbytes/blk_size),
contig_inter, &mpi_inter_type);
VRFY((mrc==MPI_SUCCESS), "MPIO_TYPE_CREATE");
@@ -707,7 +707,7 @@ do_write(results *res, file_descr *fd, parameters *parms, long ndsets,
h5count[0] = buf_size/blk_size;
} /* end else */
hrc = H5Sselect_hyperslab(h5dset_space_id, H5S_SELECT_SET,
- h5start, h5stride, h5count, h5block);
+ h5start, h5stride, h5count, h5block);
VRFY((hrc >= 0), "H5Sselect_hyperslab");
} /* end if */
else {
@@ -757,7 +757,7 @@ do_write(results *res, file_descr *fd, parameters *parms, long ndsets,
h5count[1] = 1;
} /* end else */
hrc = H5Sselect_hyperslab(h5dset_space_id, H5S_SELECT_SET,
- h5start, h5stride, h5count, h5block);
+ h5start, h5stride, h5count, h5block);
VRFY((hrc >= 0), "H5Sselect_hyperslab");
} /* end if */
else {
@@ -959,7 +959,7 @@ do_write(results *res, file_descr *fd, parameters *parms, long ndsets,
/* Set the base of user's buffer */
buf_p = (unsigned char *)buffer;
- /* Set the number of bytes to transfer this time */
+ /* Set the number of bytes to transfer this time */
nbytes_toxfer = buf_size*blk_size;
/* Compute file offset */
@@ -995,7 +995,7 @@ do_write(results *res, file_descr *fd, parameters *parms, long ndsets,
/* Set the base of user's buffer */
buf_p=(unsigned char *)buffer;
- /* Set the number of bytes to transfer this time */
+ /* Set the number of bytes to transfer this time */
nbytes_toxfer=buf_size*blk_size;
/* Compute file offset */
@@ -1522,7 +1522,7 @@ do_read(results *res, file_descr *fd, parameters *parms, long ndsets,
&contig_cont);
VRFY((mrc==MPI_SUCCESS), "MPIO_TYPE_CREATE");
- /* Build contiguous file's derived type */
+ /* Build contiguous file's derived type */
mrc = MPI_Type_vector((int)blk_size, (int)1, (int)(snbytes/buf_size),
contig_cont, &mpi_cont_type);
VRFY((mrc==MPI_SUCCESS), "MPIO_TYPE_CREATE");
@@ -1536,7 +1536,7 @@ do_read(results *res, file_descr *fd, parameters *parms, long ndsets,
&contig_inter);
VRFY((mrc==MPI_SUCCESS), "MPIO_TYPE_CREATE");
- /* Build interleaved file's derived type */
+ /* Build interleaved file's derived type */
mrc = MPI_Type_vector((int)buf_size, (int)1, (int)(snbytes/blk_size),
contig_inter, &mpi_inter_type);
VRFY((mrc==MPI_SUCCESS), "MPIO_TYPE_CREATE");
@@ -1572,7 +1572,7 @@ do_read(results *res, file_descr *fd, parameters *parms, long ndsets,
h5count[0] = buf_size/blk_size;
} /* end else */
hrc = H5Sselect_hyperslab(h5dset_space_id, H5S_SELECT_SET,
- h5start, h5stride, h5count, h5block);
+ h5start, h5stride, h5count, h5block);
VRFY((hrc >= 0), "H5Sselect_hyperslab");
} /* end if */
else {
@@ -1622,7 +1622,7 @@ do_read(results *res, file_descr *fd, parameters *parms, long ndsets,
h5count[1] = 1;
} /* end else */
hrc = H5Sselect_hyperslab(h5dset_space_id, H5S_SELECT_SET,
- h5start, h5stride, h5count, h5block);
+ h5start, h5stride, h5count, h5block);
VRFY((hrc >= 0), "H5Sselect_hyperslab");
} /* end if */
else {
@@ -1783,7 +1783,7 @@ do_read(results *res, file_descr *fd, parameters *parms, long ndsets,
/* Set the base of user's buffer */
buf_p = (unsigned char *)buffer;
- /* Set the number of bytes to transfer this time */
+ /* Set the number of bytes to transfer this time */
nbytes_toxfer = buf_size*blk_size;
/* Compute file offset */
@@ -1819,7 +1819,7 @@ do_read(results *res, file_descr *fd, parameters *parms, long ndsets,
/* Set the base of user's buffer */
buf_p=(unsigned char *)buffer;
- /* Set the number of bytes to transfer this time */
+ /* Set the number of bytes to transfer this time */
nbytes_toxfer=buf_size*blk_size;
/* Compute file offset */
@@ -2303,7 +2303,7 @@ do_fopen(parameters *param, char *fname, file_descr *fd /*out*/, int flags)
} /* end if */
else {
/* Set the file driver to the MPI-I/O driver */
- hrc = H5Pset_fapl_mpio(acc_tpl, pio_comm_g, h5_io_info_g);
+ hrc = H5Pset_fapl_mpio(acc_tpl, pio_comm_g, h5_io_info_g);
if (hrc < 0) {
fprintf(stderr, "HDF5 Property List Set failed\n");
GOTOERROR(FAIL);
@@ -2338,7 +2338,7 @@ do_fopen(parameters *param, char *fname, file_descr *fd /*out*/, int flags)
}
break;
- }
+ }
done:
return ret_code;
diff --git a/perform/pio_perf.c b/perform/pio_perf.c
index f19afa7..2bb3a67 100644
--- a/perform/pio_perf.c
+++ b/perform/pio_perf.c
@@ -465,7 +465,7 @@ run_test_loop(struct options *opts)
parms.num_bytes = (off_t)pow((double)(opts->num_bpp*parms.num_procs),2);
if (parms.interleaved)
output_report("Transfer Buffer Size: %ldx%ld bytes, File size: %.2f MBs\n",
- buf_size, opts->blk_size,
+ buf_size, opts->blk_size,
((double)parms.num_dsets * (double)parms.num_bytes)
/ ONE_MB);
else
@@ -669,7 +669,7 @@ run_test(iotype iot, parameters parms, struct options *opts)
get_minmax(&read_close_mm, t);
read_close_mm_table[i] = read_close_mm;
-
+
}
pio_time_destroy(res.timers);
@@ -739,7 +739,7 @@ run_test(iotype iot, parameters parms, struct options *opts)
}
-
+
if (!parms.h5_write_only) {
/* Read statistics */
/* Print the raw data throughput if desired */
@@ -1196,7 +1196,7 @@ report_parameters(struct options *opts)
HDfprintf(output, "2D\n");
else
HDfprintf(output, "1D\n");
-
+
HDfprintf(output, "rank %d: VFL used for HDF5 I/O=", rank);
if(opts->h5_use_mpi_posix)
HDfprintf(output, "MPI-posix driver\n");
diff --git a/perform/pio_standalone.c b/perform/pio_standalone.c
index 33d2ccc..2ad0916 100644
--- a/perform/pio_standalone.c
+++ b/perform/pio_standalone.c
@@ -107,7 +107,7 @@ get_option(int argc, const char **argv, const char *opts, const struct long_opti
opt_opt = argv[opt_ind][sp];
if (opt_opt == ':' || (cp = strchr(opts, opt_opt)) == 0) {
-
+
if (opt_err)
HDfprintf(stderr, "%s: unknown option \"%c\"\n",
argv[0], opt_opt);
diff --git a/perform/pio_timer.c b/perform/pio_timer.c
index a528e5d..3d0cb3e 100644
--- a/perform/pio_timer.c
+++ b/perform/pio_timer.c
@@ -38,11 +38,11 @@
/* global variables */
pio_time *timer_g; /* timer: global for stub functions */
-/*
+/*
* Function: sub_time
* Purpose: Struct two time values, and return the difference, in microseconds
- *
- * Note that the function assumes that a > b
+ *
+ * Note that the function assumes that a > b
* Programmer: Leon Arber, 1/27/06
*/
static double sub_time(struct timeval* a, struct timeval* b)
@@ -145,7 +145,7 @@ set_time(pio_time *pt, timer_type t, int start_stop)
} else {
pt->total_time[t] += MPI_Wtime() - pt->mpi_timer[t];
- pt->mpi_timer[t] = MPI_Wtime();
+ pt->mpi_timer[t] = MPI_Wtime();
/* When we stop the timer for HDF5_GROSS_WRITE_FIXED_DIMS or HDF5_GROSS_READ_FIXED_DIMS
* we compute the time it took to close the file after the last read/write finished */
@@ -165,7 +165,7 @@ set_time(pio_time *pt, timer_type t, int start_stop)
else if(t == HDF5_FINE_READ_FIXED_DIMS)
pt->total_time[HDF5_FILE_READ_OPEN] += sub_time(&(pt->sys_timer[t]), &(pt->sys_timer[HDF5_GROSS_READ_FIXED_DIMS]));
-
+
} else {
struct timeval sys_t;
@@ -183,7 +183,7 @@ set_time(pio_time *pt, timer_type t, int start_stop)
pt->total_time[HDF5_FILE_WRITE_CLOSE] += sub_time(&(pt->sys_timer[t]), &(pt->sys_timer[HDF5_FINE_WRITE_FIXED_DIMS]));
else if(t == HDF5_GROSS_READ_FIXED_DIMS)
pt->total_time[HDF5_FILE_READ_CLOSE] += sub_time(&(pt->sys_timer[t]), &(pt->sys_timer[HDF5_FINE_READ_FIXED_DIMS]));
-
+
}
}
diff --git a/src/H5.c b/src/H5.c
index 0bbe225..7ca10d5 100644
--- a/src/H5.c
+++ b/src/H5.c
@@ -3127,11 +3127,11 @@ H5_trace (const double *returning, const char *func, const char *type, ...)
* Function: HDrand/HDsrand
*
* Purpose: Wrapper function for rand. If rand_r exists on this system,
- * use it.
+ * use it.
*
* Wrapper function for srand. If rand_r is available, it will keep
* track of the seed locally instead of using srand() which modifies
- * global state and can break other programs.
+ * global state and can break other programs.
*
* Return: Success: Random number from 0 to RAND_MAX
*
@@ -3154,7 +3154,7 @@ int HDrand(void)
void HDsrand(unsigned int seed)
{
- g_seed = seed;
+ g_seed = seed;
}
#endif
diff --git a/src/H5A.c b/src/H5A.c
index abd70b5..43759b8 100644
--- a/src/H5A.c
+++ b/src/H5A.c
@@ -1071,7 +1071,7 @@ H5Aget_create_plist(hid_t attr_id)
/* Set the character encoding on the new property list */
if(H5P_set(new_plist, H5A_CHAR_ENCODING_NAME, &(attr->encoding)) < 0)
HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set character encoding")
-
+
ret_value = new_plist_id;
done:
@@ -1700,7 +1700,7 @@ H5A_close(H5A_t *attr)
/* Free temporary buffer */
tmp_buf = H5FL_BLK_FREE(attr_buf, tmp_buf);
} /* end if */
-
+
/* Free dynamicly allocated items */
if(H5A_free(attr) < 0)
HGOTO_ERROR(H5E_ATTR, H5E_CANTRELEASE, FAIL, "can't release attribute info")
diff --git a/src/H5AC.c b/src/H5AC.c
index 798c0b5..cf794c6 100644
--- a/src/H5AC.c
+++ b/src/H5AC.c
@@ -78,19 +78,19 @@ H5FL_DEFINE_STATIC(H5AC_aux_t);
* structure H5AC_slist_entry_t
*
* The dirty entry list maintained via the d_slist_ptr field of H5AC_aux_t
- * and the cleaned entry list maintained via the c_slist_ptr field of
- * H5AC_aux_t are just lists of the file offsets of the dirty/cleaned
- * entries. Unfortunately, the slist code makes us define a dynamically
- * allocated structure to store these offsets in. This structure serves
+ * and the cleaned entry list maintained via the c_slist_ptr field of
+ * H5AC_aux_t are just lists of the file offsets of the dirty/cleaned
+ * entries. Unfortunately, the slist code makes us define a dynamically
+ * allocated structure to store these offsets in. This structure serves
* that purpose. Its fields are as follows:
*
- * magic: Unsigned 32 bit integer always set to
- * H5AC__H5AC_SLIST_ENTRY_T_MAGIC. This field is used to
+ * magic: Unsigned 32 bit integer always set to
+ * H5AC__H5AC_SLIST_ENTRY_T_MAGIC. This field is used to
* validate pointers to instances of H5AC_slist_entry_t.
- *
+ *
* addr: file offset of a metadata entry. Entries are added to this
* list (if they aren't there already) when they are marked
- * dirty in an unprotect, inserted, or renamed. They are
+ * dirty in an unprotect, inserted, or renamed. They are
* removed when they appear in a clean entries broadcast.
*
****************************************************************************/
@@ -455,9 +455,9 @@ H5AC_term_interface(void)
* through the function.
* JRM - 4/7/05
*
- * Added code allocating and initializing the auxilary
+ * Added code allocating and initializing the auxilary
* structure (an instance of H5AC_aux_t), and linking it
- * to the instance of H5C_t created by H5C_create(). At
+ * to the instance of H5C_t created by H5C_create(). At
* present, the auxilary structure is only used in PHDF5.
*
* JRM - 6/28/05
@@ -465,7 +465,7 @@ H5AC_term_interface(void)
* Added code to set the prefix if required.
*
* JRM - 1/20/06
- *
+ *
* Added code to initialize the new write_done field.
*
* JRM - 5/11/06
@@ -530,17 +530,17 @@ H5AC_create(const H5F_t *f,
if ( (mpi_rank = H5F_mpi_get_rank(f)) < 0 ) {
- HGOTO_ERROR(H5E_VFL, H5E_CANTGET, FAIL, "can't get mpi rank")
+ HGOTO_ERROR(H5E_VFL, H5E_CANTGET, FAIL, "can't get mpi rank")
}
if ( (mpi_size = H5F_mpi_get_size(f)) < 0 ) {
- HGOTO_ERROR(H5E_VFL, H5E_CANTGET, FAIL, "can't get mpi size")
+ HGOTO_ERROR(H5E_VFL, H5E_CANTGET, FAIL, "can't get mpi size")
}
- /* There is no point in setting up the auxilary structure if size
- * is less than or equal to 1, as there will never be any processes
- * to broadcast the clean lists to.
+ /* There is no point in setting up the auxilary structure if size
+ * is less than or equal to 1, as there will never be any processes
+ * to broadcast the clean lists to.
*/
if ( mpi_size > 1 ) {
@@ -550,13 +550,13 @@ H5AC_create(const H5F_t *f,
"Can't allocate H5AC auxilary structure.")
} else {
-
+
aux_ptr->magic = H5AC__H5AC_AUX_T_MAGIC;
aux_ptr->mpi_comm = mpi_comm;
aux_ptr->mpi_rank = mpi_rank;
aux_ptr->mpi_size = mpi_size;
aux_ptr->write_permitted = FALSE;
- aux_ptr->dirty_bytes_threshold =
+ aux_ptr->dirty_bytes_threshold =
H5AC__DEFAULT_DIRTY_BYTES_THRESHOLD;
aux_ptr->dirty_bytes = 0;
#if H5AC_DEBUG_DIRTY_BYTES_CREATION
@@ -578,28 +578,28 @@ H5AC_create(const H5F_t *f,
}
if ( mpi_rank == 0 ) {
-
- aux_ptr->d_slist_ptr =
+
+ aux_ptr->d_slist_ptr =
H5SL_create(H5SL_TYPE_HADDR,0.5,(size_t)16);
if ( aux_ptr->d_slist_ptr == NULL ) {
- HGOTO_ERROR(H5E_CACHE, H5E_CANTCREATE, FAIL,
+ HGOTO_ERROR(H5E_CACHE, H5E_CANTCREATE, FAIL,
"can't create dirtied entry list.")
}
-
- aux_ptr->c_slist_ptr =
+
+ aux_ptr->c_slist_ptr =
H5SL_create(H5SL_TYPE_HADDR,0.5,(size_t)16);
if ( aux_ptr->c_slist_ptr == NULL ) {
- HGOTO_ERROR(H5E_CACHE, H5E_CANTCREATE, FAIL,
+ HGOTO_ERROR(H5E_CACHE, H5E_CANTCREATE, FAIL,
"can't create cleaned entry list.")
}
}
}
- if ( aux_ptr != NULL ) {
+ if ( aux_ptr != NULL ) {
if ( aux_ptr->mpi_rank == 0 ) {
@@ -661,7 +661,7 @@ H5AC_create(const H5F_t *f,
HGOTO_ERROR(H5E_RESOURCE, H5E_NOSPACE, FAIL, "memory allocation failed")
- }
+ }
#ifdef H5_HAVE_PARALLEL
else if ( aux_ptr != NULL ) {
@@ -739,10 +739,10 @@ done:
*
* JRM - 6/7/04
*
- * Added code to free the auxiliary structure and its
+ * Added code to free the auxiliary structure and its
* associated slist if present.
* JRM - 6/28/05
- *
+ *
*-------------------------------------------------------------------------
*/
herr_t
@@ -857,8 +857,8 @@ done:
*
* Complete re-write. See above for details. -- JRM 5/11/04
*
- * Abstracted the guts of the function to H5C_flush_cache()
- * in H5C.c, and then re-wrote the function as a wrapper for
+ * Abstracted the guts of the function to H5C_flush_cache()
+ * in H5C.c, and then re-wrote the function as a wrapper for
* H5C_flush_cache().
*
* JRM - 6/7/04
@@ -895,9 +895,9 @@ H5AC_flush(H5F_t *f, hid_t dxpl_id, unsigned flags)
if ( aux_ptr != NULL ) {
#if H5AC_DEBUG_DIRTY_BYTES_CREATION
- HDfprintf(stdout,
+ HDfprintf(stdout,
"%d::H5AC_flush: (u/uu/i/iu/r/ru) = %d/%d/%d/%d/%d/%d\n",
- (int)(aux_ptr->mpi_rank),
+ (int)(aux_ptr->mpi_rank),
(int)(aux_ptr->unprotect_dirty_bytes),
(int)(aux_ptr->unprotect_dirty_bytes_updates),
(int)(aux_ptr->insert_dirty_bytes),
@@ -907,7 +907,7 @@ H5AC_flush(H5F_t *f, hid_t dxpl_id, unsigned flags)
#endif /* H5AC_DEBUG_DIRTY_BYTES_CREATION */
/* to prevent "messages from the future" we must synchronize all
- * processes before we start the flush. Hence the following
+ * processes before we start the flush. Hence the following
* barrier.
*/
if ( MPI_SUCCESS != (mpi_code = MPI_Barrier(aux_ptr->mpi_comm)) ) {
@@ -959,10 +959,10 @@ H5AC_flush(H5F_t *f, hid_t dxpl_id, unsigned flags)
} /* end if ( aux_ptr != NULL ) */
#endif /* H5_HAVE_PARALLEL */
- status = H5C_flush_cache(f,
- dxpl_id,
- H5AC_noblock_dxpl_id,
- f->shared->cache,
+ status = H5C_flush_cache(f,
+ dxpl_id,
+ H5AC_noblock_dxpl_id,
+ f->shared->cache,
flags);
if ( status < 0 ) {
@@ -997,7 +997,7 @@ done:
* 4/27/06
*
* Modifications:
- *
+ *
* None.
*
*-------------------------------------------------------------------------
@@ -1020,7 +1020,7 @@ H5AC_get_entry_status(H5F_t * f,
FUNC_ENTER_NOAPI(H5AC_get_entry_status, FAIL)
- if ( ( cache_ptr == NULL ) ||
+ if ( ( cache_ptr == NULL ) ||
( cache_ptr->magic != H5C__H5C_T_MAGIC ) ||
( ! H5F_addr_defined(addr) ) ||
( status_ptr == NULL ) ) {
@@ -1041,16 +1041,16 @@ H5AC_get_entry_status(H5F_t * f,
status |= H5AC_ES__IN_CACHE;
- if ( is_dirty )
+ if ( is_dirty )
status |= H5AC_ES__IS_DIRTY;
- if ( is_protected )
+ if ( is_protected )
status |= H5AC_ES__IS_PROTECTED;
- if ( is_pinned )
+ if ( is_pinned )
status |= H5AC_ES__IS_PINNED;
}
-
+
*status_ptr = status;
done:
@@ -1210,7 +1210,7 @@ done:
* Purpose: Mark a pinned entry as dirty. The target entry MUST be
* be pinned, and MUST be unprotected.
*
- * If the entry has changed size, the function updates
+ * If the entry has changed size, the function updates
* data structures for the size change.
*
* Return: Non-negative on success/Negative on failure
@@ -1277,8 +1277,8 @@ H5AC_mark_pinned_entry_dirty(H5F_t * f,
}
#endif /* H5_HAVE_PARALLEL */
- result = H5C_mark_pinned_entry_dirty(cache_ptr,
- thing,
+ result = H5C_mark_pinned_entry_dirty(cache_ptr,
+ thing,
size_changed,
new_size);
if ( result < 0 ) {
@@ -1298,7 +1298,7 @@ done:
/*-------------------------------------------------------------------------
* Function: H5AC_mark_pinned_or_protected_entry_dirty
*
- * Purpose: Mark a pinned or protected entry as dirty. The target
+ * Purpose: Mark a pinned or protected entry as dirty. The target
* entry MUST be either pinned, protected, or both.
*
* Unlike H5AC_mark_pinned_entry_dirty(), this function does
@@ -1406,7 +1406,7 @@ done:
* the PHDF5 case. It should have no effect on either the
* serial or FPHSD5 cases.
*
- * Note that this code presumes that the renamed entry will
+ * Note that this code presumes that the renamed entry will
* be present in all caches -- which it must be at present.
* To maintain this invarient, only rename entries immediately
* after you unprotect them.
@@ -1461,7 +1461,7 @@ H5AC_rename(H5F_t *f, const H5AC_class_t *type, haddr_t old_addr, haddr_t new_ad
if ( ( aux_ptr != NULL ) &&
( aux_ptr->dirty_bytes >= aux_ptr->dirty_bytes_threshold ) ) {
- result = H5AC_propagate_flushed_and_still_clean_entries_list(f,
+ result = H5AC_propagate_flushed_and_still_clean_entries_list(f,
H5AC_noblock_dxpl_id,
f->shared->cache,
TRUE);
@@ -1525,7 +1525,7 @@ done:
/*-------------------------------------------------------------------------
* Function: H5AC_protect
*
- * Purpose: If the target entry is not in the cache, load it. If
+ * Purpose: If the target entry is not in the cache, load it. If
* necessary, attempt to evict one or more entries to keep
* the cache within its maximum size.
*
@@ -1533,8 +1533,8 @@ done:
* to the caller. The caller must call H5AC_unprotect() when
* finished with the entry.
*
- * While it is protected, the entry may not be either evicted
- * or flushed -- nor may it be accessed by another call to
+ * While it is protected, the entry may not be either evicted
+ * or flushed -- nor may it be accessed by another call to
* H5AC_protect. Any attempt to do so will result in a failure.
*
* This comment is a re-write of the original Purpose: section.
@@ -1575,8 +1575,8 @@ done:
* Purpose section above.
*
* JRM - 6/7/04
- * Abstracted the guts of the function to H5C_protect()
- * in H5C.c, and then re-wrote the function as a wrapper for
+ * Abstracted the guts of the function to H5C_protect()
+ * in H5C.c, and then re-wrote the function as a wrapper for
* H5C_protect().
*
*-------------------------------------------------------------------------
@@ -1630,7 +1630,7 @@ done:
/*-------------------------------------------------------------------------
* Function: H5AC_unpin_entry()
*
- * Purpose: Unpin a cache entry. The entry must be unprotected at
+ * Purpose: Unpin a cache entry. The entry must be unprotected at
* the time of call, and must be pinned.
*
* Return: Non-negative on success/Negative on failure
@@ -1741,18 +1741,18 @@ done:
*
* JRM - 7/5/05
* Added code to track dirty byte generation, and to trigger
- * clean entry list propagation when it exceeds a user
+ * clean entry list propagation when it exceeds a user
* specified threshold. Note that this code only applies in
* the PHDF5 case. It should have no effect on either the
* serial or FPHSD5 cases.
*
* JRM - 9/8/05
* Added code to track entry size changes. This is necessary
- * as it can effect dirty byte creation counts, thereby
+ * as it can effect dirty byte creation counts, thereby
* throwing the caches out of sync in the PHDF5 case.
*
* JRM - 5/16/06
- * Added code to use the new dirtied field in
+ * Added code to use the new dirtied field in
* H5C_cache_entry_t in the test to see if the entry has
* been dirtied.
*
@@ -1786,7 +1786,7 @@ H5AC_unprotect(H5F_t *f, hid_t dxpl_id, const H5AC_class_t *type, haddr_t addr,
dirtied = ( ( (flags & H5AC__DIRTIED_FLAG) == H5AC__DIRTIED_FLAG ) ||
( ((H5AC_info_t *)thing)->dirtied ) );
- if ( dirtied ) {
+ if ( dirtied ) {
if ( (type->size)(f, thing, &new_size) < 0 ) {
@@ -1805,7 +1805,7 @@ H5AC_unprotect(H5F_t *f, hid_t dxpl_id, const H5AC_class_t *type, haddr_t addr,
if ( ( dirtied ) && ( ((H5AC_info_t *)thing)->is_dirty == FALSE ) &&
( NULL != (aux_ptr = f->shared->cache->aux_ptr) ) ) {
- result = H5AC_log_dirtied_entry(f->shared->cache,
+ result = H5AC_log_dirtied_entry(f->shared->cache,
(H5AC_info_t *)thing,
addr,
size_changed,
@@ -1980,7 +1980,7 @@ done:
* Reworked for the addition of struct H5AC_cache_config_t.
*
* JRM - 10/25/05
- * Added support for the new dirty_bytes_threshold field of
+ * Added support for the new dirty_bytes_threshold field of
* both H5AC_cache_config_t and H5AC_aux_t.
*
*-------------------------------------------------------------------------
@@ -1996,21 +1996,21 @@ H5AC_get_cache_auto_resize_config(H5AC_t * cache_ptr,
FUNC_ENTER_NOAPI(H5AC_get_cache_auto_resize_config, FAIL)
- if ( ( cache_ptr == NULL )
+ if ( ( cache_ptr == NULL )
||
#ifdef H5_HAVE_PARALLEL
- ( ( cache_ptr->aux_ptr != NULL )
- &&
- ( ((H5AC_aux_t *)(cache_ptr->aux_ptr))->magic
- !=
- H5AC__H5AC_AUX_T_MAGIC
+ ( ( cache_ptr->aux_ptr != NULL )
+ &&
+ ( ((H5AC_aux_t *)(cache_ptr->aux_ptr))->magic
+ !=
+ H5AC__H5AC_AUX_T_MAGIC
)
- )
+ )
||
#endif /* H5_HAVE_PARALLEL */
- ( config_ptr == NULL )
+ ( config_ptr == NULL )
||
- ( config_ptr->version != H5AC__CURR_CACHE_CONFIG_VERSION )
+ ( config_ptr->version != H5AC__CURR_CACHE_CONFIG_VERSION )
)
{
HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, \
@@ -2060,7 +2060,7 @@ H5AC_get_cache_auto_resize_config(H5AC_t * cache_ptr,
#ifdef H5_HAVE_PARALLEL
if ( cache_ptr->aux_ptr != NULL ) {
- config_ptr->dirty_bytes_threshold =
+ config_ptr->dirty_bytes_threshold =
((H5AC_aux_t *)(cache_ptr->aux_ptr))->dirty_bytes_threshold;
} else {
@@ -2225,7 +2225,7 @@ done:
* Updated for the addition of H5AC_cache_config_t.
*
* John Mainzer -- 1025/05
- * Added support for the new dirty_bytes_threshold field of
+ * Added support for the new dirty_bytes_threshold field of
* both H5AC_cache_config_t and H5AC_aux_t.
*
*-------------------------------------------------------------------------
@@ -2244,14 +2244,14 @@ H5AC_set_cache_auto_resize_config(H5AC_t * cache_ptr,
if ( ( cache_ptr == NULL )
#ifdef H5_HAVE_PARALLEL
||
- ( ( cache_ptr->aux_ptr != NULL )
- &&
- (
- ((H5AC_aux_t *)(cache_ptr->aux_ptr))->magic
- !=
- H5AC__H5AC_AUX_T_MAGIC
+ ( ( cache_ptr->aux_ptr != NULL )
+ &&
+ (
+ ((H5AC_aux_t *)(cache_ptr->aux_ptr))->magic
+ !=
+ H5AC__H5AC_AUX_T_MAGIC
)
- )
+ )
#endif /* H5_HAVE_PARALLEL */
) {
@@ -2275,16 +2275,16 @@ H5AC_set_cache_auto_resize_config(H5AC_t * cache_ptr,
"config_ptr->rpt_fcn_enabled must be either TRUE or FALSE.")
}
- if (
- (
- config_ptr->dirty_bytes_threshold
- <
+ if (
+ (
+ config_ptr->dirty_bytes_threshold
+ <
H5AC__MIN_DIRTY_BYTES_THRESHOLD
)
||
- (
- config_ptr->dirty_bytes_threshold
- >
+ (
+ config_ptr->dirty_bytes_threshold
+ >
H5AC__MAX_DIRTY_BYTES_THRESHOLD
)
) {
@@ -2311,7 +2311,7 @@ H5AC_set_cache_auto_resize_config(H5AC_t * cache_ptr,
#ifdef H5_HAVE_PARALLEL
if ( cache_ptr->aux_ptr != NULL ) {
- ((H5AC_aux_t *)(cache_ptr->aux_ptr))->dirty_bytes_threshold =
+ ((H5AC_aux_t *)(cache_ptr->aux_ptr))->dirty_bytes_threshold =
config_ptr->dirty_bytes_threshold;
}
#endif /* H5_HAVE_PARALLEL */
@@ -2381,7 +2381,7 @@ H5AC_validate_config(H5AC_cache_config_t * config_ptr)
HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL,
"dirty_bytes_threshold too small.")
- } else
+ } else
if ( config_ptr->dirty_bytes_threshold > H5AC__MAX_DIRTY_BYTES_THRESHOLD ) {
HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL,
@@ -2423,7 +2423,7 @@ done:
* list, and also remove any matching entries from the dirtied
* slist.
*
- * This function must only be called by the process with
+ * This function must only be called by the process with
* MPI_rank 0.
*
* Return SUCCEED on success, and FAIL on failure.
@@ -2463,7 +2463,7 @@ H5AC_broadcast_clean_list(H5AC_t * cache_ptr)
HDassert( aux_ptr->magic == H5AC__H5AC_AUX_T_MAGIC );
HDassert( aux_ptr->mpi_rank == 0 );
HDassert( aux_ptr->c_slist_ptr != NULL );
- HDassert( H5SL_count(aux_ptr->c_slist_ptr) ==
+ HDassert( H5SL_count(aux_ptr->c_slist_ptr) ==
(size_t)(aux_ptr->c_slist_len) );
@@ -2479,7 +2479,7 @@ H5AC_broadcast_clean_list(H5AC_t * cache_ptr)
HMPI_GOTO_ERROR(FAIL, "MPI_Bcast failed 1", mpi_result)
- }
+ }
if ( num_entries > 0 )
{
@@ -2518,7 +2518,7 @@ H5AC_broadcast_clean_list(H5AC_t * cache_ptr)
i++;
/* now remove the entry from the cleaned entry list */
- if ( H5SL_remove(aux_ptr->c_slist_ptr, (void *)(&addr))
+ if ( H5SL_remove(aux_ptr->c_slist_ptr, (void *)(&addr))
!= slist_entry_ptr ) {
HGOTO_ERROR(H5E_CACHE, H5E_CANTDELETE, FAIL, \
@@ -2533,17 +2533,17 @@ H5AC_broadcast_clean_list(H5AC_t * cache_ptr)
HDassert( aux_ptr->c_slist_len >= 0 );
- /* and also remove the matching entry from the dirtied list
+ /* and also remove the matching entry from the dirtied list
* if it exists.
*/
- if ( (slist_entry_ptr = H5SL_search(aux_ptr->d_slist_ptr,
+ if ( (slist_entry_ptr = H5SL_search(aux_ptr->d_slist_ptr,
(void *)(&addr))) != NULL ) {
- HDassert( slist_entry_ptr->magic ==
+ HDassert( slist_entry_ptr->magic ==
H5AC__H5AC_SLIST_ENTRY_T_MAGIC );
HDassert( slist_entry_ptr->addr == addr );
- if ( H5SL_remove(aux_ptr->d_slist_ptr, (void *)(&addr))
+ if ( H5SL_remove(aux_ptr->d_slist_ptr, (void *)(&addr))
!= slist_entry_ptr ) {
HGOTO_ERROR(H5E_CACHE, H5E_CANTDELETE, FAIL, \
@@ -2562,15 +2562,15 @@ H5AC_broadcast_clean_list(H5AC_t * cache_ptr)
} /* while */
- /* Now broadcast the list of cleaned entries -- if there is one.
+ /* Now broadcast the list of cleaned entries -- if there is one.
*
* The peculiar structure of the following call to MPI_Bcast is
* due to MPI's (?) failure to believe in the MPI_Offset type.
- * Thus the element type is MPI_BYTE, with size equal to the
+ * Thus the element type is MPI_BYTE, with size equal to the
* buf_size computed above.
*/
- mpi_result = MPI_Bcast((void *)buf_ptr, (int)buf_size, MPI_BYTE, 0,
+ mpi_result = MPI_Bcast((void *)buf_ptr, (int)buf_size, MPI_BYTE, 0,
aux_ptr->mpi_comm);
if ( mpi_result != MPI_SUCCESS ) {
@@ -2612,11 +2612,11 @@ done:
* Modifications:
*
* John Mainzer, 9/23/05
- * Rewrote function to return the value of the
+ * Rewrote function to return the value of the
* write_permitted field in aux structure if the structure
- * exists and mpi_rank is 0.
+ * exists and mpi_rank is 0.
*
- * If the aux structure exists, but mpi_rank isn't 0, the
+ * If the aux structure exists, but mpi_rank isn't 0, the
* function now returns FALSE.
*
* In all other cases, the function returns TRUE.
@@ -2679,7 +2679,7 @@ done:
/*-------------------------------------------------------------------------
* Function: H5AC_ext_config_2_int_config()
*
- * Purpose: Utility function to translate an instance of
+ * Purpose: Utility function to translate an instance of
* H5AC_cache_config_t to an instance of H5C_auto_size_ctl_t.
*
* Places translation in *int_conf_ptr and returns SUCCEED
@@ -2808,14 +2808,14 @@ H5AC_log_deleted_entry(H5AC_t * cache_ptr,
HDassert( aux_ptr->c_slist_ptr != NULL );
/* if the entry appears in the dirtied entry slist, remove it. */
- if ( (slist_entry_ptr = H5SL_search(aux_ptr->d_slist_ptr,
+ if ( (slist_entry_ptr = H5SL_search(aux_ptr->d_slist_ptr,
(void *)(&addr))) != NULL ) {
- HDassert( slist_entry_ptr->magic ==
+ HDassert( slist_entry_ptr->magic ==
H5AC__H5AC_SLIST_ENTRY_T_MAGIC );
HDassert( slist_entry_ptr->addr == addr );
- if ( H5SL_remove(aux_ptr->d_slist_ptr, (void *)(&addr))
+ if ( H5SL_remove(aux_ptr->d_slist_ptr, (void *)(&addr))
!= slist_entry_ptr ) {
HGOTO_ERROR(H5E_CACHE, H5E_CANTDELETE, FAIL, \
@@ -2832,14 +2832,14 @@ H5AC_log_deleted_entry(H5AC_t * cache_ptr,
}
/* if the entry appears in the cleaned entry slist, remove it. */
- if ( (slist_entry_ptr = H5SL_search(aux_ptr->c_slist_ptr,
+ if ( (slist_entry_ptr = H5SL_search(aux_ptr->c_slist_ptr,
(void *)(&addr))) != NULL ) {
- HDassert( slist_entry_ptr->magic ==
+ HDassert( slist_entry_ptr->magic ==
H5AC__H5AC_SLIST_ENTRY_T_MAGIC );
HDassert( slist_entry_ptr->addr == addr );
- if ( H5SL_remove(aux_ptr->c_slist_ptr, (void *)(&addr))
+ if ( H5SL_remove(aux_ptr->c_slist_ptr, (void *)(&addr))
!= slist_entry_ptr ) {
HGOTO_ERROR(H5E_CACHE, H5E_CANTDELETE, FAIL, \
@@ -2876,7 +2876,7 @@ done:
* If mpi_rank is 0, we must first check to see if the entry
* appears in the dirty entries slist. If it is, do nothing.
* If it isn't, add the size to th dirty_bytes count, add the
- * entry to the dirty entries slist, and remove it from the
+ * entry to the dirty entries slist, and remove it from the
* cleaned list (if it is present there).
*
* Return SUCCEED on success, and FAIL on failure.
@@ -2965,14 +2965,14 @@ H5AC_log_dirtied_entry(H5AC_t * cache_ptr,
/* the entry is dirty. If it exists on the cleaned entries list,
* remove it.
*/
- if ( (slist_entry_ptr = H5SL_search(aux_ptr->c_slist_ptr,
+ if ( (slist_entry_ptr = H5SL_search(aux_ptr->c_slist_ptr,
(void *)(&addr))) != NULL ) {
- HDassert( slist_entry_ptr->magic ==
+ HDassert( slist_entry_ptr->magic ==
H5AC__H5AC_SLIST_ENTRY_T_MAGIC );
HDassert( slist_entry_ptr->addr == addr );
- if ( H5SL_remove(aux_ptr->c_slist_ptr, (void *)(&addr))
+ if ( H5SL_remove(aux_ptr->c_slist_ptr, (void *)(&addr))
!= slist_entry_ptr ) {
HGOTO_ERROR(H5E_CACHE, H5E_CANTDELETE, FAIL, \
@@ -3010,12 +3010,12 @@ done:
* Function: H5AC_log_flushed_entry()
*
* Purpose: Update the clean entry slist for the flush of an entry --
- * specifically, if the entry has been cleared, remove it
+ * specifically, if the entry has been cleared, remove it
* from both the cleaned and dirtied lists if it is present.
- * Otherwise, if the entry was dirty, insert the indicated
+ * Otherwise, if the entry was dirty, insert the indicated
* entry address in the clean slist if it isn't there already.
*
- * This function is only used in PHDF5, and should only
+ * This function is only used in PHDF5, and should only
* be called for the process with mpi rank 0.
*
* Return SUCCEED on success, and FAIL on failure.
@@ -3046,8 +3046,8 @@ H5AC_log_flushed_entry_dummy(H5C_t * cache_ptr,
aux_ptr = cache_ptr->aux_ptr;
if ( ( was_dirty ) && ( (flags & H5C__FLUSH_CLEAR_ONLY_FLAG) == 0 ) ) {
-
- HDfprintf(stdout,
+
+ HDfprintf(stdout,
"%d:H5AC_log_flushed_entry(): addr = %d, flags = %x, was_dirty = %d, type_id = %d\n",
(int)(aux_ptr->mpi_rank), (int)addr, flags, (int)was_dirty, type_id);
}
@@ -3091,13 +3091,13 @@ H5AC_log_flushed_entry(H5C_t * cache_ptr,
* cleaned list and the dirtied list.
*/
- if ( (slist_entry_ptr = H5SL_search(aux_ptr->c_slist_ptr,
+ if ( (slist_entry_ptr = H5SL_search(aux_ptr->c_slist_ptr,
(void *)(&addr))) != NULL ) {
HDassert( slist_entry_ptr->magic == H5AC__H5AC_SLIST_ENTRY_T_MAGIC);
HDassert( slist_entry_ptr->addr == addr );
- if ( H5SL_remove(aux_ptr->c_slist_ptr, (void *)(&addr))
+ if ( H5SL_remove(aux_ptr->c_slist_ptr, (void *)(&addr))
!= slist_entry_ptr ) {
HGOTO_ERROR(H5E_CACHE, H5E_CANTDELETE, FAIL, \
@@ -3113,13 +3113,13 @@ H5AC_log_flushed_entry(H5C_t * cache_ptr,
HDassert( aux_ptr->c_slist_len >= 0 );
}
- if ( (slist_entry_ptr = H5SL_search(aux_ptr->d_slist_ptr,
+ if ( (slist_entry_ptr = H5SL_search(aux_ptr->d_slist_ptr,
(void *)(&addr))) != NULL ) {
HDassert( slist_entry_ptr->magic == H5AC__H5AC_SLIST_ENTRY_T_MAGIC);
HDassert( slist_entry_ptr->addr == addr );
- if ( H5SL_remove(aux_ptr->d_slist_ptr, (void *)(&addr))
+ if ( H5SL_remove(aux_ptr->d_slist_ptr, (void *)(&addr))
!= slist_entry_ptr ) {
HGOTO_ERROR(H5E_CACHE, H5E_CANTDELETE, FAIL, \
@@ -3177,7 +3177,7 @@ done:
* If mpi_rank isnt 0, this simply means adding the size
* of the entry to the dirty_bytes count.
*
- * If mpi_rank is 0, we must also add the entry to the
+ * If mpi_rank is 0, we must also add the entry to the
* dirty entries slist.
*
* Return SUCCEED on success, and FAIL on failure.
@@ -3246,7 +3246,7 @@ H5AC_log_inserted_entry(H5F_t * f,
slist_entry_ptr->magic = H5AC__H5AC_SLIST_ENTRY_T_MAGIC;
slist_entry_ptr->addr = addr;
- if ( H5SL_insert(aux_ptr->d_slist_ptr, slist_entry_ptr,
+ if ( H5SL_insert(aux_ptr->d_slist_ptr, slist_entry_ptr,
&(slist_entry_ptr->addr)) < 0 ) {
HGOTO_ERROR(H5E_CACHE, H5E_CANTINSERT, FAIL, \
@@ -3266,7 +3266,7 @@ H5AC_log_inserted_entry(H5F_t * f,
HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, \
"Inserted entry in clean slist.")
}
- }
+ }
aux_ptr->dirty_bytes += size;
@@ -3292,14 +3292,14 @@ done:
* WARNING
*
* At present, the way that the rename call is used ensures
- * that the renamed entry is present in all caches by
+ * that the renamed entry is present in all caches by
* renaming in a collective operation and immediately after
* unprotecting the target entry.
*
* This function uses this invarient, and will cause arcane
* failures if it is not met. If maintaining this invarient
* becomes impossible, we will have to rework this function
- * extensively, and likely include a bit of IPC for
+ * extensively, and likely include a bit of IPC for
* synchronization. A better option might be to subsume
* rename in the unprotect operation.
*
@@ -3308,17 +3308,17 @@ done:
*
* For processes with mpi rank other 0, it simply checks to
* see if the entry was dirty prior to the rename, and adds
- * the entries size to the dirty bytes count.
+ * the entries size to the dirty bytes count.
*
* In the process with mpi rank 0, the function first checks
* to see if the entry was dirty prior to the rename. If it
* was, and if the entry doesn't appear in the dirtied list
- * under its old address, it adds the entry's size to the
+ * under its old address, it adds the entry's size to the
* dirty bytes count.
*
- * The rank 0 process then removes any references to the
- * entry under its old address from the cleands and dirtied
- * lists, and inserts an entry in the dirtied list under the
+ * The rank 0 process then removes any references to the
+ * entry under its old address from the cleands and dirtied
+ * lists, and inserts an entry in the dirtied list under the
* new address.
*
* Return SUCCEED on success, and FAIL on failure.
@@ -3373,7 +3373,7 @@ H5AC_log_renamed_entry(H5AC_t * cache_ptr,
HDassert( aux_ptr->c_slist_ptr != NULL );
/* if the entry appears in the cleaned entry slist, under its old
- * address, remove it.
+ * address, remove it.
*/
if ( (slist_entry_ptr = H5SL_search(aux_ptr->c_slist_ptr,
(void *)(&old_addr))) != NULL ) {
@@ -3422,9 +3422,9 @@ H5AC_log_renamed_entry(H5AC_t * cache_ptr,
HDassert( aux_ptr->d_slist_len >= 0 );
} else {
-
- /* otherwise, allocate a new entry that is ready
- * for insertion, and increment dirty_bytes.
+
+ /* otherwise, allocate a new entry that is ready
+ * for insertion, and increment dirty_bytes.
*
* Note that the fact that the entry wasn't in the dirtied
* list under its old address implies that it must have
@@ -3489,12 +3489,12 @@ done:
* Function: H5AC_propagate_flushed_and_still_clean_entries_list
*
* Purpose: In PHDF5, only the metadata cache with mpi rank 0 is allowed
- * to write to file. All other metadata caches on processes
+ * to write to file. All other metadata caches on processes
* with rank greater than 0 must retain dirty entries until
* they are notified that the entry is now clean.
*
* This function is the main routine for that proceedure.
- * It must be called simultaniously on all processes that
+ * It must be called simultaniously on all processes that
* have the relevant file open. To this end, there must
* be a barrier immediately prior to this call.
*
@@ -3502,21 +3502,21 @@ done:
*
* 1) Dirty byte creation exceeds some user specified value.
*
- * While metadata reads may occur independently, all
+ * While metadata reads may occur independently, all
* operations writing metadata must be collective. Thus
* all metadata caches see the same sequence of operations,
* and therefore the same dirty data creation.
*
* This fact is used to synchronize the caches for purposes
* of propagating the list of flushed and still clean
- * entries, by simply calling this function from all
+ * entries, by simply calling this function from all
* caches whenever some user specified threshold on dirty
* data is exceeded.
*
- * 2) Under direct user control -- this operation must be
+ * 2) Under direct user control -- this operation must be
* collective.
*
- * The operations to be managed by this function are as
+ * The operations to be managed by this function are as
* follows:
*
* For the process with mpi rank 0:
@@ -3525,10 +3525,10 @@ done:
* and then disable writes again.
*
* 2) Load the contents of the flushed and still clean entries
- * list (c_slist_ptr) into a buffer, and broadcast that
+ * list (c_slist_ptr) into a buffer, and broadcast that
* buffer to all the other caches.
*
- * 3) Clear the flushed and still clean entries list
+ * 3) Clear the flushed and still clean entries list
* (c_slist_ptr).
*
*
@@ -3542,7 +3542,7 @@ done:
* For all processes:
*
* 1) Reset the dirtied bytes count to 0.
- *
+ *
* Return: Success: non-negative
*
* Failure: negative
@@ -3560,8 +3560,8 @@ done:
#ifdef H5_HAVE_PARALLEL
herr_t
-H5AC_propagate_flushed_and_still_clean_entries_list(H5F_t * f,
- hid_t dxpl_id,
+H5AC_propagate_flushed_and_still_clean_entries_list(H5F_t * f,
+ hid_t dxpl_id,
H5AC_t * cache_ptr,
hbool_t do_barrier)
{
@@ -3581,10 +3581,10 @@ H5AC_propagate_flushed_and_still_clean_entries_list(H5F_t * f,
HDassert( aux_ptr->magic == H5AC__H5AC_AUX_T_MAGIC );
#if H5AC_DEBUG_DIRTY_BYTES_CREATION
- HDfprintf(stdout,
+ HDfprintf(stdout,
"%d:H5AC_propagate...:%d: (u/uu/i/iu/r/ru) = %d/%d/%d/%d/%d/%d\n",
- (int)(aux_ptr->mpi_rank),
- (int)(aux_ptr->dirty_bytes_propagations),
+ (int)(aux_ptr->mpi_rank),
+ (int)(aux_ptr->dirty_bytes_propagations),
(int)(aux_ptr->unprotect_dirty_bytes),
(int)(aux_ptr->unprotect_dirty_bytes_updates),
(int)(aux_ptr->insert_dirty_bytes),
@@ -3610,7 +3610,7 @@ H5AC_propagate_flushed_and_still_clean_entries_list(H5F_t * f,
aux_ptr->write_permitted = TRUE;
- result = H5C_flush_to_min_clean(f, dxpl_id, H5AC_noblock_dxpl_id,
+ result = H5C_flush_to_min_clean(f, dxpl_id, H5AC_noblock_dxpl_id,
cache_ptr);
aux_ptr->write_permitted = FALSE;
@@ -3636,7 +3636,7 @@ H5AC_propagate_flushed_and_still_clean_entries_list(H5F_t * f,
} else {
- if ( H5AC_receive_and_apply_clean_list(f, dxpl_id,
+ if ( H5AC_receive_and_apply_clean_list(f, dxpl_id,
H5AC_noblock_dxpl_id,
cache_ptr) < 0 ) {
@@ -3671,7 +3671,7 @@ done:
* Purpose: Receive the list of cleaned entries from process 0,
* and mark the specified entries as clean.
*
- * This function must only be called by the process with
+ * This function must only be called by the process with
* MPI_rank greater than 0.
*
* Return SUCCEED on success, and FAIL on failure.
@@ -3737,7 +3737,7 @@ H5AC_receive_and_apply_clean_list(H5F_t * f,
"memory allocation failed for receive buffer")
}
- haddr_buf_ptr = (haddr_t *)H5MM_malloc(sizeof(haddr_t) *
+ haddr_buf_ptr = (haddr_t *)H5MM_malloc(sizeof(haddr_t) *
(size_t)num_entries);
if ( haddr_buf_ptr == NULL ) {
@@ -3747,15 +3747,15 @@ H5AC_receive_and_apply_clean_list(H5F_t * f,
}
- /* Now receive the list of cleaned entries
+ /* Now receive the list of cleaned entries
*
* The peculiar structure of the following call to MPI_Bcast is
* due to MPI's (?) failure to believe in the MPI_Offset type.
- * Thus the element type is MPI_BYTE, with size equal to the
+ * Thus the element type is MPI_BYTE, with size equal to the
* buf_size computed above.
*/
- mpi_result = MPI_Bcast((void *)MPI_Offset_buf_ptr, (int)buf_size,
+ mpi_result = MPI_Bcast((void *)MPI_Offset_buf_ptr, (int)buf_size,
MPI_BYTE, 0, aux_ptr->mpi_comm);
if ( mpi_result != MPI_SUCCESS ) {
@@ -3795,7 +3795,7 @@ done:
if ( MPI_Offset_buf_ptr != NULL ) {
- MPI_Offset_buf_ptr =
+ MPI_Offset_buf_ptr =
(MPI_Offset *)H5MM_xfree((void *)MPI_Offset_buf_ptr);
}
diff --git a/src/H5ACpkg.h b/src/H5ACpkg.h
index e31f245..fc51ef0 100644
--- a/src/H5ACpkg.h
+++ b/src/H5ACpkg.h
@@ -21,7 +21,7 @@
* Source files outside the H5AC package should include
* H5ACprivate.h instead.
*
- * The one exception to this rule is testpar/t_cache.c. The
+ * The one exception to this rule is testpar/t_cache.c. The
* test code is easier to write if it can look at H5AC_aux_t.
* Indeed, this is the main reason why this file was created.
*/
@@ -51,9 +51,9 @@
#define H5AC_DEBUG_DIRTY_BYTES_CREATION 0
/*-------------------------------------------------------------------------
- * It is a bit difficult to set ranges of allowable values on the
- * dirty_bytes_threshold field of H5AC_aux_t. The following are
- * probably broader than they should be.
+ * It is a bit difficult to set ranges of allowable values on the
+ * dirty_bytes_threshold field of H5AC_aux_t. The following are
+ * probably broader than they should be.
*-------------------------------------------------------------------------
*/
@@ -71,71 +71,71 @@
* are some features of the metadata cache that are specific to it, and which
* therefore do not belong in the more generic H5C cache code.
*
- * In particular, there is the matter of synchronizing writes from the
+ * In particular, there is the matter of synchronizing writes from the
* metadata cache to disk in the PHDF5 case.
*
- * Prior to this update, the presumption was that all metadata caches would
- * write the same data at the same time since all operations modifying
- * metadata must be performed collectively. Given this assumption, it was
- * safe to allow only the writes from process 0 to actually make it to disk,
+ * Prior to this update, the presumption was that all metadata caches would
+ * write the same data at the same time since all operations modifying
+ * metadata must be performed collectively. Given this assumption, it was
+ * safe to allow only the writes from process 0 to actually make it to disk,
* while metadata writes from all other processes were discarded.
*
- * Unfortunately, this presumption is in error as operations that read
- * metadata need not be collective, but can change the location of dirty
- * entries in the metadata cache LRU lists. This can result in the same
- * metadata write operation triggering writes from the metadata caches on
- * some processes, but not all (causing a hang), or in different sets of
- * entries being written from different caches (potentially resulting in
+ * Unfortunately, this presumption is in error as operations that read
+ * metadata need not be collective, but can change the location of dirty
+ * entries in the metadata cache LRU lists. This can result in the same
+ * metadata write operation triggering writes from the metadata caches on
+ * some processes, but not all (causing a hang), or in different sets of
+ * entries being written from different caches (potentially resulting in
* metadata corruption in the file).
*
* To deal with this issue, I decided to apply a paradigm shift to the way
* metadata is written to disk.
*
- * With this set of changes, only the metadata cache on process 0 is able
- * to write metadata to disk, although metadata caches on all other
+ * With this set of changes, only the metadata cache on process 0 is able
+ * to write metadata to disk, although metadata caches on all other
* processes can read metadata from disk as before.
*
* To keep all the other caches from getting plugged up with dirty metadata,
* process 0 periodically broadcasts a list of entries that it has flushed
* since that last notice, and which are currently clean. The other caches
- * mark these entries as clean as well, which allows them to evict the
+ * mark these entries as clean as well, which allows them to evict the
* entries as needed.
*
* One obvious problem in this approach is synchronizing the broadcasts
- * and receptions, as different caches may see different amounts of
- * activity.
+ * and receptions, as different caches may see different amounts of
+ * activity.
*
- * The current solution is for the caches to track the number of bytes
- * of newly generated dirty metadata, and to broadcast and receive
+ * The current solution is for the caches to track the number of bytes
+ * of newly generated dirty metadata, and to broadcast and receive
* whenever this value exceeds some user specified threshold.
*
* Maintaining this count is easy for all processes not on process 0 --
- * all that is necessary is to add the size of the entry to the total
+ * all that is necessary is to add the size of the entry to the total
* whenever there is an insertion, a rename of a previously clean entry,
* or whever a previously clean entry is marked dirty in an unprotect.
*
* On process 0, we have to be careful not to count dirty bytes twice.
- * If an entry is marked dirty, flushed, and marked dirty again, all
- * within a single reporting period, it only th first marking should
- * be added to the dirty bytes generated tally, as that is all that
+ * If an entry is marked dirty, flushed, and marked dirty again, all
+ * within a single reporting period, it only th first marking should
+ * be added to the dirty bytes generated tally, as that is all that
* the other processes will see.
*
* At present, this structure exists to maintain the fields needed to
* implement the above scheme, and thus is only used in the parallel
* case. However, other uses may arise in the future.
*
- * Instance of this structure are associated with metadata caches via
- * the aux_ptr field of H5C_t (see H5Cpkg.h). The H5AC code is
+ * Instance of this structure are associated with metadata caches via
+ * the aux_ptr field of H5C_t (see H5Cpkg.h). The H5AC code is
* responsible for allocating, maintaining, and discarding instances
- * of H5AC_aux_t.
+ * of H5AC_aux_t.
*
* The remainder of this header comments documents the individual fields
* of the structure.
*
* JRM - 6/27/05
*
- * magic: Unsigned 32 bit integer always set to
- * H5AC__H5AC_AUX_T_MAGIC. This field is used to validate
+ * magic: Unsigned 32 bit integer always set to
+ * H5AC__H5AC_AUX_T_MAGIC. This field is used to validate
* pointers to instances of H5AC_aux_t.
*
* mpi_comm: MPI communicator associated with the file for which the
@@ -146,14 +146,14 @@
* mpi_size: Number of processes in mpi_comm.
*
* write_permitted: Boolean flag used to control whether the cache
- * is permitted to write to file.
+ * is permitted to write to file.
*
- * dirty_bytes_threshold: Integer field containing the dirty bytes
- * generation threashold. Whenever dirty byte creation
- * exceeds this value, the metadata cache on process 0
+ * dirty_bytes_threshold: Integer field containing the dirty bytes
+ * generation threashold. Whenever dirty byte creation
+ * exceeds this value, the metadata cache on process 0
* broadcasts a list of the entries it has flushed since
* the last broadcast (or since the beginning of execution)
- * and which are currently clean (if they are still in the
+ * and which are currently clean (if they are still in the
* cache)
*
* Similarly, metadata caches on processes other than process
@@ -161,16 +161,16 @@
* the threshold is exceeded.
*
* dirty_bytes: Integer field containing the number of bytes of dirty
- * metadata generated since the beginning of the computation,
- * or (more typically) since the last clean entries list
+ * metadata generated since the beginning of the computation,
+ * or (more typically) since the last clean entries list
* broadcast. This field is reset to zero after each such
* broadcast.
*
- * dirty_bytes_propagations: This field only exists when the
+ * dirty_bytes_propagations: This field only exists when the
* H5AC_DEBUG_DIRTY_BYTES_CREATION #define is TRUE.
*
* It is used to track the number of times the cleaned list
- * has been propagated from process 0 to the other
+ * has been propagated from process 0 to the other
* processes.
*
* unprotect_dirty_bytes: This field only exists when the
@@ -184,7 +184,7 @@
* H5AC_DEBUG_DIRTY_BYTES_CREATION #define is TRUE.
*
* It is used to track the number of times dirty bytes have
- * been created via unprotect operations since the last time
+ * been created via unprotect operations since the last time
* the cleaned list was propagated.
*
* insert_dirty_bytes: This field only exists when the
@@ -198,7 +198,7 @@
* H5AC_DEBUG_DIRTY_BYTES_CREATION #define is TRUE.
*
* It is used to track the number of times dirty bytes have
- * been created via insert operations since the last time
+ * been created via insert operations since the last time
* the cleaned list was propagated.
*
* rename_dirty_bytes: This field only exists when the
@@ -212,7 +212,7 @@
* H5AC_DEBUG_DIRTY_BYTES_CREATION #define is TRUE.
*
* It is used to track the number of times dirty bytes have
- * been created via rename operations since the last time
+ * been created via rename operations since the last time
* the cleaned list was propagated.
*
* d_slist_ptr: Pointer to an instance of H5SL_t used to maintain a list
@@ -231,36 +231,36 @@
* 2) a previously clean entry is renamed, and it does not
* already appear in the dirty entry list, or
*
- * 3) a previously clean entry is unprotected with the
- * dirtied flag set and the entry does not already appear
+ * 3) a previously clean entry is unprotected with the
+ * dirtied flag set and the entry does not already appear
* in the dirty entry list.
*
* Entries are added to the dirty entry list whever they cause
- * the dirty bytes count to be increased. They are removed
+ * the dirty bytes count to be increased. They are removed
* when they appear in a clean entries broadcast. Note that
* renames must be reflected in the dirty entry list.
*
- * To reitterate, this field is only used on process 0 -- it
+ * To reitterate, this field is only used on process 0 -- it
* should be NULL on all other processes.
*
- * d_slist_len: Integer field containing the number of entries in the
- * dirty entry list. This field should always contain the
+ * d_slist_len: Integer field containing the number of entries in the
+ * dirty entry list. This field should always contain the
* value 0 on all processes other than process 0. It exists
* primarily for sanity checking.
*
- * c_slist_ptr: Pointer to an instance of H5SL_t used to maintain a list
+ * c_slist_ptr: Pointer to an instance of H5SL_t used to maintain a list
* of entries that were dirty, have been flushed
* to disk since the last clean entries broadcast, and are
* still clean. Since only process 0 can write to disk, this
* list only exists on process 0.
*
* In essence, this slist is used to assemble the contents of
- * the next clean entries broadcast. The list emptied after
+ * the next clean entries broadcast. The list emptied after
* each broadcast.
- *
+ *
* c_slist_len: Integer field containing the number of entries in the clean
- * entries list (*c_slist_ptr). This field should always
- * contain the value 0 on all processes other than process 0.
+ * entries list (*c_slist_ptr). This field should always
+ * contain the value 0 on all processes other than process 0.
* It exists primarily for sanity checking.
*
* write_done: In the parallel test bed, it is necessary to ensure that
@@ -297,7 +297,7 @@ typedef struct H5AC_aux_t
int32_t dirty_bytes;
-#if H5AC_DEBUG_DIRTY_BYTES_CREATION
+#if H5AC_DEBUG_DIRTY_BYTES_CREATION
int32_t dirty_bytes_propagations;
diff --git a/src/H5ACprivate.h b/src/H5ACprivate.h
index 6dcd88c..c3433be 100644
--- a/src/H5ACprivate.h
+++ b/src/H5ACprivate.h
@@ -229,7 +229,7 @@ extern hid_t H5AC_ind_dxpl_id;
#define H5AC__FLUSH_MARKED_ENTRIES_FLAG H5C__FLUSH_MARKED_ENTRIES_FLAG
-/* #defines of flags used to report entry status in the
+/* #defines of flags used to report entry status in the
* H5AC_get_entry_status() call.
*/
@@ -261,7 +261,7 @@ H5_DLL herr_t H5AC_mark_pinned_entry_dirty(H5F_t * f,
void * thing,
hbool_t size_changed,
size_t new_size);
-H5_DLL herr_t H5AC_mark_pinned_or_protected_entry_dirty(H5F_t * f,
+H5_DLL herr_t H5AC_mark_pinned_or_protected_entry_dirty(H5F_t * f,
void * thing);
H5_DLL herr_t H5AC_rename(H5F_t *f, const H5AC_class_t *type,
haddr_t old_addr, haddr_t new_addr);
diff --git a/src/H5ACpublic.h b/src/H5ACpublic.h
index 5db8c5a..81d3319 100644
--- a/src/H5ACpublic.h
+++ b/src/H5ACpublic.h
@@ -40,16 +40,16 @@ extern "C" {
* structure H5AC_cache_config_t
*
* H5AC_cache_config_t is a public structure intended for use in public APIs.
- * At least in its initial incarnation, it is basicaly a copy of struct
- * H5C_auto_size_ctl_t, minus the report_fcn field, and plus the
- * dirty_bytes_threshold field.
+ * At least in its initial incarnation, it is basicaly a copy of struct
+ * H5C_auto_size_ctl_t, minus the report_fcn field, and plus the
+ * dirty_bytes_threshold field.
*
- * The report_fcn field is omitted, as including it would require us to
+ * The report_fcn field is omitted, as including it would require us to
* make H5C_t structure public.
*
* The dirty_bytes_threshold field does not appear in H5C_auto_size_ctl_t,
* as synchronization between caches on different processes is handled at
- * the H5AC level, not at the level of H5C. Note however that there is
+ * the H5AC level, not at the level of H5C. Note however that there is
* considerable interaction between this value and the other fields in this
* structure.
*
@@ -235,31 +235,31 @@ extern "C" {
* The value of this field must be in the range [0.0, 1.0]. I would
* expect typical values to be in the range of 0.01 to 0.1.
*
- *
+ *
* Parallel Configuration Fields:
*
* In PHDF5, all operations that modify metadata must be executed collectively.
- * We used to think that this was enough to ensure consistency across the
+ * We used to think that this was enough to ensure consistency across the
* metadata caches, but since we allow processes to read metadata individually,
- * the order of dirty entries in the LRU list can vary across processes,
+ * the order of dirty entries in the LRU list can vary across processes,
* which can result in inconsistencies between the caches.
*
- * To prevent this, only the metadata cache on process 0 is allowed to write
+ * To prevent this, only the metadata cache on process 0 is allowed to write
* to file, and then only after synchronizing with the other caches. After
* it writes entries to file, it sends the base addresses of the now clean
* entries to the other caches, so they can mark these entries clean as well.
*
- * The different caches know when to synchronize caches by counting the
+ * The different caches know when to synchronize caches by counting the
* number of bytes of dirty metadata created by the collective operations
- * modifying metadata. Whenever this count exceeds a user specified
- * threshold (see below), process 0 flushes down to its minimum clean size,
+ * modifying metadata. Whenever this count exceeds a user specified
+ * threshold (see below), process 0 flushes down to its minimum clean size,
* and then sends the list of newly cleaned entries to the other caches.
*
- * dirty_bytes_threshold: Threshold of dirty byte creation used to
- * synchronize updates between caches. (See above for outline and
+ * dirty_bytes_threshold: Threshold of dirty byte creation used to
+ * synchronize updates between caches. (See above for outline and
* motivation.)
*
- * This value MUST be consistant across all processes accessing the
+ * This value MUST be consistant across all processes accessing the
* file. This field is ignored unless HDF5 has been compiled for
* parallel.
*
diff --git a/src/H5B2private.h b/src/H5B2private.h
index 537921f..6f90ef6 100644
--- a/src/H5B2private.h
+++ b/src/H5B2private.h
@@ -98,7 +98,7 @@ typedef struct H5B2_class_t {
/*****************************/
/* Library-private Variables */
/*****************************/
-
+
/***************************************/
/* Library-private Function Prototypes */
/***************************************/
diff --git a/src/H5Bprivate.h b/src/H5Bprivate.h
index 246d0c5..c94d1a6 100644
--- a/src/H5Bprivate.h
+++ b/src/H5Bprivate.h
@@ -134,7 +134,7 @@ typedef struct H5B_class_t {
/*****************************/
/* Library-private Variables */
/*****************************/
-
+
/* Declare a free list to manage the H5B_shared_t struct */
H5FL_EXTERN(H5B_shared_t);
diff --git a/src/H5C.c b/src/H5C.c
index 15fc671..dd0d56d 100644
--- a/src/H5C.c
+++ b/src/H5C.c
@@ -201,11 +201,11 @@
* JRM - 1/10/05
*
* - Added the H5C__DLL_UPDATE_FOR_SIZE_CHANGE macro and the associated
- * sanity checking macros. These macro are used to update the size of
+ * sanity checking macros. These macro are used to update the size of
* a DLL when one of its entries changes size.
*
* JRM - 9/8/05
- *
+ *
****************************************************************************/
#if H5C_DO_SANITY_CHECKS
@@ -294,7 +294,7 @@ if ( ( (new_size) > (dll_size) ) || \
#define H5C__DLL_PRE_REMOVE_SC(entry_ptr, head_ptr, tail_ptr, len, Size, fv)
#define H5C__DLL_SC(head_ptr, tail_ptr, len, Size, fv)
#define H5C__DLL_PRE_INSERT_SC(entry_ptr, head_ptr, tail_ptr, len, Size, fv)
-#define H5C__DLL_PRE_SIZE_UPDATE_SC(dll_len, dll_size, old_size, new_size)
+#define H5C__DLL_PRE_SIZE_UPDATE_SC(dll_len, dll_size, old_size, new_size)
#define H5C__DLL_POST_SIZE_UPDATE_SC(dll_len, dll_size, old_size, new_size)
#endif /* H5C_DO_SANITY_CHECKS */
@@ -1174,9 +1174,9 @@ if ( ( (cache_ptr) == NULL ) || \
* Macro: H5C__FAKE_RP_FOR_MOST_RECENT_ACCESS
*
* Purpose: For efficiency, we sometimes change the order of flushes --
- * but doing so can confuse the replacement policy. This
- * macro exists to allow us to specify an entry as the
- * most recently touched so we can repair any such
+ * but doing so can confuse the replacement policy. This
+ * macro exists to allow us to specify an entry as the
+ * most recently touched so we can repair any such
* confusion.
*
* At present, we only support the modified LRU policy, so
@@ -1192,7 +1192,7 @@ if ( ( (cache_ptr) == NULL ) || \
*
* JRM -- 3/20/06
* Modified macro to ignore pinned entries. Pinned entries
- * do not appear in the data structures maintained by the
+ * do not appear in the data structures maintained by the
* replacement policy code, and thus this macro has nothing
* to do if called for such an entry.
*
@@ -1831,7 +1831,7 @@ if ( ( (cache_ptr) == NULL ) || \
* JRM - 3/17/06
* Modified macro to do nothing if the entry is pinned.
* In this case, the entry is on the pinned entry list, not
- * in the replacement policy data structures, so there is
+ * in the replacement policy data structures, so there is
* nothing to be done.
*
*-------------------------------------------------------------------------
@@ -1947,7 +1947,7 @@ if ( ( (cache_ptr) == NULL ) || \
* unpin of the specified cache entry.
*
* To do this, unlink the specified entry from the protected
- * entry list, and re-insert it in the data structures used
+ * entry list, and re-insert it in the data structures used
* by the current replacement policy.
*
* At present, we only support the modified LRU policy, so
@@ -2271,7 +2271,7 @@ static herr_t H5C_make_space_in_cache(H5F_t * f,
hbool_t * first_flush_ptr);
#if H5C_DO_EXTREME_SANITY_CHECKS
static herr_t H5C_validate_lru_list(H5C_t * cache_ptr);
-static herr_t H5C_verify_not_in_index(H5C_t * cache_ptr,
+static herr_t H5C_verify_not_in_index(H5C_t * cache_ptr,
H5C_cache_entry_t * entry_ptr);
#endif /* H5C_DO_EXTREME_SANITY_CHECKS */
@@ -2444,7 +2444,7 @@ done:
* size control data structures.
*
* JRM -- 6/24/05
- * Added support for the new write_permitted field of
+ * Added support for the new write_permitted field of
* the H5C_t structure.
*
* JRM -- 7/5/05
@@ -2683,7 +2683,7 @@ done:
* ageout method of cache size reduction.
*
* JRM -- 1/19/06
- * Updated function for display the new prefix field of
+ * Updated function for display the new prefix field of
* H5C_t in output.
*
*-------------------------------------------------------------------------
@@ -2705,8 +2705,8 @@ H5C_def_auto_resize_rpt_fcn(H5C_t * cache_ptr,
switch ( status )
{
case in_spec:
- HDfprintf(stdout,
- "%sAuto cache resize -- no change. (hit rate = %lf)\n",
+ HDfprintf(stdout,
+ "%sAuto cache resize -- no change. (hit rate = %lf)\n",
cache_ptr->prefix, hit_rate);
break;
@@ -2714,9 +2714,9 @@ H5C_def_auto_resize_rpt_fcn(H5C_t * cache_ptr,
HDassert( hit_rate < (cache_ptr->resize_ctl).lower_hr_threshold );
HDassert( old_max_cache_size < new_max_cache_size );
- HDfprintf(stdout,
+ HDfprintf(stdout,
"%sAuto cache resize -- hit rate (%lf) out of bounds low (%6.5lf).\n",
- cache_ptr->prefix, hit_rate,
+ cache_ptr->prefix, hit_rate,
(cache_ptr->resize_ctl).lower_hr_threshold);
HDfprintf(stdout,
@@ -2749,7 +2749,7 @@ H5C_def_auto_resize_rpt_fcn(H5C_t * cache_ptr,
case H5C_decr__age_out:
HDfprintf(stdout,
- "%sAuto cache resize -- decrease by ageout. HR = %lf\n",
+ "%sAuto cache resize -- decrease by ageout. HR = %lf\n",
cache_ptr->prefix, hit_rate);
break;
@@ -2765,7 +2765,7 @@ H5C_def_auto_resize_rpt_fcn(H5C_t * cache_ptr,
default:
HDfprintf(stdout,
- "%sAuto cache resize -- decrease by unknown mode. HR = %lf\n",
+ "%sAuto cache resize -- decrease by unknown mode. HR = %lf\n",
cache_ptr->prefix, hit_rate);
}
@@ -2779,43 +2779,43 @@ H5C_def_auto_resize_rpt_fcn(H5C_t * cache_ptr,
break;
case at_max_size:
- HDfprintf(stdout,
- "%sAuto cache resize -- hit rate (%lf) out of bounds low (%6.5lf).\n",
- cache_ptr->prefix, hit_rate,
+ HDfprintf(stdout,
+ "%sAuto cache resize -- hit rate (%lf) out of bounds low (%6.5lf).\n",
+ cache_ptr->prefix, hit_rate,
(cache_ptr->resize_ctl).lower_hr_threshold);
- HDfprintf(stdout,
+ HDfprintf(stdout,
"%s cache already at maximum size so no change.\n",
cache_ptr->prefix);
break;
case at_min_size:
- HDfprintf(stdout,
- "%sAuto cache resize -- hit rate (%lf) -- can't decrease.\n",
+ HDfprintf(stdout,
+ "%sAuto cache resize -- hit rate (%lf) -- can't decrease.\n",
cache_ptr->prefix, hit_rate);
- HDfprintf(stdout, "%s cache already at minimum size.\n",
+ HDfprintf(stdout, "%s cache already at minimum size.\n",
cache_ptr->prefix);
break;
case increase_disabled:
- HDfprintf(stdout,
+ HDfprintf(stdout,
"%sAuto cache resize -- increase disabled -- HR = %lf.",
cache_ptr->prefix, hit_rate);
break;
case decrease_disabled:
- HDfprintf(stdout,
- "%sAuto cache resize -- decrease disabled -- HR = %lf.\n",
+ HDfprintf(stdout,
+ "%sAuto cache resize -- decrease disabled -- HR = %lf.\n",
cache_ptr->prefix, hit_rate);
break;
case not_full:
HDassert( hit_rate < (cache_ptr->resize_ctl).lower_hr_threshold );
- HDfprintf(stdout,
- "%sAuto cache resize -- hit rate (%lf) out of bounds low (%6.5lf).\n",
- cache_ptr->prefix, hit_rate,
+ HDfprintf(stdout,
+ "%sAuto cache resize -- hit rate (%lf) out of bounds low (%6.5lf).\n",
+ cache_ptr->prefix, hit_rate,
(cache_ptr->resize_ctl).lower_hr_threshold);
- HDfprintf(stdout,
+ HDfprintf(stdout,
"%s cache not full so no increase in size.\n",
cache_ptr->prefix);
break;
@@ -3004,7 +3004,7 @@ done:
* the marked entries.
*
* JRM -- 10/15/05
- * Added code supporting the new
+ * Added code supporting the new
* H5C__FLUSH_IGNORE_PROTECTED_FLAG. We need this flag, as
* we now use this function to flush large number of entries
* in increasing address order. We do this by marking the
@@ -3012,10 +3012,10 @@ done:
* and then restoring LRU order.
*
* However, it is possible that the cache will contain other,
- * unmarked protected entries, when we make this call. This
+ * unmarked protected entries, when we make this call. This
* new flag allows us to ignore them.
*
- * Note that even with this flag set, it is still an error
+ * Note that even with this flag set, it is still an error
* to try to flush a protected entry.
*
* JRM -- 3/25/065
@@ -3094,9 +3094,9 @@ H5C_flush_cache(H5F_t * f,
node_ptr = H5SL_first(cache_ptr->slist_ptr);
#if H5C_DO_SANITY_CHECKS
- /* H5C_flush_single_entry() now removes dirty entries from the
+ /* H5C_flush_single_entry() now removes dirty entries from the
* slist as it flushes them. Thus for sanity checks we must
- * make note of the initial slist length and size before we
+ * make note of the initial slist length and size before we
* do any flushes.
*/
initial_slist_len = cache_ptr->slist_len;
@@ -3126,8 +3126,8 @@ H5C_flush_cache(H5F_t * f,
if ( entry_ptr->is_protected ) {
- /* we probably have major problems -- but lets flush
- * everything we can before we decide whether to flag
+ /* we probably have major problems -- but lets flush
+ * everything we can before we decide whether to flag
* an error.
*/
tried_to_flush_protected_entry = TRUE;
@@ -3169,7 +3169,7 @@ H5C_flush_cache(H5F_t * f,
HDassert( protected_entries <= cache_ptr->pl_len );
- if ( ( ( cache_ptr->pl_len > 0 ) && ( !ignore_protected ) )
+ if ( ( ( cache_ptr->pl_len > 0 ) && ( !ignore_protected ) )
||
( tried_to_flush_protected_entry ) ) {
@@ -3191,16 +3191,16 @@ done:
* Purpose: Flush dirty entries until the caches min clean size is
* attained.
*
- * This function is used in the implementation of the
- * metadata cache in PHDF5. To avoid "messages from the
- * future", the cache on process 0 can't be allowed to
+ * This function is used in the implementation of the
+ * metadata cache in PHDF5. To avoid "messages from the
+ * future", the cache on process 0 can't be allowed to
* flush entries until the other processes have reached
* the same point in the calculation. If this constraint
* is not met, it is possible that the other processes will
- * read metadata generated at a future point in the
+ * read metadata generated at a future point in the
* computation.
*
- *
+ *
* Return: Non-negative on success/Negative on failure or if
* write is not permitted.
*
@@ -3214,9 +3214,9 @@ done:
* upon return.
*
* Do this by scanning up the dirty LRU list for entries to
- * flush to reach min clean size, setting their flush_marker
- * flags, and recording their addresses in the order
- * encountered.
+ * flush to reach min clean size, setting their flush_marker
+ * flags, and recording their addresses in the order
+ * encountered.
*
* Then call H5C_flush_cache() to flush the marked entries.
*
@@ -3228,13 +3228,13 @@ done:
* This change had the oposite of the desired effect. Lets
* leave it in (albeit commented out for now). If we can't
* find a case where it helps, lets get rid of it.
- *
+ *
*-------------------------------------------------------------------------
*/
herr_t
-H5C_flush_to_min_clean(H5F_t * f,
- hid_t primary_dxpl_id,
- hid_t secondary_dxpl_id,
+H5C_flush_to_min_clean(H5F_t * f,
+ hid_t primary_dxpl_id,
+ hid_t secondary_dxpl_id,
H5C_t * cache_ptr)
{
herr_t result;
@@ -3277,7 +3277,7 @@ H5C_flush_to_min_clean(H5F_t * f,
HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, \
"cache write is not permitted!?!\n");
}
-#if 1 /* original code */
+#if 1 /* original code */
result = H5C_make_space_in_cache(f,
primary_dxpl_id,
secondary_dxpl_id,
@@ -3291,17 +3291,17 @@ H5C_flush_to_min_clean(H5F_t * f,
HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, \
"H5C_make_space_in_cache failed.")
}
-#else /* modified code -- commented out for now */
+#else /* modified code -- commented out for now */
if ( cache_ptr->max_cache_size > cache_ptr->index_size ) {
- if ( ((cache_ptr->max_cache_size - cache_ptr->index_size) +
+ if ( ((cache_ptr->max_cache_size - cache_ptr->index_size) +
cache_ptr->cLRU_list_size) >= cache_ptr->min_clean_size ) {
space_needed = 0;
} else {
- space_needed = cache_ptr->min_clean_size -
+ space_needed = cache_ptr->min_clean_size -
((cache_ptr->max_cache_size - cache_ptr->index_size) +
cache_ptr->cLRU_list_size);
}
@@ -3313,7 +3313,7 @@ H5C_flush_to_min_clean(H5F_t * f,
} else {
- space_needed = cache_ptr->min_clean_size -
+ space_needed = cache_ptr->min_clean_size -
cache_ptr->cLRU_list_size;
}
}
@@ -3360,7 +3360,7 @@ H5C_flush_to_min_clean(H5F_t * f,
( flushed_entries_size < space_needed ) ) {
HDfprintf(stdout, "flushed_entries_count = %d <= %d = slist_size\n",
(int)flushed_entries_count, (int)(cache_ptr->slist_size));
- HDfprintf(stdout,
+ HDfprintf(stdout,
"flushed_entries_size = %d < %d = space_needed.\n",
(int)flushed_entries_size, (int)space_needed);
}
@@ -3370,7 +3370,7 @@ H5C_flush_to_min_clean(H5F_t * f,
/* Flush the marked entries */
- result = H5C_flush_cache(f, primary_dxpl_id, secondary_dxpl_id,
+ result = H5C_flush_cache(f, primary_dxpl_id, secondary_dxpl_id,
cache_ptr, H5C__FLUSH_MARKED_ENTRIES_FLAG |
H5C__FLUSH_IGNORE_PROTECTED_FLAG);
@@ -3380,12 +3380,12 @@ H5C_flush_to_min_clean(H5F_t * f,
}
/* Now touch up the LRU list so as to place the flushed entries in
- * the order they they would be in if we had flushed them in the
+ * the order they they would be in if we had flushed them in the
* order we encountered them in.
*/
i = 0;
- while ( i < flushed_entries_count )
+ while ( i < flushed_entries_count )
{
H5C__SEARCH_INDEX_NO_STATS(cache_ptr, flushed_entries_list[i], \
entry_ptr, FAIL)
@@ -3640,7 +3640,7 @@ H5C_get_entry_status(H5C_t * cache_ptr,
if ( entry_ptr == NULL ) {
- /* the entry doesn't exist in the cache -- report this
+ /* the entry doesn't exist in the cache -- report this
* and quit.
*/
*in_cache_ptr = FALSE;
@@ -3726,7 +3726,7 @@ done:
* is_dirty field of H5C_cache_entry_t into the H5C code.
*
* JRM -- 6/24/05
- * Added support for the new write_permitted field of
+ * Added support for the new write_permitted field of
* the H5C_t structure.
*
* JRM -- 3/16/06
@@ -3734,7 +3734,7 @@ done:
* H5C_cache_entry_t structure.
*
* JRM -- 5/3/06
- * Added initialization for the new dirtied field of the
+ * Added initialization for the new dirtied field of the
* H5C_cache_entry_t structure.
*
*-------------------------------------------------------------------------
@@ -3769,16 +3769,16 @@ H5C_insert_entry(H5F_t * f,
HDassert( H5F_addr_defined(addr) );
HDassert( thing );
-#if H5C_DO_EXTREME_SANITY_CHECKS
+#if H5C_DO_EXTREME_SANITY_CHECKS
if ( H5C_verify_not_in_index(cache_ptr, (H5C_cache_entry_t *)thing) < 0 ) {
-
+
HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, "thing already in index.\n");
}
#endif /* H5C_DO_SANITY_CHECKS */
-#if H5C_DO_EXTREME_SANITY_CHECKS
+#if H5C_DO_EXTREME_SANITY_CHECKS
if ( H5C_validate_lru_list(cache_ptr) < 0 ) {
-
+
HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, \
"LRU sanity check failed.\n");
}
@@ -3943,7 +3943,7 @@ H5C_insert_entry(H5F_t * f,
#if H5C_DO_EXTREME_SANITY_CHECKS
if ( H5C_validate_lru_list(cache_ptr) < 0 ) {
-
+
HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, \
"LRU sanity check failed.\n");
}
@@ -3971,9 +3971,9 @@ done:
* Function: H5C_mark_entries_as_clean
*
* Purpose: When the H5C code is used to implement the metadata caches
- * in PHDF5, only the cache with MPI_rank 0 is allowed to
+ * in PHDF5, only the cache with MPI_rank 0 is allowed to
* actually write entries to disk -- all other caches must
- * retain dirty entries until they are advised that the
+ * retain dirty entries until they are advised that the
* entries are clean.
*
* This function exists to allow the H5C code to receive these
@@ -3981,13 +3981,13 @@ done:
*
* The function receives a list of entry base addresses
* which must refer to dirty entries in the cache. If any
- * of the entries are either clean or don't exist, the
+ * of the entries are either clean or don't exist, the
* function flags an error.
*
* The function scans the list of entries and flushes all
- * those that are currently unprotected with the
+ * those that are currently unprotected with the
* H5C__FLUSH_CLEAR_ONLY_FLAG. Those that are currently
- * protected are flagged for clearing when they are
+ * protected are flagged for clearing when they are
* unprotected.
*
* Return: Non-negative on success/Negative on failure
@@ -4048,7 +4048,7 @@ H5C_mark_entries_as_clean(H5F_t * f,
#if H5C_DO_EXTREME_SANITY_CHECKS
if ( H5C_validate_lru_list(cache_ptr) < 0 ) {
-
+
HDassert(0);
HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, \
"LRU sanity check failed.\n");
@@ -4080,7 +4080,7 @@ H5C_mark_entries_as_clean(H5F_t * f,
#if H5C_DO_EXTREME_SANITY_CHECKS
if ( H5C_validate_lru_list(cache_ptr) < 0 ) {
-
+
HDassert(0);
HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, \
"LRU sanity check failed.\n");
@@ -4094,7 +4094,7 @@ H5C_mark_entries_as_clean(H5F_t * f,
if ( entry_ptr == NULL ) {
#if H5C_DO_SANITY_CHECKS
- HDfprintf(stdout,
+ HDfprintf(stdout,
"H5C_mark_entries_as_clean: entry[%d] = %ld not in cache.\n",
(int)i,
(long)addr);
@@ -4105,7 +4105,7 @@ H5C_mark_entries_as_clean(H5F_t * f,
} else if ( ! entry_ptr->is_dirty ) {
#if H5C_DO_SANITY_CHECKS
- HDfprintf(stdout,
+ HDfprintf(stdout,
"H5C_mark_entries_as_clean: entry %ld is not dirty!?!\n",
(long)addr);
#endif /* H5C_DO_SANITY_CHECKS */
@@ -4131,7 +4131,7 @@ H5C_mark_entries_as_clean(H5F_t * f,
HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, "Can't clear entry.")
}
}
-#else /* modified code */
+#else /* modified code */
} else {
/* Mark the entry to be cleared on unprotect. We will
* scan the LRU list shortly, and clear all those entries
@@ -4156,12 +4156,12 @@ H5C_mark_entries_as_clean(H5F_t * f,
#endif /* end modified code */
}
#if 1 /* modified code */
- /* Scan through the LRU list from back to front, and flush the
+ /* Scan through the LRU list from back to front, and flush the
* entries whose clear_on_unprotect flags are set. Observe that
* any protected entries will not be on the LRU, and therefore
* will not be flushed at this time.
*/
-
+
entries_cleared = 0;
entries_examined = 0;
initial_list_len = cache_ptr->LRU_list_len;
@@ -4169,7 +4169,7 @@ H5C_mark_entries_as_clean(H5F_t * f,
while ( ( entry_ptr != NULL ) &&
( entries_examined <= initial_list_len ) &&
- ( entries_cleared < ce_array_len ) )
+ ( entries_cleared < ce_array_len ) )
{
if ( entry_ptr->clear_on_unprotect ) {
@@ -4239,13 +4239,13 @@ H5C_mark_entries_as_clean(H5F_t * f,
HDassert( entries_cleared + protected_entries_marked == ce_array_len );
#endif /* H5C_DO_SANITY_CHECKS */
- HDassert( ( entries_cleared == ce_array_len ) ||
+ HDassert( ( entries_cleared == ce_array_len ) ||
( (ce_array_len - entries_cleared) <= cache_ptr->pl_len ) );
#if H5C_DO_SANITY_CHECKS
i = 0;
entry_ptr = cache_ptr->pl_head_ptr;
- while ( entry_ptr != NULL )
+ while ( entry_ptr != NULL )
{
if ( entry_ptr->clear_on_unprotect ) {
@@ -4261,7 +4261,7 @@ done:
#if H5C_DO_EXTREME_SANITY_CHECKS
if ( H5C_validate_lru_list(cache_ptr) < 0 ) {
-
+
HDassert(0);
HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, \
"LRU sanity check failed.\n");
@@ -4280,7 +4280,7 @@ done:
* Purpose: Mark a pinned entry as dirty. The target entry MUST be
* be pinned, and MUST be unprotected.
*
- * If the entry has changed size, the function updates
+ * If the entry has changed size, the function updates
* data structures for the size change.
*
* If the entry is not already dirty, the function places
@@ -4374,16 +4374,16 @@ done:
/*-------------------------------------------------------------------------
* Function: H5C_mark_pinned_or_protected_entry_dirty
*
- * Purpose: Mark a pinned or protected entry as dirty. The target entry
+ * Purpose: Mark a pinned or protected entry as dirty. The target entry
* MUST be either pinned or protected, and MAY be both.
*
* At present, this funtion does not support size change.
*
- * In the protected case, this call is the functional
+ * In the protected case, this call is the functional
* equivalent of setting the H5C__DIRTIED_FLAG on an unprotect
* call.
*
- * In the pinned but not protected case, if the entry is not
+ * In the pinned but not protected case, if the entry is not
* already dirty, the function places function marks the entry
* dirty and places it on the skip list.
*
@@ -4498,7 +4498,7 @@ H5C_rename_entry(H5C_t * cache_ptr,
#if H5C_DO_EXTREME_SANITY_CHECKS
if ( H5C_validate_lru_list(cache_ptr) < 0 ) {
-
+
HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, \
"LRU sanity check failed.\n");
}
@@ -4575,7 +4575,7 @@ done:
#if H5C_DO_EXTREME_SANITY_CHECKS
if ( H5C_validate_lru_list(cache_ptr) < 0 ) {
-
+
HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, \
"LRU sanity check failed.\n");
}
@@ -4589,7 +4589,7 @@ done:
/*-------------------------------------------------------------------------
* Function: H5C_pin_protected_entry()
*
- * Purpose: Pin a protected cache entry. The entry must be protected
+ * Purpose: Pin a protected cache entry. The entry must be protected
* at the time of call, and must be unpinned.
*
* Return: Non-negative on success/Negative on failure
@@ -4703,7 +4703,7 @@ done:
* Hand optimizations.
*
* JRM -- 5/3/06
- * Added code to set the new dirtied field in
+ * Added code to set the new dirtied field in
* H5C_cache_entry_t to FALSE prior to return.
*
*-------------------------------------------------------------------------
@@ -4741,7 +4741,7 @@ H5C_protect(H5F_t * f,
#if H5C_DO_EXTREME_SANITY_CHECKS
if ( H5C_validate_lru_list(cache_ptr) < 0 ) {
-
+
HDassert(0);
HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, NULL, \
"LRU sanity check failed.\n");
@@ -4966,7 +4966,7 @@ done:
#if H5C_DO_EXTREME_SANITY_CHECKS
if ( H5C_validate_lru_list(cache_ptr) < 0 ) {
-
+
HDassert(0);
HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, NULL, \
"LRU sanity check failed.\n");
@@ -5273,7 +5273,7 @@ done:
/*-------------------------------------------------------------------------
* Function: H5C_set_prefix
*
- * Purpose: Set the values of the prefix field of H5C_t. This
+ * Purpose: Set the values of the prefix field of H5C_t. This
* filed is used to label some debugging output.
*
* Return: Non-negative on success/Negative on failure
@@ -5374,11 +5374,11 @@ done:
* Updated function for the addition of the hash table.
*
* JRM -- 9/8/05
- * Updated function for the addition of cache entry size
+ * Updated function for the addition of cache entry size
* change statistics.
*
* JRM -- 1/13/06
- * Added code to use the prefix field of H5C_t to allow
+ * Added code to use the prefix field of H5C_t to allow
* tagging of statistics output.
*
* JRM -- 3/21/06
@@ -5502,7 +5502,7 @@ H5C_stats(H5C_t * cache_ptr,
HDfprintf(stdout, "\n");
HDfprintf(stdout,
- "%s hash table insertion / deletions = %ld / %ld\n",
+ "%s hash table insertion / deletions = %ld / %ld\n",
cache_ptr->prefix,
(long)(cache_ptr->total_ht_insertions),
(long)(cache_ptr->total_ht_deletions));
@@ -5550,7 +5550,7 @@ H5C_stats(H5C_t * cache_ptr,
(long)(cache_ptr->max_pel_size),
(long)(cache_ptr->pel_len),
(long)(cache_ptr->max_pel_len));
-
+
HDfprintf(stdout,
"%s current LRU list size / length = %ld / %ld\n",
cache_ptr->prefix,
@@ -5593,7 +5593,7 @@ H5C_stats(H5C_t * cache_ptr,
(long)total_size_increases,
(long)total_size_decreases);
- HDfprintf(stdout,
+ HDfprintf(stdout,
"%s Total entry pins (dirty) / unpins = %ld (%ld) / %ld\n",
cache_ptr->prefix,
(long)total_pins,
@@ -5663,19 +5663,19 @@ H5C_stats(H5C_t * cache_ptr,
(long)(cache_ptr->insertions[i]),
(long)(cache_ptr->renames[i]));
- HDfprintf(stdout,
+ HDfprintf(stdout,
"%s size increases / decreases = %ld / %ld\n",
cache_ptr->prefix,
(long)(cache_ptr->size_increases[i]),
(long)(cache_ptr->size_decreases[i]));
- HDfprintf(stdout,
+ HDfprintf(stdout,
"%s entry pins / unpins = %ld / %ld\n",
cache_ptr->prefix,
(long)(cache_ptr->pins[i]),
(long)(cache_ptr->unpins[i]));
- HDfprintf(stdout,
+ HDfprintf(stdout,
"%s entry dirty pins/pin'd flushes = %ld / %ld\n",
cache_ptr->prefix,
(long)(cache_ptr->dirty_pins[i]),
@@ -5812,7 +5812,7 @@ H5C_stats__reset(H5C_t * cache_ptr)
/*-------------------------------------------------------------------------
* Function: H5C_unpin_entry()
*
- * Purpose: Unpin a cache entry. The entry must be unprotected at
+ * Purpose: Unpin a cache entry. The entry must be unprotected at
* the time of call, and must be pinned.
*
* Return: Non-negative on success/Negative on failure
@@ -5945,7 +5945,7 @@ done:
* the new H5C__PIN_ENTRY_FLAG and H5C__UNPIN_ENTRY_FLAG flags.
*
* JRM -- 5/3/06
- * Added code to make use of the new dirtied field in
+ * Added code to make use of the new dirtied field in
* H5C_cache_entry_t. If this field is TRUE, it is the
* equivalent of setting the H5C__DIRTIED_FLAG.
*
@@ -6002,27 +6002,27 @@ H5C_unprotect(H5F_t * f,
HDassert( entry_ptr->addr == addr );
HDassert( entry_ptr->type == type );
- /* also set the dirtied variable if the dirtied field is set in
+ /* also set the dirtied variable if the dirtied field is set in
* the entry.
*/
dirtied |= entry_ptr->dirtied;
#if H5C_DO_EXTREME_SANITY_CHECKS
if ( H5C_validate_lru_list(cache_ptr) < 0 ) {
-
+
HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, \
"LRU sanity check failed.\n");
}
#endif /* H5C_DO_EXTREME_SANITY_CHECKS */
#ifdef H5_HAVE_PARALLEL
- /* When the H5C code is used to implement the metadata cache in the
+ /* When the H5C code is used to implement the metadata cache in the
* PHDF5 case, only the cache on process 0 is allowed to write to file.
* All the other metadata caches must hold dirty entries until they
- * are told that the entries are clean.
+ * are told that the entries are clean.
*
- * The clear_on_unprotect flag in the H5C_cache_entry_t structure
- * exists to deal with the case in which an entry is protected when
+ * The clear_on_unprotect flag in the H5C_cache_entry_t structure
+ * exists to deal with the case in which an entry is protected when
* its cache receives word that the entry is now clean. In this case,
* the clear_on_unprotect flag is set, and the entry is flushed with
* the H5C__FLUSH_CLEAR_ONLY_FLAG.
@@ -6198,14 +6198,14 @@ H5C_unprotect(H5F_t * f,
"hash table contains multiple entries for addr?!?.")
}
- if ( H5C_flush_single_entry(f,
- primary_dxpl_id,
- secondary_dxpl_id,
+ if ( H5C_flush_single_entry(f,
+ primary_dxpl_id,
+ secondary_dxpl_id,
cache_ptr,
- type,
- addr,
+ type,
+ addr,
H5C__FLUSH_CLEAR_ONLY_FLAG,
- &dummy_first_flush,
+ &dummy_first_flush,
TRUE) < 0 ) {
HGOTO_ERROR(H5E_CACHE, H5E_CANTUNPROTECT, FAIL, "Can't clear.")
@@ -6219,7 +6219,7 @@ done:
#if H5C_DO_EXTREME_SANITY_CHECKS
if ( H5C_validate_lru_list(cache_ptr) < 0 ) {
-
+
HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, \
"LRU sanity check failed.\n");
}
@@ -7538,17 +7538,17 @@ done:
*
* If the cache contains protected entries, the function will
* fail, as protected entries cannot be either flushed or
- * destroyed. However all unprotected entries should be
+ * destroyed. However all unprotected entries should be
* flushed and destroyed before the function returns failure.
*
* While pinned entries can usually be flushed, they cannot
* be destroyed. However, they should be unpinned when all
* the entries that reference them have been destroyed (thus
* reduding the pinned entry's reference count to 0, allowing
- * it to be unpinned).
+ * it to be unpinned).
*
- * If pinned entries are present, the function makes repeated
- * passes through the cache, flushing all dirty entries
+ * If pinned entries are present, the function makes repeated
+ * passes through the cache, flushing all dirty entries
* (including the pinned dirty entries where permitted) and
* destroying all unpinned entries. This process is repeated
* until either the cache is empty, or the number of pinned
@@ -7625,7 +7625,7 @@ H5C_flush_invalidate_cache(H5F_t * f,
cur_pel_len = cache_ptr->pel_len;
old_pel_len = cache_ptr->pel_len;
- while ( ( first_pass ) ||
+ while ( ( first_pass ) ||
( ( cur_pel_len < old_pel_len ) && ( protected_entries == 0 ) ) )
{
have_pinned_entries = ( cur_pel_len > 0 );
@@ -7642,9 +7642,9 @@ H5C_flush_invalidate_cache(H5F_t * f,
node_ptr = H5SL_first(cache_ptr->slist_ptr);
#if H5C_DO_SANITY_CHECKS
- /* Depending on circumstances, H5C_flush_single_entry() will
- * remove dirty entries from the slist as it flushes them.
- * Thus for sanity checks we must make note of the initial
+ /* Depending on circumstances, H5C_flush_single_entry() will
+ * remove dirty entries from the slist as it flushes them.
+ * Thus for sanity checks we must make note of the initial
* slist length and size before we do any flushes.
*/
initial_slist_len = cache_ptr->slist_len;
@@ -7657,13 +7657,13 @@ H5C_flush_invalidate_cache(H5F_t * f,
{
/* Note that we now remove nodes from the slist as we flush
* the associated entries, instead of leaving them there
- * until we are done, and then destroying all nodes in
+ * until we are done, and then destroying all nodes in
* the slist.
*
* While this optimization is still easy if everything works,
- * the addition of pinned entries and multiple passes
+ * the addition of pinned entries and multiple passes
* through the cache to allow entries to unpin themselves
- * complicates error recover greatly.
+ * complicates error recover greatly.
*
* Given these complications, I've decided to ommit this
* this optimization for now. It can be re-implemented
@@ -7687,7 +7687,7 @@ H5C_flush_invalidate_cache(H5F_t * f,
if ( entry_ptr->is_protected ) {
- /* we have major problems -- but lets flush
+ /* we have major problems -- but lets flush
* everything we can before we flag an error.
*/
protected_entries++;
@@ -7728,7 +7728,7 @@ H5C_flush_invalidate_cache(H5F_t * f,
cache_ptr,
NULL,
entry_ptr->addr,
- (cooked_flags |
+ (cooked_flags |
H5C__FLUSH_INVALIDATE_FLAG),
&first_flush,
TRUE);
@@ -7749,8 +7749,8 @@ H5C_flush_invalidate_cache(H5F_t * f,
#endif /* H5C_DO_SANITY_CHECKS */
/* Since we are doing a destroy, we must make a pass through
- * the hash table and try to flush - destroy all entries that
- * remain. Note that all remaining entries entries must be
+ * the hash table and try to flush - destroy all entries that
+ * remain. Note that all remaining entries entries must be
* clean, so this will not result in any writes to disk.
*/
for ( i = 0; i < H5C__HASH_TABLE_LEN; i++ )
@@ -7784,7 +7784,7 @@ H5C_flush_invalidate_cache(H5F_t * f,
cache_ptr,
NULL,
entry_ptr->addr,
- (cooked_flags |
+ (cooked_flags |
H5C__FLUSH_INVALIDATE_FLAG),
&first_flush,
TRUE);
@@ -7797,8 +7797,8 @@ H5C_flush_invalidate_cache(H5F_t * f,
"Clean entry flush destroy failed.")
}
}
- /* We can't do anything if the entry is pinned. The
- * hope is that the entry will be unpinned as the
+ /* We can't do anything if the entry is pinned. The
+ * hope is that the entry will be unpinned as the
* result of destroys of entries that reference it.
*
* We detect this by noting the change in the number
@@ -7811,7 +7811,7 @@ H5C_flush_invalidate_cache(H5F_t * f,
HDassert( protected_entries == cache_ptr->pl_len );
old_pel_len = cur_pel_len;
- cur_pel_len = cache_ptr->pel_len;
+ cur_pel_len = cache_ptr->pel_len;
first_pass = FALSE;
@@ -7898,9 +7898,9 @@ done:
* respectively.
*
* JRM -- 6/24/05
- * Added code to remove dirty entries from the slist after
- * they have been flushed. Also added a sanity check that
- * will scream if we attempt a write when writes are
+ * Added code to remove dirty entries from the slist after
+ * they have been flushed. Also added a sanity check that
+ * will scream if we attempt a write when writes are
* completely disabled.
*
* JRM -- 7/5/05
@@ -8233,7 +8233,7 @@ H5C_flush_single_entry(H5F_t * f,
if ( cache_ptr->log_flush ) {
- status = (cache_ptr->log_flush)(cache_ptr, addr, was_dirty,
+ status = (cache_ptr->log_flush)(cache_ptr, addr, was_dirty,
flags, type_id);
if ( status < 0 ) {
@@ -8491,7 +8491,7 @@ H5C_make_space_in_cache(H5F_t * f,
entry_ptr = cache_ptr->dLRU_tail_ptr;
if ( cache_ptr->index_size < cache_ptr->max_cache_size ) {
-
+
empty_space = cache_ptr->max_cache_size - cache_ptr->index_size;
} else {
@@ -8499,7 +8499,7 @@ H5C_make_space_in_cache(H5F_t * f,
empty_space = 0;
}
- while ( ( (cache_ptr->cLRU_list_size + empty_space)
+ while ( ( (cache_ptr->cLRU_list_size + empty_space)
< cache_ptr->min_clean_size ) &&
( entries_examined <= initial_list_len ) &&
( entry_ptr != NULL )
@@ -8587,7 +8587,7 @@ done:
*
* Purpose: Debugging function that scans the LRU list for errors.
*
- * If an error is detected, the function generates a
+ * If an error is detected, the function generates a
* diagnostic and returns FAIL. If no error is detected,
* the function returns SUCCEED.
*
@@ -8615,10 +8615,10 @@ H5C_validate_lru_list(H5C_t * cache_ptr)
HDassert( cache_ptr );
HDassert( cache_ptr->magic == H5C__H5C_T_MAGIC );
- if ( ( ( cache_ptr->LRU_head_ptr == NULL )
- ||
- ( cache_ptr->LRU_tail_ptr == NULL )
- )
+ if ( ( ( cache_ptr->LRU_head_ptr == NULL )
+ ||
+ ( cache_ptr->LRU_tail_ptr == NULL )
+ )
&&
( cache_ptr->LRU_head_ptr != cache_ptr->LRU_tail_ptr )
) {
@@ -8633,7 +8633,7 @@ H5C_validate_lru_list(H5C_t * cache_ptr)
HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, "Check 2 failed")
}
- if ( ( cache_ptr->LRU_list_len == 1 )
+ if ( ( cache_ptr->LRU_list_len == 1 )
&&
( ( cache_ptr->LRU_head_ptr != cache_ptr->LRU_tail_ptr )
||
@@ -8688,7 +8688,7 @@ H5C_validate_lru_list(H5C_t * cache_ptr)
entry_ptr = entry_ptr->next;
}
- if ( ( cache_ptr->LRU_list_len != len ) ||
+ if ( ( cache_ptr->LRU_list_len != len ) ||
( cache_ptr->LRU_list_size != size ) ) {
HDfprintf(stdout,"H5C_validate_lru_list: Check 7 failed.\n");
@@ -8717,7 +8717,7 @@ done:
* that the specified instance of H5C_cache_entry_t is not
* present.
*
- * If an error is detected, the function generates a
+ * If an error is detected, the function generates a
* diagnostic and returns FAIL. If no error is detected,
* the function returns SUCCEED.
*
@@ -8756,7 +8756,7 @@ H5C_verify_not_in_index(H5C_t * cache_ptr,
{
if ( scan_ptr == entry_ptr ) {
- HDfprintf(stdout,
+ HDfprintf(stdout,
"H5C_verify_not_in_index: entry in index (%d/%d)\n",
i, depth);
HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, \
diff --git a/src/H5CS.c b/src/H5CS.c
index 3de842b..79db4ba 100644
--- a/src/H5CS.c
+++ b/src/H5CS.c
@@ -167,10 +167,10 @@ herr_t
H5CS_print(FILE *stream)
{
H5CS_t *fstack = H5CS_get_my_stack (); /* Get the correct function stack */
-
+
/* Don't push this function on the function stack... :-) */
FUNC_ENTER_NOAPI_NOFUNC_NOFS(H5CS_print);
-
+
/* Sanity check */
assert(fstack);
@@ -270,7 +270,7 @@ H5CS_copy_stack(H5CS_t *new_stack)
{
H5CS_t *old_stack = H5CS_get_my_stack ();
unsigned u; /* Local index variable */
-
+
/* Don't push this function on the function stack... :-) */
FUNC_ENTER_NOAPI_NOFUNC_NOFS(H5CS_copy_stack);
@@ -304,7 +304,7 @@ herr_t
H5CS_close_stack(H5CS_t *stack)
{
unsigned u; /* Local index variable */
-
+
/* Don't push this function on the function stack... :-) */
FUNC_ENTER_NOAPI_NOFUNC_NOFS(H5CS_close_stack);
diff --git a/src/H5Cpkg.h b/src/H5Cpkg.h
index 12fcfe5..16c27de 100644
--- a/src/H5Cpkg.h
+++ b/src/H5Cpkg.h
@@ -79,7 +79,7 @@
*
* JRM - 7/19/04
*
- * The TBBT has since been replaced with a skip list. This change
+ * The TBBT has since been replaced with a skip list. This change
* greatly predates this note.
*
* JRM - 9/26/05
@@ -87,7 +87,7 @@
* magic: Unsigned 32 bit integer always set to H5C__H5C_T_MAGIC. This
* field is used to validate pointers to instances of H5C_t.
*
- * aux_ptr: Pointer to void used to allow wrapper code to associate
+ * aux_ptr: Pointer to void used to allow wrapper code to associate
* its data with an instance of H5C_t. The H5C cache code
* sets this field to NULL, and otherwise leaves it alone.
*
@@ -142,10 +142,10 @@
* the cache uses the following write_permitted field to
* determine whether writes are permitted.
*
- * write_permitted: If check_write_permitted is NULL, this boolean flag
+ * write_permitted: If check_write_permitted is NULL, this boolean flag
* indicates whether writes are permitted.
*
- * log_flush: If provided, this function is called whenever a dirty
+ * log_flush: If provided, this function is called whenever a dirty
* entry is flushed to disk.
*
*
@@ -187,7 +187,7 @@
* on how frequently the cache is flushed. We will see how it goes.
*
* For now at least, I will not remove dirty entries from the list as they
- * are flushed. (this has been changed -- dirty entries are now removed from
+ * are flushed. (this has been changed -- dirty entries are now removed from
* the skip list as they are flushed. JRM - 10/25/05)
*
* slist_len: Number of entries currently in the skip list
@@ -235,22 +235,22 @@
*
* For very frequently used entries, the protect/unprotect overhead can
* become burdensome. To avoid this overhead, I have modified the cache
- * to allow entries to be "pinned". A pinned entry is similar to a
+ * to allow entries to be "pinned". A pinned entry is similar to a
* protected entry, in the sense that it cannot be evicted, and that
* the entry can be modified at any time.
*
* Pinning an entry has the following implications:
*
* 1) A pinned entry cannot be evicted. Thus unprotected
- * pinned entries reside in the pinned entry list, instead
+ * pinned entries reside in the pinned entry list, instead
* of the LRU list(s) (or other lists maintained by the current
* replacement policy code).
- *
+ *
* 2) A pinned entry can be accessed or modified at any time.
* Therefore, the cache must check with the entry owner
* before flushing it. If permission is denied, the
* cache just skips the entry in the flush.
- *
+ *
* 3) A pinned entry can be marked as dirty (and possibly
* change size) while it is unprotected.
*
@@ -263,20 +263,20 @@
*
* Maintaining the pinned entry list requires the following fields:
*
- * pel_len: Number of entries currently residing on the pinned
+ * pel_len: Number of entries currently residing on the pinned
* entry list.
*
* pel_size: Number of bytes of cache entries currently residing on
* the pinned entry list.
*
* pel_head_ptr: Pointer to the head of the doubly linked list of pinned
- * but not protected entries. Note that cache entries on
+ * but not protected entries. Note that cache entries on
* this list are linked by their next and prev fields.
*
* This field is NULL if the list is empty.
*
* pel_tail_ptr: Pointer to the tail of the doubly linked list of pinned
- * but not protected entries. Note that cache entries on
+ * but not protected entries. Note that cache entries on
* this list are linked by their next and prev fields.
*
* This field is NULL if the list is empty.
@@ -568,24 +568,24 @@
* id equal to the array index has been marked dirty while pinned
* in the current epoch.
*
- * pinned_flushes: Array of int64 of length H5C__MAX_NUM_TYPE_IDS + 1. The
- * cells are used to record the number of times an entry
- * with type id equal to the array index has been flushed while
+ * pinned_flushes: Array of int64 of length H5C__MAX_NUM_TYPE_IDS + 1. The
+ * cells are used to record the number of times an entry
+ * with type id equal to the array index has been flushed while
* pinned in the current epoch.
*
- * pinned_cleared: Array of int64 of length H5C__MAX_NUM_TYPE_IDS + 1. The
- * cells are used to record the number of times an entry
- * with type id equal to the array index has been cleared while
+ * pinned_cleared: Array of int64 of length H5C__MAX_NUM_TYPE_IDS + 1. The
+ * cells are used to record the number of times an entry
+ * with type id equal to the array index has been cleared while
* pinned in the current epoch.
*
*
- * size_increases: Array of int64 of length H5C__MAX_NUM_TYPE_IDS + 1.
- * The cells are used to record the number of times an entry
+ * size_increases: Array of int64 of length H5C__MAX_NUM_TYPE_IDS + 1.
+ * The cells are used to record the number of times an entry
* with type id equal to the array index has increased in
* size in the current epoch.
*
- * size_decreases: Array of int64 of length H5C__MAX_NUM_TYPE_IDS + 1.
- * The cells are used to record the number of times an entry
+ * size_decreases: Array of int64 of length H5C__MAX_NUM_TYPE_IDS + 1.
+ * The cells are used to record the number of times an entry
* with type id equal to the array index has decreased in
* size in the current epoch.
*
@@ -662,8 +662,8 @@
* the cache in the current epoch.
*
* max_pins: Array of size_t of length H5C__MAX_NUM_TYPE_IDS + 1. The cells
- * are used to record the maximum number of times that any single
- * entry with type id equal to the array index that has been
+ * are used to record the maximum number of times that any single
+ * entry with type id equal to the array index that has been
* marked as pinned in the cache in the current epoch.
*
*
diff --git a/src/H5Cprivate.h b/src/H5Cprivate.h
index bdcf501..fd54d69 100644
--- a/src/H5Cprivate.h
+++ b/src/H5Cprivate.h
@@ -187,8 +187,8 @@ typedef herr_t (*H5C_log_flush_func_t)(H5C_t * cache_ptr,
*
* In typical application, this structure is the first field in a
* structure to be cached. For historical reasons, the external module
- * is responsible for managing the is_dirty field (this is no longer
- * completely true. See the comment on the is_dirty field for details).
+ * is responsible for managing the is_dirty field (this is no longer
+ * completely true. See the comment on the is_dirty field for details).
* All other fields are managed by the cache.
*
* The fields of this structure are discussed individually below:
@@ -230,23 +230,23 @@ typedef herr_t (*H5C_log_flush_func_t)(H5C_t * cache_ptr,
*
* Update: Management of the is_dirty field has been largely
* moved into the cache. The only remaining exceptions
- * are the flush and clear functions supplied by the
- * modules using the cache. These still clear the
+ * are the flush and clear functions supplied by the
+ * modules using the cache. These still clear the
* is_dirty field as before. -- JRM 7/5/05
*
* dirtied: Boolean flag used to indicate that the entry has been
* dirtied while protected.
*
* This field is set to FALSE in the protect call, and may
- * be set to TRUE by the
+ * be set to TRUE by the
* H5C_mark_pinned_or_protected_entry_dirty()
* call at an time prior to the unprotect call.
*
- * The H5C_mark_pinned_or_protected_entry_dirty() call exists
+ * The H5C_mark_pinned_or_protected_entry_dirty() call exists
* as a convenience function for the fractal heap code which
* may not know if an entry is protected or pinned, but knows
- * that is either protected or pinned. The dirtied field was
- * added as in the parallel case, it is necessary to know
+ * that is either protected or pinned. The dirtied field was
+ * added as in the parallel case, it is necessary to know
* whether a protected entry was dirty prior to the protect call.
*
* is_protected: Boolean flag indicating whether this entry is protected
@@ -261,7 +261,7 @@ typedef herr_t (*H5C_log_flush_func_t)(H5C_t * cache_ptr,
* is_pinned: Boolean flag indicating whether the entry has been pinned
* in the cache.
*
- * For very hot entries, the protect / unprotect overhead
+ * For very hot entries, the protect / unprotect overhead
* can become excessive. Thus the cache has been extended
* to allow an entry to be "pinned" in the cache.
*
@@ -274,14 +274,14 @@ typedef herr_t (*H5C_log_flush_func_t)(H5C_t * cache_ptr,
*
* 2) A pinned entry can be accessed or modified at any time.
* Therefore, the cache must check with the entry owner
- * before flushing it. If permission is denied, the
+ * before flushing it. If permission is denied, the
* cache does not flush the entry.
*
- * 3) A pinned entry can be marked as dirty (and possibly
+ * 3) A pinned entry can be marked as dirty (and possibly
* change size) while it is unprotected.
*
- * 4) The flush-destroy code must allow pinned entries to
- * be unpinned (and possibly unprotected) during the
+ * 4) The flush-destroy code must allow pinned entries to
+ * be unpinned (and possibly unprotected) during the
* flush.
*
* JRM -- 3/16/06
@@ -301,13 +301,13 @@ typedef herr_t (*H5C_log_flush_func_t)(H5C_t * cache_ptr,
*
* clear_on_unprotect: Boolean flag used only in PHDF5. When H5C is used
* to implement the metadata cache In the parallel case, only
- * the cache with mpi rank 0 is allowed to actually write to
+ * the cache with mpi rank 0 is allowed to actually write to
* file -- all other caches must retain dirty entries until they
- * are advised that the entry is clean.
+ * are advised that the entry is clean.
*
- * This flag is used in the case that such an advisory is
+ * This flag is used in the case that such an advisory is
* received when the entry is protected. If it is set when an
- * entry is unprotected, and the dirtied flag is not set in
+ * entry is unprotected, and the dirtied flag is not set in
* the unprotect, the entry's is_dirty flag is reset by flushing
* it with the H5C__FLUSH_CLEAR_ONLY_FLAG.
*
@@ -406,7 +406,7 @@ typedef herr_t (*H5C_log_flush_func_t)(H5C_t * cache_ptr,
* been flushed to file in its life time.
*
* pins: int32_t containing the number of times this cache entry has
- * been pinned in cache in its life time.
+ * been pinned in cache in its life time.
*
****************************************************************************/
@@ -416,7 +416,7 @@ typedef struct H5C_cache_entry_t
size_t size;
const H5C_class_t * type;
hbool_t is_dirty;
- hbool_t dirtied;
+ hbool_t dirtied;
hbool_t is_protected;
hbool_t is_pinned;
hbool_t in_slist;
diff --git a/src/H5D.c b/src/H5D.c
index 5c4591d..0fc4168 100644
--- a/src/H5D.c
+++ b/src/H5D.c
@@ -196,7 +196,7 @@ H5D_init_interface(void)
size_t def_hyp_vec_size = H5D_XFER_HYPER_VECTOR_SIZE_DEF;
#ifdef H5_HAVE_PARALLEL
H5FD_mpio_xfer_t def_io_xfer_mode = H5D_XFER_IO_XFER_MODE_DEF;
- H5FD_mpio_chunk_opt_t def_mpio_chunk_opt_mode = H5D_XFER_MPIO_CHUNK_OPT_HARD_DEF;
+ H5FD_mpio_chunk_opt_t def_mpio_chunk_opt_mode = H5D_XFER_MPIO_CHUNK_OPT_HARD_DEF;
unsigned def_mpio_chunk_opt_num = H5D_XFER_MPIO_CHUNK_OPT_NUM_DEF;
unsigned def_mpio_chunk_opt_ratio = H5D_XFER_MPIO_CHUNK_OPT_RATIO_DEF;
#endif /* H5_HAVE_PARALLEL */
diff --git a/src/H5Dcompact.c b/src/H5Dcompact.c
index aaa04ea..ae4e473 100644
--- a/src/H5Dcompact.c
+++ b/src/H5Dcompact.c
@@ -155,7 +155,7 @@ done:
* Return: Non-negative on success, negative on failure.
*
* Programmer: Peter Cao
- * December 11, 2005
+ * December 11, 2005
*
*-------------------------------------------------------------------------
*/
@@ -181,10 +181,10 @@ H5D_compact_copy(H5F_t *f_src, H5O_layout_t *layout_src,
HDassert(layout_dst && H5D_COMPACT == layout_dst->type);
/* If there's a source datatype, set up type conversion information */
- if (!dt_src)
+ if (!dt_src)
/* Type conversion not necessary */
HDmemcpy(layout_dst->u.compact.buf, layout_src->u.compact.buf, layout_src->u.compact.size);
- else {
+ else {
H5T_path_t *tpath_src_mem, *tpath_mem_dst; /* Datatype conversion paths */
H5T_t *dt_dst; /* Destination datatype */
H5T_t *dt_mem; /* Memory datatype */
diff --git a/src/H5Dcontig.c b/src/H5Dcontig.c
index 09af474..285f121 100644
--- a/src/H5Dcontig.c
+++ b/src/H5Dcontig.c
@@ -988,7 +988,7 @@ done:
* Return: Non-negative on success, negative on failure.
*
* Programmer: Quincey Koziol
- * Monday, November 21, 2005
+ * Monday, November 21, 2005
*
* Modifier: Peter Cao
* Saturday, January 07, 2006
@@ -996,7 +996,7 @@ done:
*-------------------------------------------------------------------------
*/
herr_t
-H5D_contig_copy(H5F_t *f_src, H5O_layout_t *layout_src,
+H5D_contig_copy(H5F_t *f_src, H5O_layout_t *layout_src,
H5F_t *f_dst, H5O_layout_t *layout_dst, H5T_t *dt_src, hid_t dxpl_id)
{
haddr_t addr_src; /* File offset in source dataset */
diff --git a/src/H5Dio.c b/src/H5Dio.c
index dec068e..05b428e 100644
--- a/src/H5Dio.c
+++ b/src/H5Dio.c
@@ -1249,7 +1249,7 @@ H5D_contig_write(H5D_io_info_t *io_info, hsize_t nelmts,
if(H5D_contig_collective_io(io_info,file_space,mem_space,buf,TRUE)<0)
HGOTO_ERROR(H5E_DATASET, H5E_CANTGET, FAIL, "contiguous write failed in collective mode");
}
- else
+ else
#endif
{
if((io_info->ops.write)(io_info,
@@ -1514,7 +1514,7 @@ H5D_chunk_read(H5D_io_info_t *io_info, hsize_t nelmts,
if(H5D_chunk_collective_io(io_info,&fm,buf,FALSE)<0)
HGOTO_ERROR(H5E_DATASET, H5E_CANTGET, FAIL, "chunked read failed in collective mode");
}
-
+
else {/* sequential or independent read */
#endif
/* Get first node in chunk skip list */
@@ -1830,7 +1830,7 @@ H5D_chunk_write(H5D_io_info_t *io_info, hsize_t nelmts,
#ifdef H5_HAVE_PARALLEL
/* Check whether the collective mode can be turned off globally*/
-
+
if(io_info->dxpl_cache->xfer_mode == H5FD_MPIO_COLLECTIVE) {
if(H5D_mpio_chunk_adjust_iomode(io_info,&fm))
HGOTO_ERROR(H5E_DATASET,H5E_CANTGET,FAIL,"can't adjust collective I/O")
@@ -1840,7 +1840,7 @@ H5D_chunk_write(H5D_io_info_t *io_info, hsize_t nelmts,
HGOTO_ERROR(H5E_DATASET, H5E_CANTGET, FAIL, "chunked write failed in collective mode");
}
else {/* sequential or independent write */
-
+
#endif /* H5_HAVE_PARALLEL */
/* Get first node in chunk skip list */
chunk_node=H5SL_first(fm.fsel);
@@ -2188,14 +2188,14 @@ H5D_create_chunk_map(const H5D_t *dataset, const H5T_t *mem_type, const H5S_t *f
/* calculate total chunk in file map*/
fm->select_chunk = NULL;
fm->total_chunks = 1;
- for(u=0; u<fm->f_ndims; u++)
+ for(u=0; u<fm->f_ndims; u++)
fm->total_chunks= fm->total_chunks*fm->chunks[u];
- if(IS_H5FD_MPI(dataset->oloc.file)) {
+ if(IS_H5FD_MPI(dataset->oloc.file)) {
H5_CHECK_OVERFLOW(fm->total_chunks, hsize_t, size_t);
if(NULL == (fm->select_chunk = (hbool_t *) H5MM_calloc((size_t)fm->total_chunks * sizeof(hbool_t))))
HGOTO_ERROR (H5E_RESOURCE, H5E_NOSPACE, FAIL, "can't allocate chunk info")
}
-
+
@@ -2219,9 +2219,9 @@ H5D_create_chunk_map(const H5D_t *dataset, const H5T_t *mem_type, const H5S_t *f
HGOTO_ERROR (H5E_DATASET, H5E_BADSELECT, FAIL, "unable to convert from file to memory data space")
/* If the selection is NONE or POINTS, set the flag to FALSE */
- if(fsel_type == H5S_SEL_POINTS || fsel_type == H5S_SEL_NONE)
+ if(fsel_type == H5S_SEL_POINTS || fsel_type == H5S_SEL_NONE)
sel_hyper_flag = FALSE;
- else
+ else
sel_hyper_flag = TRUE;
/* Check if file selection is a point selection */
if(!sel_hyper_flag) {
@@ -2487,7 +2487,7 @@ H5D_create_chunk_file_map_hyper(fm_map *fm,const H5D_t *dset)
end[u]=(coords[u]+fm->chunk_dim[u])-1;
} /* end for */
-
+
/* Calculate the index of this chunk */
if(H5V_chunk_index(fm->f_ndims,coords,fm->layout->u.chunk.dim,fm->down_chunks,&chunk_index)<0)
HGOTO_ERROR (H5E_DATASPACE, H5E_BADRANGE, FAIL, "can't get chunk index")
diff --git a/src/H5Distore.c b/src/H5Distore.c
index 2978f72..b479aa0 100644
--- a/src/H5Distore.c
+++ b/src/H5Distore.c
@@ -196,7 +196,7 @@ typedef struct H5D_istore_it_ud4_t {
haddr_t addr_dst; /* Address of dest. B-tree */
void *buf; /* Buffer to hold chunk data for read/write */
size_t buf_size; /* Buffer size */
-
+
/* needed for converting variable-length data */
hid_t tid_src; /* Datatype ID for source datatype */
hid_t tid_dst; /* Datatype ID for destination datatype */
@@ -911,12 +911,12 @@ H5D_istore_iter_chunkmap (H5F_t UNUSED *f, hid_t UNUSED dxpl_id, const void *_lt
int ret_value = H5B_ITER_CONT; /* Return value */
FUNC_ENTER_NOAPI_NOINIT(H5D_istore_iter_chunkmap);
-
+
rank = udata->common.mesg->u.chunk.ndims - 1;
-
+
if(H5V_chunk_index(rank,lt_key->offset,udata->common.mesg->u.chunk.dim,udata->down_chunks,&chunk_index)<0)
HGOTO_ERROR (H5E_DATASPACE, H5E_BADRANGE, FAIL, "can't get chunk index")
-
+
udata->chunk_addr[chunk_index] = addr;
done:
@@ -969,15 +969,15 @@ H5D_istore_iter_dump (H5F_t UNUSED *f, hid_t UNUSED dxpl_id, const void *_lt_key
/*-------------------------------------------------------------------------
- * Function: H5D_istore_iter_copy
+ * Function: H5D_istore_iter_copy
*
- * Purpose: copy chunked raw data from source file and insert to the
+ * Purpose: copy chunked raw data from source file and insert to the
* B-tree node in the destination file
*
* Return: Non-negative on success/Negative on failure
*
- * Programmer: Peter Cao
- * August 20, 2005
+ * Programmer: Peter Cao
+ * August 20, 2005
*
*-------------------------------------------------------------------------
*/
@@ -2446,8 +2446,8 @@ done:
/*-------------------------------------------------------------------------
* Function: H5D_istore_chunkmap
*
- * Purpose: obtain the chunk address and corresponding chunk index
- *
+ * Purpose: obtain the chunk address and corresponding chunk index
+ *
* Return: Success: Non-negative on succeed.
*
* Failure: negative value
@@ -3510,13 +3510,13 @@ done:
* Return: Non-negative on success (with the ISTORE argument initialized
* and ready to write to an object header). Negative on failure.
*
- * Programmer: Peter Cao
- * August 20, 2005
+ * Programmer: Peter Cao
+ * August 20, 2005
*
*-------------------------------------------------------------------------
*/
herr_t
-H5D_istore_copy(H5F_t *f_src, H5O_layout_t *layout_src, H5F_t *f_dst,
+H5D_istore_copy(H5F_t *f_src, H5O_layout_t *layout_src, H5F_t *f_dst,
H5O_layout_t *layout_dst, H5T_t *dt_src, H5O_pline_t *pline, hid_t dxpl_id)
{
H5D_istore_it_ud4_t udata;
diff --git a/src/H5Dmpio.c b/src/H5Dmpio.c
index 7ad8e50..ead1777 100644
--- a/src/H5Dmpio.c
+++ b/src/H5Dmpio.c
@@ -104,29 +104,29 @@ typedef struct H5D_common_coll_info_t {
size_t mpi_buf_count;
haddr_t chunk_addr;
} H5D_common_coll_info_t;
-
+
/********************/
/* Local Prototypes */
/********************/
-static herr_t
-H5D_multi_chunk_collective_io(H5D_io_info_t *io_info,fm_map *fm,const void *buf,
+static herr_t
+H5D_multi_chunk_collective_io(H5D_io_info_t *io_info,fm_map *fm,const void *buf,
hbool_t do_write);
static herr_t
-H5D_link_chunk_collective_io(H5D_io_info_t *io_info,fm_map *fm,const void *buf,
+H5D_link_chunk_collective_io(H5D_io_info_t *io_info,fm_map *fm,const void *buf,
hbool_t do_write,int sum_chunk);
-static herr_t
+static herr_t
H5D_inter_collective_io(H5D_io_info_t *io_info,const H5S_t *file_space,
- const H5S_t *mem_space,haddr_t addr,
+ const H5S_t *mem_space,haddr_t addr,
const void *buf, hbool_t do_write );
-static herr_t
+static herr_t
H5D_final_collective_io(H5D_io_info_t *io_info,MPI_Datatype*mpi_file_type,
MPI_Datatype *mpi_buf_type,
- H5D_common_coll_info_t* coll_info,
+ H5D_common_coll_info_t* coll_info,
const void *buf, hbool_t do_write);
#ifdef OLD_WAY
static herr_t
@@ -134,14 +134,14 @@ H5D_pre_sort_chunk(H5D_io_info_t *io_info,int total_chunks,
haddr_t total_chunk_addr_array[]);
#endif
-static herr_t
+static herr_t
H5D_sort_chunk(H5D_io_info_t * io_info,
fm_map *fm,
H5D_chunk_addr_info_t chunk_addr_info_array[],
int many_chunk_opt);
-static herr_t
-H5D_obtain_mpio_mode(H5D_io_info_t* io_info,
+static herr_t
+H5D_obtain_mpio_mode(H5D_io_info_t* io_info,
fm_map *fm,
uint8_t assign_io_mode[],
haddr_t chunk_addr[]);
@@ -151,7 +151,7 @@ static herr_t H5D_ioinfo_make_coll(H5D_io_info_t *io_info);
static herr_t H5D_mpio_get_min_chunk(const H5D_io_info_t *io_info,
const fm_map *fm, int *min_chunkf);
static int H5D_cmp_chunk_addr(const void *addr1, const void *addr2);
-static herr_t
+static herr_t
H5D_mpio_get_sum_chunk(const H5D_io_info_t *io_info,
const fm_map *fm, int *sum_chunkf);
@@ -284,10 +284,10 @@ done:
* Decription: If H5_MPI_SPECIAL_COLLECTIVE_IO_WORKS is not defined,
collective IO with no contribution from one or more
processes are not assured. We will check the minimum
- number of chunks the process is used. If the number is
+ number of chunks the process is used. If the number is
zero, we will use independent IO mode instead.
This is necessary with Linked chunk IO.
- * Purpose: Checks if it is possible to do collective IO
+ * Purpose: Checks if it is possible to do collective IO
*
* Return: Success: Non-negative: TRUE or FALSE
* Failure: Negative
@@ -307,8 +307,8 @@ H5D_mpio_chunk_adjust_iomode(H5D_io_info_t *io_info, const fm_map *fm) {
#ifndef H5_MPI_SPECIAL_COLLECTIVE_IO_WORKS
if(H5D_mpio_get_min_chunk(io_info,fm,&min_chunk)<0)
- HGOTO_ERROR(H5E_DATASPACE, H5E_CANTSWAP, FAIL, "unable to obtain the min chunk number of all processes");
- if(min_chunk == 0) {
+ HGOTO_ERROR(H5E_DATASPACE, H5E_CANTSWAP, FAIL, "unable to obtain the min chunk number of all processes");
+ if(min_chunk == 0) {
H5P_genplist_t *dx_plist; /* Data transer property list */
/* Get the dataset transfer property list */
@@ -347,11 +347,11 @@ done:
*/
herr_t
H5D_mpio_select_read(H5D_io_info_t *io_info,
- size_t mpi_buf_count,
+ size_t mpi_buf_count,
const size_t UNUSED elmt_size,
- const H5S_t UNUSED *file_space,
+ const H5S_t UNUSED *file_space,
const H5S_t UNUSED *mem_space,
- haddr_t addr,
+ haddr_t addr,
void *buf/*out*/)
{
herr_t ret_value = SUCCEED;
@@ -378,9 +378,9 @@ done:
*/
herr_t
H5D_mpio_select_write(H5D_io_info_t *io_info,
- size_t mpi_buf_count,
+ size_t mpi_buf_count,
const size_t UNUSED elmt_size,
- const H5S_t UNUSED *file_space,
+ const H5S_t UNUSED *file_space,
const H5S_t UNUSED *mem_space,
haddr_t addr,
const void *buf)
@@ -569,8 +569,8 @@ done:
* Function: H5D_contig_collective_io
*
* Purpose: Wrapper Routine for H5D_inter_collective_io
- The starting address of contiguous storage is passed
- *
+ The starting address of contiguous storage is passed
+ *
*
* Return: Non-negative on success/Negative on failure
*
@@ -581,11 +581,11 @@ done:
*-------------------------------------------------------------------------
*/
herr_t
-H5D_contig_collective_io(H5D_io_info_t *io_info,
+H5D_contig_collective_io(H5D_io_info_t *io_info,
const H5S_t *file_space,
const H5S_t *mem_space,
const void *buf,
- hbool_t do_write)
+ hbool_t do_write)
{
@@ -607,8 +607,8 @@ H5D_contig_collective_io(H5D_io_info_t *io_info,
#endif
if(H5D_inter_collective_io(io_info,file_space,mem_space,addr,buf,do_write)<0)
HGOTO_ERROR(H5E_IO, H5E_CANTGET, FAIL,"couldn't finish shared collective MPI-IO");
-
- done:
+
+ done:
FUNC_LEAVE_NOAPI(ret_value)
} /* end H5D_contig_collective_io */
@@ -616,10 +616,10 @@ H5D_contig_collective_io(H5D_io_info_t *io_info,
/*-------------------------------------------------------------------------
* Function: H5D_chunk_collective_io
*
- * Purpose: Routine for
- 1) choose an IO option:
+ * Purpose: Routine for
+ 1) choose an IO option:
a) One collective IO defined by one MPI derived datatype to link through all chunks
- or b) multiple chunk IOs,to do MPI-IO for each chunk, the IO mode may be adjusted
+ or b) multiple chunk IOs,to do MPI-IO for each chunk, the IO mode may be adjusted
due to the selection pattern for each chunk.
* For option a)
1. Sort the chunk address, obtain chunk info according to the sorted chunk address
@@ -633,7 +633,7 @@ H5D_contig_collective_io(H5D_io_info_t *io_info,
2. Depending on whether the IO mode is collective or independent or none,
Create either MPI derived datatype for each chunk to do collective IO or just do independent IO
3. Set up collective IO property list for collective mode
- 4. DO IO
+ 4. DO IO
*
* Return: Non-negative on success/Negative on failure
*
@@ -643,44 +643,44 @@ H5D_contig_collective_io(H5D_io_info_t *io_info,
*
*-------------------------------------------------------------------------
*/
-herr_t
-H5D_chunk_collective_io(H5D_io_info_t *io_info,fm_map *fm,const void *buf, hbool_t do_write)
+herr_t
+H5D_chunk_collective_io(H5D_io_info_t *io_info,fm_map *fm,const void *buf, hbool_t do_write)
{
int io_option = H5D_MULTI_CHUNK_IO_MORE_OPT;
int sum_chunk = 0,mpi_size;
unsigned one_link_chunk_io_threshold;
- H5P_genplist_t *plist;
+ H5P_genplist_t *plist;
H5FD_mpio_chunk_opt_t chunk_opt_mode;
#ifdef H5_HAVE_INSTRUMENTED_LIBRARY
htri_t check_prop,temp_not_link_io = FALSE;
int prop_value,new_value;
#endif
- herr_t ret_value = SUCCEED;
+ herr_t ret_value = SUCCEED;
FUNC_ENTER_NOAPI_NOINIT(H5D_chunk_collective_io)
assert (IS_H5FD_MPIO(io_info->dset->oloc.file));
-
+
/* Obtain the data transfer properties */
if(NULL == (plist = H5I_object(io_info->dxpl_id)))
HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a file access property list")
-
+
/* Check the optional property list on what to do with collective chunk IO. */
chunk_opt_mode=(H5FD_mpio_chunk_opt_t)H5P_peek_unsigned(plist,H5D_XFER_MPIO_CHUNK_OPT_HARD_NAME);
#ifdef KENT
printf("chunk_opt_mode = %d\n",chunk_opt_mode);
#endif
-
+
if(chunk_opt_mode == H5FD_MPIO_CHUNK_ONE_IO) io_option = H5D_ONE_LINK_CHUNK_IO;/*no opt*/
else if(chunk_opt_mode == H5FD_MPIO_CHUNK_MULTI_IO) io_option = H5D_MULTI_CHUNK_IO;/*no opt */
else {
- if(H5D_mpio_get_sum_chunk(io_info,fm,&sum_chunk)<0)
- HGOTO_ERROR(H5E_DATASPACE, H5E_CANTSWAP, FAIL, "unable to obtain the total chunk number of all processes");
+ if(H5D_mpio_get_sum_chunk(io_info,fm,&sum_chunk)<0)
+ HGOTO_ERROR(H5E_DATASPACE, H5E_CANTSWAP, FAIL, "unable to obtain the total chunk number of all processes");
if((mpi_size = H5F_mpi_get_size(io_info->dset->oloc.file))<0)
HGOTO_ERROR (H5E_IO, H5E_MPI, FAIL, "unable to obtain mpi size");
-
+
if(NULL == (plist = H5I_object(io_info->dxpl_id)))
HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a file access property list")
@@ -732,8 +732,8 @@ H5D_chunk_collective_io(H5D_io_info_t *io_info,fm_map *fm,const void *buf, hbool
HGOTO_ERROR(H5E_PLIST, H5E_UNSUPPORTED, FAIL, "unable to get property value");
}
}
-
-
+
+
#endif
#ifndef H5_MPI_COMPLEX_DERIVED_DATATYPE_WORKS
if(io_option == H5D_ONE_LINK_CHUNK_IO ) io_option = H5D_MULTI_CHUNK_IO ;/* We can not do this with one chunk IO. */
@@ -745,9 +745,9 @@ H5D_chunk_collective_io(H5D_io_info_t *io_info,fm_map *fm,const void *buf, hbool
if(H5D_link_chunk_collective_io(io_info,fm,buf,do_write,sum_chunk)<0)
HGOTO_ERROR(H5E_IO, H5E_CANTGET, FAIL,"couldn't finish linked chunk MPI-IO");
}
-
+
else { /*multiple chunk IOs without opt */
-
+
if(H5D_multi_chunk_collective_io(io_info,fm,buf,do_write)<0)
HGOTO_ERROR(H5E_IO, H5E_CANTGET, FAIL,"couldn't finish multiple chunk MPI-IO");
@@ -764,7 +764,7 @@ done:
1. Sort the chunk address and chunk info
2. Build up MPI derived datatype for each chunk
3. Build up the final MPI derived datatype
- 4. Use common collective IO routine to do MPI-IO
+ 4. Use common collective IO routine to do MPI-IO
*
* Return: Non-negative on success/Negative on failure
@@ -788,9 +788,9 @@ H5D_link_chunk_collective_io(H5D_io_info_t *io_info,fm_map *fm,const void *buf,
size_t mpi_buf_count;
size_t mpi_file_count;
hbool_t mbt_is_derived=0, /* Whether the buffer (memory) type is derived and needs to be free'd */
- mft_is_derived=0; /* Whether the file type is derived and needs to be free'd */
-
- int mpi_size,mpi_code; /* MPI return code */
+ mft_is_derived=0; /* Whether the file type is derived and needs to be free'd */
+
+ int mpi_size,mpi_code; /* MPI return code */
int i,num_chunk=0,total_chunks;
size_t ori_num_chunk;
@@ -818,8 +818,8 @@ H5D_link_chunk_collective_io(H5D_io_info_t *io_info,fm_map *fm,const void *buf,
char *bc_percent = NULL;
char *bcc_percent = NULL;
#endif
- herr_t ret_value = SUCCEED;
-
+ herr_t ret_value = SUCCEED;
+
FUNC_ENTER_NOAPI_NOINIT(H5D_link_chunk_collective_io)
ori_total_chunks = fm->total_chunks;
H5_ASSIGN_OVERFLOW(total_chunks,ori_total_chunks,hsize_t,int);
@@ -829,7 +829,7 @@ H5D_link_chunk_collective_io(H5D_io_info_t *io_info,fm_map *fm,const void *buf,
H5SL_node_t *chunk_node;
H5D_chunk_info_t *chunk_info;
H5D_storage_t store;
-
+
chunk_node = H5SL_first(fm->fsel);
if(chunk_node == NULL) {
if(H5D_istore_chunkmap(io_info,total_chunks,&chunk_base_addr,fm->down_chunks)<0)
@@ -846,7 +846,7 @@ H5D_link_chunk_collective_io(H5D_io_info_t *io_info,fm_map *fm,const void *buf,
if(HADDR_UNDEF==(chunk_base_addr = H5D_istore_get_addr(io_info,NULL)))
HGOTO_ERROR(H5E_STORAGE, H5E_CANTGET, FAIL,"couldn't get chunk info from skipped list");
-
+
#ifdef KENT
printf("before inter_collective_io for total chunk = 1 \n");
#endif
@@ -864,7 +864,7 @@ printf("before inter_collective_io for total chunk = 1 \n");
printf("total_chunks = %d\n",(int)total_chunks);
#endif
-
+
if(num_chunk == 0) total_chunk_addr_array = H5MM_malloc(sizeof(haddr_t)*total_chunks);
else
{
@@ -888,12 +888,12 @@ printf("total_chunks = %d\n",(int)total_chunks);
"bc" means 'b-tree iterately obtain all chunk addresses individually',
the default one means 'obtaining the chunk address individually',
*/
-
+
if(bcc_percent=getenv("BCC_PERCENT")){
bsearch_coll_chunk_threshold = atoi(bcc_percent);
assert((bsearch_coll_chunk_threshold >=0) &&(bsearch_coll_chunk_threshold <=100));
}
- else
+ else
bsearch_coll_chunk_threshold = H5D_ALL_CHUNK_ADDR_THRES_COL;
#else
bsearch_coll_chunk_threshold = H5D_ALL_CHUNK_ADDR_THRES_COL; /*This number may be changed according to the performance study */
@@ -902,9 +902,9 @@ printf("total_chunks = %d\n",(int)total_chunks);
if((mpi_size = H5F_mpi_get_size(io_info->dset->oloc.file))<0)
HGOTO_ERROR (H5E_IO, H5E_MPI, FAIL, "unable to obtain mpi size");
- /* Calculate the actual threshold to obtain all chunk addresses collectively
+ /* Calculate the actual threshold to obtain all chunk addresses collectively
The bigger this number is, the more possible the use of obtaining chunk address collectively. */
- /* For non-optimization one-link IO,
+ /* For non-optimization one-link IO,
actual bsearch threshold is always 0,
we would always want to obtain the chunk addresses individually
for each process. */
@@ -921,7 +921,7 @@ printf("total_chunks = %d\n",(int)total_chunks);
bsearch_chunk_ratio = atoi(bc_percent);
assert((bsearch_chunk_ratio<=100)&&(bsearch_chunk_ratio>=0));
}
- else
+ else
bsearch_chunk_ratio = H5D_ALL_CHUNK_ADDR_THRES_IND;
#else
bsearch_chunk_ratio = H5D_ALL_CHUNK_ADDR_THRES_IND; /*This number may be changed according to the performance study */
@@ -931,20 +931,20 @@ printf("total_chunks = %d\n",(int)total_chunks);
The unit of the threshold is the number of chunks. The value should be at least 1.
It can be calculated as follows:
- if(total_chunks*bsearch_chunk_ratio/100 <=1)
+ if(total_chunks*bsearch_chunk_ratio/100 <=1)
bsearch_chunk_threahold = 1;
- else
+ else
bsearch_chunk_threshold = total_chunks*bsearch_chunk_ratio/100;
- In order to make the caluculation more efficient,
+ In order to make the caluculation more efficient,
we use the following approximate formula to calculate the threshold.
bsearch_chunk_threshold = 1+ (total_chunks*bsearch_chunk_ratio-99)/100;
The only difference is when total_chunks* besearch_chunk_ratio == 100n+99;
- the approximate formula will give value (n+1) instead of n for threshold.
+ the approximate formula will give value (n+1) instead of n for threshold.
That shouldn't matter much from our persective.
- */
-
+ */
+
bsearch_chunk_threshold = 1 +(total_chunks*bsearch_chunk_ratio-99)/100;
if(num_chunk > bsearch_chunk_threshold) many_chunk_opt = H5D_OBTAIN_ALL_CHUNK_ADDR_IND;
if((sum_chunk == 0) && (total_chunks >= H5D_ALL_CHUNK_ADDR_THRES_IND_NUM))
@@ -953,14 +953,14 @@ printf("total_chunks = %d\n",(int)total_chunks);
#ifdef KENT
printf("before sorting the chunk address \n");
#endif
- /* Sort the chunk address
+ /* Sort the chunk address
when chunk optimization selection is either H5D_OBTAIN_*/
if(num_chunk == 0){ /* special case: this process doesn't select anything */
if(H5D_istore_chunkmap(io_info,total_chunks,total_chunk_addr_array,fm->down_chunks)<0)
HGOTO_ERROR(H5E_DATASET, H5E_CANTGET, FAIL, "can't get chunk address");
chunk_base_addr = total_chunk_addr_array[0];
}
-
+
else {
if(H5D_sort_chunk(io_info,fm,chunk_addr_info_array,many_chunk_opt)<0)
HGOTO_ERROR (H5E_DATASPACE, H5E_CANTSWAP, FAIL, "unable to sort chunk address");
@@ -969,8 +969,8 @@ printf("before sorting the chunk address \n");
#ifdef KENT
printf("after sorting the chunk address \n");
#endif
-
- /* Obtain MPI derived datatype from all individual chunks */
+
+ /* Obtain MPI derived datatype from all individual chunks */
for ( i = 0; i < num_chunk; i++) {
/* Disk MPI derived datatype */
if(H5S_mpio_space_type(chunk_addr_info_array[i].chunk_info.fspace,src_type_size,&chunk_ftype[i],
@@ -981,7 +981,7 @@ printf("after sorting the chunk address \n");
if(H5S_mpio_space_type(chunk_addr_info_array[i].chunk_info.mspace,dst_type_size,&chunk_mtype[i],
&mpi_buf_count,&mpi_buf_extra_offset,&mbt_is_derived)<0)
HGOTO_ERROR(H5E_DATASPACE, H5E_BADTYPE, FAIL,"couldn't create MPI buf type");
-
+
/* Chunk address relative to the first chunk */
chunk_addr_info_array[i].chunk_addr -= chunk_base_addr;
H5_ASSIGN_OVERFLOW(chunk_disp_array[i],chunk_addr_info_array[i].chunk_addr,haddr_t,MPI_Aint);
@@ -989,7 +989,7 @@ printf("after sorting the chunk address \n");
blocklen_value = 1;
if(num_chunk){
-
+
/* initialize the buffer with the constant value 1 */
H5V_array_fill(blocklen,&blocklen_value,sizeof(int),(size_t)num_chunk);
@@ -1022,7 +1022,7 @@ printf("after sorting the chunk address \n");
else {/* no selection at all for this process */
chunk_final_ftype = MPI_BYTE;
chunk_final_mtype = MPI_BYTE;
-
+
/* buffer, file derived datatypes should be true */
coll_info.mbt_is_derived = 0;
coll_info.mft_is_derived = 0;
@@ -1032,7 +1032,7 @@ printf("after sorting the chunk address \n");
#ifdef KENT
printf("before coming to final collective IO\n");
#endif
-
+
if(H5D_final_collective_io(io_info,&chunk_final_ftype,&chunk_final_mtype,&coll_info,buf,do_write)<0)
HGOTO_ERROR(H5E_IO, H5E_CANTGET, FAIL,"couldn't finish MPI-IO");
@@ -1042,7 +1042,7 @@ printf("before freeing memory inside H5D_link_collective_io ret_value = %d\n",r
#endif
-
+
if (fm->total_chunks != 1) {
if(num_chunk == 0) HDfree(total_chunk_addr_array);
else {
@@ -1072,7 +1072,7 @@ printf("before leaving H5D_link_collective_io ret_value = %d\n",ret_value);
1. Use MPI_gather and MPI_Bcast to obtain IO mode in each chunk(collective/independent/none)
2. Depending on whether the IO mode is collective or independent or none,
Create either MPI derived datatype for each chunk or just do independent IO
- 3. Use common collective IO routine to do MPI-IO
+ 3. Use common collective IO routine to do MPI-IO
*
* Return: Non-negative on success/Negative on failure
*
@@ -1082,8 +1082,8 @@ printf("before leaving H5D_link_collective_io ret_value = %d\n",ret_value);
*
*-------------------------------------------------------------------------
*/
-static herr_t
-H5D_multi_chunk_collective_io(H5D_io_info_t *io_info,fm_map *fm,const void *buf, hbool_t do_write)
+static herr_t
+H5D_multi_chunk_collective_io(H5D_io_info_t *io_info,fm_map *fm,const void *buf, hbool_t do_write)
{
int i,total_chunk;
@@ -1096,7 +1096,7 @@ H5D_multi_chunk_collective_io(H5D_io_info_t *io_info,fm_map *fm,const void *buf,
H5D_storage_t store; /* union of EFL and chunk pointer in file space */
hbool_t select_chunk;
hbool_t last_io_mode_coll = TRUE;
- herr_t ret_value = SUCCEED;
+ herr_t ret_value = SUCCEED;
#ifdef KENT
int mpi_rank;
#endif
@@ -1117,7 +1117,7 @@ H5D_multi_chunk_collective_io(H5D_io_info_t *io_info,fm_map *fm,const void *buf,
#endif
/* obtain IO option for each chunk */
- if(H5D_obtain_mpio_mode(io_info,fm,chunk_io_option,chunk_addr)<0)
+ if(H5D_obtain_mpio_mode(io_info,fm,chunk_io_option,chunk_addr)<0)
HGOTO_ERROR (H5E_DATASET, H5E_CANTRECV, FAIL, "unable to obtain MPIO mode");
for( i = 0; i<total_chunk;i++){
@@ -1140,7 +1140,7 @@ printf("mpi_rank = %d, chunk index = %d\n",mpi_rank,i);
if(NULL ==(chunk_node = H5SL_first(fm->fsel)))
HGOTO_ERROR(H5E_STORAGE, H5E_CANTGET, FAIL,"couldn't get chunk node from skipped list");
#else
-
+
if(NULL ==(chunk_node = H5SL_first(fm->fsel)))
HGOTO_ERROR(H5E_STORAGE, H5E_CANTGET, FAIL,"couldn't get chunk node from skipped list");
while(chunk_node){
@@ -1161,30 +1161,30 @@ printf("mpi_rank = %d, chunk index = %d\n",mpi_rank,i);
#endif
}
- if(chunk_io_option[i] == 1){ /*collective IO for this chunk,
+ if(chunk_io_option[i] == 1){ /*collective IO for this chunk,
note: even there is no selection for this process,
the process still needs to contribute MPI NONE TYPE.*/
#ifdef KENT
printf("inside collective chunk IO mpi_rank = %d, chunk index = %d\n",mpi_rank,i);
#endif
-
+
if(!last_io_mode_coll)
/* Switch back to collective I/O */
if(H5D_ioinfo_make_coll(io_info) < 0)
HGOTO_ERROR(H5E_DATASET, H5E_CANTGET, FAIL, "can't switch to collective I/O")
-
+
if(select_chunk){
if(H5D_inter_collective_io(io_info,chunk_info->fspace,chunk_info->mspace,
chunk_addr[i],buf,do_write )<0)
HGOTO_ERROR(H5E_IO, H5E_CANTGET, FAIL,"couldn't finish shared collective MPI-IO");
-
+
}
else{
if(H5D_inter_collective_io(io_info,NULL,NULL,
chunk_addr[i],buf,do_write )<0)
HGOTO_ERROR(H5E_IO, H5E_CANTGET, FAIL,"couldn't finish shared collective MPI-IO");
-
- }
+
+ }
last_io_mode_coll = TRUE;
}
@@ -1192,7 +1192,7 @@ printf("inside collective chunk IO mpi_rank = %d, chunk index = %d\n",mpi_rank,i
#ifdef KENT
printf("inside independent IO mpi_rank = %d, chunk index = %d\n",mpi_rank,i);
#endif
-
+
HDassert(chunk_io_option[i] == 0);
if(!select_chunk) continue; /* this process has nothing to do with this chunk, continue! */
if(last_io_mode_coll)
@@ -1206,16 +1206,16 @@ printf("inside independent IO mpi_rank = %d, chunk index = %d\n",mpi_rank,i);
chunk_info->fspace,chunk_info->mspace,0,
buf);
/* Check return value of the write */
- if (ret_value<0)
+ if (ret_value<0)
HGOTO_ERROR(H5E_DATASET, H5E_WRITEERROR, FAIL, "optimized write failed")
}
else {
ret_value = (io_info->ops.read)(io_info,
chunk_info->chunk_points,H5T_get_size(io_info->dset->shared->type),
chunk_info->fspace,chunk_info->mspace,0,
- buf);
+ buf);
/* Check return value from optimized write */
- if (ret_value<0)
+ if (ret_value<0)
HGOTO_ERROR(H5E_DATASET, H5E_READERROR, FAIL, "optimized read failed")
}
@@ -1241,7 +1241,7 @@ printf("inside independent IO mpi_rank = %d, chunk index = %d\n",mpi_rank,i);
*
* Purpose: Routine for the shared part of collective IO between multiple chunk
collective IO and contiguous collective IO
-
+
*
* Return: Non-negative on success/Negative on failure
*
@@ -1251,16 +1251,16 @@ printf("inside independent IO mpi_rank = %d, chunk index = %d\n",mpi_rank,i);
*
*-------------------------------------------------------------------------
*/
-static herr_t
+static herr_t
H5D_inter_collective_io(H5D_io_info_t *io_info,const H5S_t *file_space,const H5S_t *mem_space,
- haddr_t addr, const void *buf, hbool_t do_write )
+ haddr_t addr, const void *buf, hbool_t do_write )
{
size_t mpi_buf_count, mpi_file_count; /* Number of "objects" to transfer */
MPI_Datatype mpi_file_type,mpi_buf_type;
hsize_t mpi_buf_offset, mpi_file_offset; /* Offset within dataset where selection (ie. MPI type) begins */
hbool_t mbt_is_derived=0, /* Whether the buffer (memory) type is derived and needs to be free'd */
- mft_is_derived=0; /* Whether the file type is derived and needs to be free'd */
+ mft_is_derived=0; /* Whether the file type is derived and needs to be free'd */
H5D_common_coll_info_t coll_info;
herr_t ret_value = SUCCEED; /* return value */
@@ -1274,11 +1274,11 @@ H5D_inter_collective_io(H5D_io_info_t *io_info,const H5S_t *file_space,const H5S
if(H5S_mpio_space_type(mem_space,H5T_get_size(io_info->dset->shared->type),
&mpi_buf_type,&mpi_buf_count,&mpi_buf_offset,&mbt_is_derived)<0)
HGOTO_ERROR(H5E_DATASPACE, H5E_BADTYPE, FAIL,"couldn't create MPI buffer type");
-
+
}
else {
/* For non-selection, participate with a none MPI derived datatype, the count is 0. */
- mpi_buf_type = MPI_BYTE;
+ mpi_buf_type = MPI_BYTE;
mpi_file_type = MPI_BYTE;
mpi_file_count = 0;
mpi_buf_count = 0;
@@ -1305,7 +1305,7 @@ printf("before leaving inter_collective_io ret_value = %d\n",ret_value);
* Function: H5D_final_collective_io
*
* Purpose: Routine for the common part of collective IO with different storages.
-
+
*
* Return: Non-negative on success/Negative on failure
*
@@ -1315,13 +1315,13 @@ printf("before leaving inter_collective_io ret_value = %d\n",ret_value);
*
*-------------------------------------------------------------------------
*/
-static herr_t
+static herr_t
H5D_final_collective_io(H5D_io_info_t *io_info,MPI_Datatype*mpi_file_type,MPI_Datatype *mpi_buf_type,
- H5D_common_coll_info_t* coll_info, const void *buf, hbool_t do_write)
+ H5D_common_coll_info_t* coll_info, const void *buf, hbool_t do_write)
{
- int mpi_code; /* MPI return code */
+ int mpi_code; /* MPI return code */
hbool_t plist_is_setup=0; /* Whether the dxpl has been customized */
herr_t ret_value = SUCCEED;
@@ -1338,7 +1338,7 @@ H5D_final_collective_io(H5D_io_info_t *io_info,MPI_Datatype*mpi_file_type,MPI_Da
plist_is_setup=1;
#ifdef KENT
HDfprintf(stdout,"chunk addr %Hu\n",coll_info->chunk_addr);
- printf("mpi_buf_count %d\n",coll_info->mpi_buf_count);
+ printf("mpi_buf_count %d\n",coll_info->mpi_buf_count);
#endif
if(do_write) {
ret_value = (io_info->ops.write)(io_info,
@@ -1348,7 +1348,7 @@ H5D_final_collective_io(H5D_io_info_t *io_info,MPI_Datatype*mpi_file_type,MPI_Da
#ifdef KENT
printf("ret_value after final collective IO= %d\n",ret_value);
#endif
- if (ret_value<0)
+ if (ret_value<0)
HGOTO_ERROR(H5E_DATASET, H5E_WRITEERROR, FAIL, "optimized write failed")
}
else {
@@ -1356,11 +1356,11 @@ H5D_final_collective_io(H5D_io_info_t *io_info,MPI_Datatype*mpi_file_type,MPI_Da
coll_info->mpi_buf_count,0,NULL,NULL,coll_info->chunk_addr,
buf);
/* Check return value from optimized write */
- if (ret_value<0)
+ if (ret_value<0)
HGOTO_ERROR(H5E_DATASET, H5E_READERROR, FAIL, "optimized read failed")
}
done:
-
+
/* Reset the dxpl settings */
if(plist_is_setup) {
if(H5FD_mpi_teardown_collective(io_info->dxpl_id)<0)
@@ -1371,7 +1371,7 @@ H5D_final_collective_io(H5D_io_info_t *io_info,MPI_Datatype*mpi_file_type,MPI_Da
if (coll_info->mbt_is_derived) {
if (MPI_SUCCESS != (mpi_code= MPI_Type_free( mpi_buf_type )))
HMPI_DONE_ERROR(FAIL, "MPI_Type_free failed", mpi_code);
-
+
}
if (coll_info->mft_is_derived) {
if (MPI_SUCCESS != (mpi_code= MPI_Type_free( mpi_file_type )))
@@ -1392,7 +1392,7 @@ H5D_final_collective_io(H5D_io_info_t *io_info,MPI_Datatype*mpi_file_type,MPI_Da
Description:
root will collective all chunk addresses and broadcast towards other processes.
-
+
Parameters:
Input: H5D_io_info_t* io_info,
@@ -1430,7 +1430,7 @@ H5D_pre_sort_chunk(H5D_io_info_t *io_info,int total_chunks,haddr_t total_chunk_a
if(MPI_SUCCESS != (mpi_code = MPI_Type_commit(&chunk_addrtype)))
HMPI_GOTO_ERROR(FAIL, "MPI_Type_commit failed", mpi_code);
-
+
mpi_type_cleanup = 1;
if(mpi_rank == root) {
@@ -1441,7 +1441,7 @@ H5D_pre_sort_chunk(H5D_io_info_t *io_info,int total_chunks,haddr_t total_chunk_a
/* Broadcasting the MPI_IO option info. and chunk address info. */
if(MPI_SUCCESS !=(mpi_code = MPI_Bcast(total_chunk_addr_array,1,chunk_addrtype,root,comm)))
HMPI_GOTO_ERROR(FAIL, "MPI_BCast failed", mpi_code);
-
+
done:
if(mpi_type_cleanup){
@@ -1462,12 +1462,12 @@ done:
For most cases, the chunk address has already been sorted in increasing order.
The special sorting flag is used to optimize this common case.
quick sort is used for necessary sorting.
-
+
Parameters:
Input: H5D_io_info_t* io_info,
fm_map *fm(global chunk map struct)
- Input/Output: H5D_chunk_addr_info_t chunk_addr_info_array[] : array to store chunk address and information
- many_chunk_opt : flag to optimize the way to obtain chunk addresses
+ Input/Output: H5D_chunk_addr_info_t chunk_addr_info_array[] : array to store chunk address and information
+ many_chunk_opt : flag to optimize the way to obtain chunk addresses
for many chunks
*
* Return: Non-negative on success/Negative on failure
@@ -1479,7 +1479,7 @@ done:
*-------------------------------------------------------------------------
*/
-static herr_t
+static herr_t
H5D_sort_chunk(H5D_io_info_t * io_info,
fm_map *fm,
H5D_chunk_addr_info_t chunk_addr_info_array[],
@@ -1500,7 +1500,7 @@ H5D_sort_chunk(H5D_io_info_t * io_info,
H5D_storage_t store; /*union of EFL and chunk pointer in file space */
hbool_t do_sort = FALSE;
herr_t ret_value = SUCCEED; /*return value */
-
+
FUNC_ENTER_NOAPI_NOINIT(H5D_sort_chunk)
num_chunks = H5SL_count(fm->fsel);
@@ -1563,7 +1563,7 @@ printf("Coming inside H5D_OBTAIN_ALL_CHUNK_ADDR_COL\n");
if(HADDR_UNDEF==(chunk_addr = H5D_istore_get_addr(io_info,NULL)))
HGOTO_ERROR(H5E_STORAGE, H5E_CANTGET, FAIL,"couldn't get chunk info from skipped list");
}
- else
+ else
chunk_addr = total_chunk_addr_array[chunk_info->index];
chunk_addr_info_array[i].chunk_addr = chunk_addr;
chunk_addr_info_array[i].chunk_info = *chunk_info;
@@ -1574,12 +1574,12 @@ printf("Coming inside H5D_OBTAIN_ALL_CHUNK_ADDR_COL\n");
chunk_info = H5SL_item(chunk_node);
store.chunk.offset = chunk_info->coords;
store.chunk.index = chunk_info->index;
-
+
if(many_chunk_opt == H5D_OBTAIN_ONE_CHUNK_ADDR_IND){
if(HADDR_UNDEF==(chunk_addr = H5D_istore_get_addr(io_info,NULL)))
HGOTO_ERROR(H5E_STORAGE, H5E_CANTGET, FAIL,"couldn't get chunk info from skipped list");
}
- else
+ else
chunk_addr = total_chunk_addr_array[chunk_info->index];
if(chunk_addr < chunk_addr_info_array[i].chunk_addr) do_sort = TRUE;
@@ -1605,7 +1605,7 @@ done:
}
FUNC_LEAVE_NOAPI(ret_value)
} /* end H5D_sort_chunk() */
-
+
/*-------------------------------------------------------------------------
* Function: H5D_obtain_mpio_mode
@@ -1616,11 +1616,11 @@ done:
Description:
1) Each process provides two piece of information for all chunks with selection
- a) chunk index
+ a) chunk index
b) wheather this chunk is regular(for MPI derived datatype not working case)
2) Gather all the information to the root process
-
+
3) Root process will do the following:
a) Obtain chunk address for all chunks in this data space
b) With the consideration of the user option, calculate IO mode for each chunk
@@ -1628,7 +1628,7 @@ done:
in order to do MPI Bcast only once
d) MPI Bcast the IO mode and chunk address information for each chunk.
4) Each process then retrieves IO mode and chunk address information to assign_io_mode and chunk_addr.
-
+
Parameters:
Input: H5D_io_info_t* io_info,
@@ -1645,8 +1645,8 @@ done:
*-------------------------------------------------------------------------
*/
-static herr_t
-H5D_obtain_mpio_mode(H5D_io_info_t* io_info,
+static herr_t
+H5D_obtain_mpio_mode(H5D_io_info_t* io_info,
fm_map *fm,
uint8_t assign_io_mode[],
haddr_t chunk_addr[])
@@ -1661,7 +1661,7 @@ H5D_obtain_mpio_mode(H5D_io_info_t* io_info,
uint8_t* mergebuf=NULL;
uint8_t* tempbuf;
- H5SL_node_t* chunk_node;
+ H5SL_node_t* chunk_node;
H5D_chunk_info_t* chunk_info;
MPI_Datatype bastype[2];
@@ -1688,7 +1688,7 @@ H5D_obtain_mpio_mode(H5D_io_info_t* io_info,
FUNC_ENTER_NOAPI_NOINIT(H5D_obtain_mpio_mode)
/* Assign the rank 0 to the root */
- root = 0;
+ root = 0;
comm = io_info->comm;
/* Obtain the number of process and the current rank of the process */
@@ -1696,7 +1696,7 @@ H5D_obtain_mpio_mode(H5D_io_info_t* io_info,
HGOTO_ERROR (H5E_IO, H5E_MPI, FAIL, "unable to obtain mpi rank");
if((mpi_size = H5F_mpi_get_size(io_info->dset->oloc.file))<0)
HGOTO_ERROR (H5E_IO, H5E_MPI, FAIL, "unable to obtain mpi size");
-
+
/* Allocate memory */
ori_total_chunks = fm->total_chunks;
H5_ASSIGN_OVERFLOW(total_chunks,ori_total_chunks,hsize_t,int);
@@ -1704,30 +1704,30 @@ H5D_obtain_mpio_mode(H5D_io_info_t* io_info,
/* Obtain the data transfer properties */
if(NULL == (plist = H5I_object(io_info->dxpl_id)))
HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a file access property list")
-
+
percent_nproc_per_chunk=H5P_peek_unsigned(plist,H5D_XFER_MPIO_CHUNK_OPT_RATIO_NAME);
#if defined(H5_MPI_COMPLEX_DERIVED_DATATYPE_WORKS) && defined(H5_MPI_SPECIAL_COLLECTIVE_IO_WORKS)
-
+
chunk_opt_mode=(H5FD_mpio_chunk_opt_t)H5P_peek_unsigned(plist,H5D_XFER_MPIO_CHUNK_OPT_HARD_NAME);
if((chunk_opt_mode == H5FD_MPIO_CHUNK_MULTI_IO) || (percent_nproc_per_chunk == 0)){
if(H5D_istore_chunkmap(io_info,total_chunks,chunk_addr,fm->down_chunks)<0)
- HGOTO_ERROR(H5E_DATASET, H5E_CANTGET, FAIL, "can't get chunk address");
+ HGOTO_ERROR(H5E_DATASET, H5E_CANTGET, FAIL, "can't get chunk address");
for(ic = 0; ic<total_chunks;ic++)
assign_io_mode[ic] = H5D_CHUNK_IO_MODE_COL;
goto done;
}
-#endif
+#endif
threshold_nproc_per_chunk = mpi_size * percent_nproc_per_chunk/100;
io_mode_info = (uint8_t *)H5MM_calloc(total_chunks*sizeof(MPI_BYTE));
mergebuf = H5MM_malloc((sizeof(haddr_t)+sizeof(MPI_BYTE))*total_chunks);
tempbuf = mergebuf + sizeof(MPI_BYTE)*total_chunks;
- if(mpi_rank == root)
+ if(mpi_rank == root)
recv_io_mode_info = (uint8_t *)H5MM_malloc(total_chunks*sizeof(MPI_BYTE)*mpi_size);
-
+
mem_cleanup = 1;
chunk_node = H5SL_first(fm->fsel);
@@ -1750,7 +1750,7 @@ H5D_obtain_mpio_mode(H5D_io_info_t* io_info,
chunk_node = H5SL_next(chunk_node);
}
-
+
/*Create sent MPI derived datatype */
if(MPI_SUCCESS !=(mpi_code = MPI_Type_contiguous(total_chunks,MPI_BYTE,&stype)))
HMPI_GOTO_ERROR(FAIL, "MPI_Comm_rank failed", mpi_code);
@@ -1764,7 +1764,7 @@ H5D_obtain_mpio_mode(H5D_io_info_t* io_info,
basdisp[0] = 0;
basdisp[1] = (MPI_Aint)(sizeof(MPI_BYTE)*total_chunks);/* may need to check overflow */
bastype[0] = MPI_BYTE;
-
+
if(MPI_SUCCESS !=(mpi_code = MPI_Type_contiguous(sizeof(haddr_t),MPI_BYTE,&chunk_addrtype)))
HMPI_GOTO_ERROR(FAIL, "MPI_Type_contiguous failed", mpi_code);
if(MPI_SUCCESS != (mpi_code = MPI_Type_commit(&chunk_addrtype)))
@@ -1792,7 +1792,7 @@ H5D_obtain_mpio_mode(H5D_io_info_t* io_info,
int* ind_this_chunk;
#endif
- /* pre-computing: calculate number of processes and
+ /* pre-computing: calculate number of processes and
regularity of the selection occupied in each chunk */
nproc_per_chunk = (int*)H5MM_calloc(total_chunks*sizeof(int));
#if !defined(H5_MPI_COMPLEX_DERIVED_DATATYPE_WORKS) || !defined(H5_MPI_SPECIAL_COLLECTIVE_IO_WORKS)
@@ -1866,7 +1866,7 @@ H5D_obtain_mpio_mode(H5D_io_info_t* io_info,
new_value = 0;
if(H5Pset(io_info->dxpl_id,H5D_XFER_COLL_CHUNK_MULTI_RATIO_COLL_NAME,&new_value)<0)
HGOTO_ERROR(H5E_PLIST, H5E_UNSUPPORTED, FAIL, "unable to set property value");
-#else
+#else
for(ic = 0; ic < total_chunks; ic++){
if(assign_io_mode[ic] == H5D_CHUNK_IO_MODE_COL) {
new_value = 0;
@@ -1893,7 +1893,7 @@ H5D_obtain_mpio_mode(H5D_io_info_t* io_info,
}
}
#endif
-
+
done:
if(mpi_type_cleanup) {
@@ -1910,7 +1910,7 @@ done:
if(mem_cleanup){
HDfree(io_mode_info);
HDfree(mergebuf);
- if(mpi_rank == root)
+ if(mpi_rank == root)
HDfree(recv_io_mode_info);
}
@@ -1923,7 +1923,7 @@ H5D_cmp_chunk_addr(const void *chunk_addr_info1, const void *chunk_addr_info2)
haddr_t addr1, addr2;
FUNC_ENTER_NOAPI_NOINIT(H5D_cmp_chunk_addr)
-
+
addr1 = ((const H5D_chunk_addr_info_t *)chunk_addr_info1)->chunk_addr;
addr2 = ((const H5D_chunk_addr_info_t *)chunk_addr_info2)->chunk_addr;
diff --git a/src/H5Doh.c b/src/H5Doh.c
index 4da2381..ff42659 100644
--- a/src/H5Doh.c
+++ b/src/H5Doh.c
@@ -173,7 +173,7 @@ H5O_dset_free_copy_file_udata(void *_udata)
H5T_close(udata->src_dtype);
/* Release copy of dataset's filter pipeline, if it was set */
- if (udata->src_pline)
+ if (udata->src_pline)
H5O_free(H5O_PLINE_ID, udata->src_pline);
/* Release space for 'copy file' user data */
diff --git a/src/H5E.c b/src/H5E.c
index f7519bb..a891ee8 100644
--- a/src/H5E.c
+++ b/src/H5E.c
@@ -108,7 +108,7 @@ static ssize_t H5E_get_num(const H5E_t *err_stack);
static herr_t H5E_pop(H5E_t *err_stack, size_t count);
static herr_t H5E_clear_entries(H5E_t *estack, size_t nentries);
static herr_t H5E_print_stack(const H5E_t *estack, FILE *stream, hbool_t bk_compatible);
-static herr_t H5E_walk_stack(const H5E_t *estack, H5E_direction_t direction, H5E_walk_t func,
+static herr_t H5E_walk_stack(const H5E_t *estack, H5E_direction_t direction, H5E_walk_t func,
H5E_walk_stack_t stack_func, hbool_t bk_compatible, void *client_data);
static herr_t H5E_walk_cb(unsigned n, const H5E_error_t *err_desc, void *client_data);
static herr_t H5E_walk_stack_cb(unsigned n, const H5E_error_stack_t *err_desc, void *client_data);
@@ -1991,7 +1991,7 @@ H5E_print_stack(const H5E_t *estack, FILE *stream, hbool_t bk_compatible)
if(bk_compatible) {
if(H5E_walk_stack(estack, H5E_WALK_DOWNWARD, H5E_walk_cb, NULL, TRUE, (void*)&eprint)<0)
HGOTO_ERROR(H5E_ERROR, H5E_CANTLIST, FAIL, "can't walk error stack")
- } else {
+ } else {
if(H5E_walk_stack(estack, H5E_WALK_DOWNWARD, NULL, H5E_walk_stack_cb, FALSE, (void*)&eprint)<0)
HGOTO_ERROR(H5E_ERROR, H5E_CANTLIST, FAIL, "can't walk error stack")
}
@@ -2102,16 +2102,16 @@ done:
* means to start at the API and end at the inner-most function
* where the error was first detected.
*
- * The function pointed to by STACK_FUNC will be called for
- * each error record in the error stack. It's arguments will
- * include an index number (beginning at zero regardless of
- * stack traversal direction), an error stack entry, and the
+ * The function pointed to by STACK_FUNC will be called for
+ * each error record in the error stack. It's arguments will
+ * include an index number (beginning at zero regardless of
+ * stack traversal direction), an error stack entry, and the
* CLIENT_DATA pointer passed to H5E_print_stack.
*
* The function FUNC is also provided for backward compatibility.
* When BK_COMPATIBLE is set to be TRUE, FUNC is used to be
* compatible with older library. If BK_COMPATIBLE is FALSE,
- * STACK_FUNC is used.
+ * STACK_FUNC is used.
*
* Return: Non-negative on success/Negative on failure
*
@@ -2126,13 +2126,13 @@ done:
*
* Raymond Lu
* Friday, May 12, 2006
- * Added backward compatibility support. FUNC is for older
+ * Added backward compatibility support. FUNC is for older
* library; STACK_FUNC is for new library.
*
*-------------------------------------------------------------------------
*/
static herr_t
-H5E_walk_stack(const H5E_t *estack, H5E_direction_t direction, H5E_walk_t func, H5E_walk_stack_t stack_func,
+H5E_walk_stack(const H5E_t *estack, H5E_direction_t direction, H5E_walk_t func, H5E_walk_stack_t stack_func,
hbool_t bk_compatible, void *client_data)
{
int i; /* Local index variable */
@@ -2216,9 +2216,9 @@ done:
* Purpose: This is a default error stack traversal callback function
* that prints error messages to the specified output stream.
* It is not meant to be called directly but rather as an
- * argument to the H5Ewalk_stack() function. This function is
- * called also by H5Eprint_stack(). Application writers are
- * encouraged to use this function as a model for their own
+ * argument to the H5Ewalk_stack() function. This function is
+ * called also by H5Eprint_stack(). Application writers are
+ * encouraged to use this function as a model for their own
* error stack walking functions.
*
* N is a counter for how many times this function has been
@@ -2351,7 +2351,7 @@ H5E_walk_stack_cb(unsigned n, const H5E_error_stack_t *err_desc, void *client_da
*
* Return: Non-negative on success/Negative on failure
*
- * Programmer: Raymond Lu
+ * Programmer: Raymond Lu
* Thursday, May 11, 2006
*
* Modifications:
diff --git a/src/H5Eterm.h b/src/H5Eterm.h
index c2c206e..0b3a85e 100644
--- a/src/H5Eterm.h
+++ b/src/H5Eterm.h
@@ -20,180 +20,180 @@
#define _H5Eterm_H
/* Reset major error IDs */
-
-H5E_DATASET_g=
-H5E_FUNC_g=
-H5E_STORAGE_g=
-H5E_FILE_g=
-H5E_SYM_g=
-H5E_VFL_g=
-H5E_INTERNAL_g=
-H5E_BTREE_g=
-H5E_REFERENCE_g=
-H5E_DATASPACE_g=
-H5E_RESOURCE_g=
-H5E_PLIST_g=
-H5E_DATATYPE_g=
-H5E_RS_g=
-H5E_HEAP_g=
-H5E_OHDR_g=
-H5E_ATOM_g=
-H5E_ATTR_g=
-H5E_NONE_MAJOR_g=
-H5E_IO_g=
-H5E_SLIST_g=
-H5E_EFL_g=
-H5E_TST_g=
-H5E_ARGS_g=
-H5E_ERROR_g=
-H5E_PLINE_g=
-H5E_FSPACE_g=
+
+H5E_DATASET_g=
+H5E_FUNC_g=
+H5E_STORAGE_g=
+H5E_FILE_g=
+H5E_SYM_g=
+H5E_VFL_g=
+H5E_INTERNAL_g=
+H5E_BTREE_g=
+H5E_REFERENCE_g=
+H5E_DATASPACE_g=
+H5E_RESOURCE_g=
+H5E_PLIST_g=
+H5E_DATATYPE_g=
+H5E_RS_g=
+H5E_HEAP_g=
+H5E_OHDR_g=
+H5E_ATOM_g=
+H5E_ATTR_g=
+H5E_NONE_MAJOR_g=
+H5E_IO_g=
+H5E_SLIST_g=
+H5E_EFL_g=
+H5E_TST_g=
+H5E_ARGS_g=
+H5E_ERROR_g=
+H5E_PLINE_g=
+H5E_FSPACE_g=
H5E_CACHE_g= (-1);
/* Reset minor error IDs */
-/* Generic low-level file I/O errors */
-H5E_SEEKERROR_g=
-H5E_READERROR_g=
-H5E_WRITEERROR_g=
-H5E_CLOSEERROR_g=
-H5E_OVERFLOW_g=
+/* Generic low-level file I/O errors */
+H5E_SEEKERROR_g=
+H5E_READERROR_g=
+H5E_WRITEERROR_g=
+H5E_CLOSEERROR_g=
+H5E_OVERFLOW_g=
H5E_FCNTL_g=
-/* Resource errors */
-H5E_NOSPACE_g=
-H5E_CANTALLOC_g=
-H5E_CANTCOPY_g=
-H5E_CANTFREE_g=
-H5E_ALREADYEXISTS_g=
-H5E_CANTLOCK_g=
-H5E_CANTUNLOCK_g=
-H5E_CANTGC_g=
+/* Resource errors */
+H5E_NOSPACE_g=
+H5E_CANTALLOC_g=
+H5E_CANTCOPY_g=
+H5E_CANTFREE_g=
+H5E_ALREADYEXISTS_g=
+H5E_CANTLOCK_g=
+H5E_CANTUNLOCK_g=
+H5E_CANTGC_g=
H5E_CANTGETSIZE_g=
-/* Heap errors */
-H5E_CANTRESTORE_g=
-H5E_CANTCOMPUTE_g=
-H5E_CANTEXTEND_g=
-H5E_CANTATTACH_g=
+/* Heap errors */
+H5E_CANTRESTORE_g=
+H5E_CANTCOMPUTE_g=
+H5E_CANTEXTEND_g=
+H5E_CANTATTACH_g=
H5E_CANTUPDATE_g=
-/* Function entry/exit interface errors */
-H5E_CANTINIT_g=
-H5E_ALREADYINIT_g=
+/* Function entry/exit interface errors */
+H5E_CANTINIT_g=
+H5E_ALREADYINIT_g=
H5E_CANTRELEASE_g=
-/* Property list errors */
-H5E_CANTGET_g=
-H5E_CANTSET_g=
+/* Property list errors */
+H5E_CANTGET_g=
+H5E_CANTSET_g=
H5E_DUPCLASS_g=
-/* Free space errors */
-H5E_CANTMERGE_g=
-H5E_CANTREVIVE_g=
+/* Free space errors */
+H5E_CANTMERGE_g=
+H5E_CANTREVIVE_g=
H5E_CANTSHRINK_g=
-/* Object header related errors */
-H5E_LINKCOUNT_g=
-H5E_VERSION_g=
-H5E_ALIGNMENT_g=
-H5E_BADMESG_g=
-H5E_CANTDELETE_g=
-H5E_BADITER_g=
+/* Object header related errors */
+H5E_LINKCOUNT_g=
+H5E_VERSION_g=
+H5E_ALIGNMENT_g=
+H5E_BADMESG_g=
+H5E_CANTDELETE_g=
+H5E_BADITER_g=
H5E_CANTPACK_g=
-/* System level errors */
+/* System level errors */
H5E_SYSERRSTR_g=
-/* I/O pipeline errors */
-H5E_NOFILTER_g=
-H5E_CALLBACK_g=
-H5E_CANAPPLY_g=
-H5E_SETLOCAL_g=
+/* I/O pipeline errors */
+H5E_NOFILTER_g=
+H5E_CALLBACK_g=
+H5E_CANAPPLY_g=
+H5E_SETLOCAL_g=
H5E_NOENCODER_g=
-/* Group related errors */
-H5E_CANTOPENOBJ_g=
-H5E_CANTCLOSEOBJ_g=
-H5E_COMPLEN_g=
-H5E_LINK_g=
-H5E_SLINK_g=
+/* Group related errors */
+H5E_CANTOPENOBJ_g=
+H5E_CANTCLOSEOBJ_g=
+H5E_COMPLEN_g=
+H5E_LINK_g=
+H5E_SLINK_g=
H5E_PATH_g=
-/* No error */
+/* No error */
H5E_NONE_MINOR_g=
-/* File accessability errors */
-H5E_FILEEXISTS_g=
-H5E_FILEOPEN_g=
-H5E_CANTCREATE_g=
-H5E_CANTOPENFILE_g=
-H5E_CANTCLOSEFILE_g=
-H5E_NOTHDF5_g=
-H5E_BADFILE_g=
-H5E_TRUNCATED_g=
+/* File accessability errors */
+H5E_FILEEXISTS_g=
+H5E_FILEOPEN_g=
+H5E_CANTCREATE_g=
+H5E_CANTOPENFILE_g=
+H5E_CANTCLOSEFILE_g=
+H5E_NOTHDF5_g=
+H5E_BADFILE_g=
+H5E_TRUNCATED_g=
H5E_MOUNT_g=
-/* Object atom related errors */
-H5E_BADATOM_g=
-H5E_BADGROUP_g=
-H5E_CANTREGISTER_g=
-H5E_CANTINC_g=
-H5E_CANTDEC_g=
+/* Object atom related errors */
+H5E_BADATOM_g=
+H5E_BADGROUP_g=
+H5E_CANTREGISTER_g=
+H5E_CANTINC_g=
+H5E_CANTDEC_g=
H5E_NOIDS_g=
-/* Cache related errors */
-H5E_CANTFLUSH_g=
-H5E_CANTSERIALIZE_g=
-H5E_CANTLOAD_g=
-H5E_PROTECT_g=
-H5E_NOTCACHED_g=
-H5E_SYSTEM_g=
-H5E_CANTINS_g=
-H5E_CANTRENAME_g=
-H5E_CANTPROTECT_g=
-H5E_CANTUNPROTECT_g=
-H5E_CANTPIN_g=
-H5E_CANTUNPIN_g=
-H5E_CANTMARKDIRTY_g=
+/* Cache related errors */
+H5E_CANTFLUSH_g=
+H5E_CANTSERIALIZE_g=
+H5E_CANTLOAD_g=
+H5E_PROTECT_g=
+H5E_NOTCACHED_g=
+H5E_SYSTEM_g=
+H5E_CANTINS_g=
+H5E_CANTRENAME_g=
+H5E_CANTPROTECT_g=
+H5E_CANTUNPROTECT_g=
+H5E_CANTPIN_g=
+H5E_CANTUNPIN_g=
+H5E_CANTMARKDIRTY_g=
H5E_CANTDIRTY_g=
-/* Parallel MPI errors */
-H5E_MPI_g=
-H5E_MPIERRSTR_g=
+/* Parallel MPI errors */
+H5E_MPI_g=
+H5E_MPIERRSTR_g=
H5E_CANTRECV_g=
-/* Dataspace errors */
-H5E_CANTCLIP_g=
-H5E_CANTCOUNT_g=
-H5E_CANTSELECT_g=
-H5E_CANTNEXT_g=
-H5E_BADSELECT_g=
+/* Dataspace errors */
+H5E_CANTCLIP_g=
+H5E_CANTCOUNT_g=
+H5E_CANTSELECT_g=
+H5E_CANTNEXT_g=
+H5E_BADSELECT_g=
H5E_CANTCOMPARE_g=
-/* B-tree related errors */
-H5E_NOTFOUND_g=
-H5E_EXISTS_g=
-H5E_CANTENCODE_g=
-H5E_CANTDECODE_g=
-H5E_CANTSPLIT_g=
-H5E_CANTREDISTRIBUTE_g=
-H5E_CANTSWAP_g=
-H5E_CANTINSERT_g=
-H5E_CANTLIST_g=
-H5E_CANTMODIFY_g=
+/* B-tree related errors */
+H5E_NOTFOUND_g=
+H5E_EXISTS_g=
+H5E_CANTENCODE_g=
+H5E_CANTDECODE_g=
+H5E_CANTSPLIT_g=
+H5E_CANTREDISTRIBUTE_g=
+H5E_CANTSWAP_g=
+H5E_CANTINSERT_g=
+H5E_CANTLIST_g=
+H5E_CANTMODIFY_g=
H5E_CANTREMOVE_g=
-/* Argument errors */
-H5E_UNINITIALIZED_g=
-H5E_UNSUPPORTED_g=
-H5E_BADTYPE_g=
-H5E_BADRANGE_g=
+/* Argument errors */
+H5E_UNINITIALIZED_g=
+H5E_UNSUPPORTED_g=
+H5E_BADTYPE_g=
+H5E_BADRANGE_g=
H5E_BADVALUE_g=
-/* Datatype conversion errors */
-H5E_CANTCONVERT_g=
+/* Datatype conversion errors */
+H5E_CANTCONVERT_g=
H5E_BADSIZE_g= (-1);
#endif /* H5Eterm_H */
diff --git a/src/H5F.c b/src/H5F.c
index 0d80e51..24f4e9c 100644
--- a/src/H5F.c
+++ b/src/H5F.c
@@ -1428,8 +1428,8 @@ done:
* property list changes.
*
* J Mainzer, Jun 30, 2005
- * Added lf parameter so the shared->lf field can be
- * initialized prior to the call to H5AC_create() if a
+ * Added lf parameter so the shared->lf field can be
+ * initialized prior to the call to H5AC_create() if a
* new instance of H5F_file_t is created. lf should be
* NULL if shared isn't, and vise versa.
*
@@ -1458,7 +1458,7 @@ H5F_new(H5F_file_t *shared, hid_t fcpl_id, hid_t fapl_id, H5FD_t *lf)
f->shared->freespace_addr = HADDR_UNDEF;
f->shared->driver_addr = HADDR_UNDEF;
f->shared->lf = lf;
-
+
/*
* Copy the file creation and file access property lists into the
* new file handle. We do this early because some values might need
diff --git a/src/H5FDfamily.c b/src/H5FDfamily.c
index 0e4a453..c826163 100644
--- a/src/H5FDfamily.c
+++ b/src/H5FDfamily.c
@@ -60,7 +60,7 @@ typedef struct H5FD_family_t {
hid_t memb_fapl_id; /*file access property list for members */
hsize_t memb_size; /*actual size of each member file */
hsize_t pmem_size; /*member size passed in from property */
- hsize_t mem_newsize; /*new member size passed in as private
+ hsize_t mem_newsize; /*new member size passed in as private
*property. It's used only by h5repart */
unsigned nmembs; /*number of family members */
unsigned amembs; /*number of member slots allocated */
diff --git a/src/H5FDmpi.h b/src/H5FDmpi.h
index b7b4162..6c2a2c5 100644
--- a/src/H5FDmpi.h
+++ b/src/H5FDmpi.h
@@ -21,8 +21,8 @@
#ifndef H5FDmpi_H
#define H5FDmpi_H
-/***** Macros for One linked collective IO case. *****/
-/* The default value to do one linked collective IO for all chunks.
+/***** Macros for One linked collective IO case. *****/
+/* The default value to do one linked collective IO for all chunks.
If the average number of chunks per process is greater than this value,
the library will create an MPI derived datatype to link all chunks to do collective IO.
The user can set this value through an API. */
diff --git a/src/H5FDmpio.c b/src/H5FDmpio.c
index f639182..0be55e3 100644
--- a/src/H5FDmpio.c
+++ b/src/H5FDmpio.c
@@ -543,14 +543,14 @@ Description:
The library won't behave as it asks for only when we find
that the low-level MPI-IO package doesn't support this.
-Parameters:
+Parameters:
hid_t dxpl_id in: Data transfer property list identifier
H5FD_mpio_chunk_opt_t in: The optimization flag for linked chunk IO
or multi-chunk IO.
-
-Returns:
-Returns a non-negative value if successful. Otherwise returns a negative value.
+
+Returns:
+Returns a non-negative value if successful. Otherwise returns a negative value.
*
*-------------------------------------------------------------------------
*/
@@ -590,15 +590,15 @@ Purpose:
To set a threshold for doing linked chunk IO
Description:
- If the number is greater than the threshold set by the user,
+ If the number is greater than the threshold set by the user,
the library will do linked chunk IO; otherwise, IO will be done for every chunk.
-Parameters:
+Parameters:
hid_t dxpl_id in: Data transfer property list identifier
- unsigned num_proc_per_chunk in: the threshold of the average number of chunks selected by each process
+ unsigned num_proc_per_chunk in: the threshold of the average number of chunks selected by each process
-Returns:
-Returns a non-negative value if successful. Otherwise returns a negative value.
+Returns:
+Returns a non-negative value if successful. Otherwise returns a negative value.
*
*-------------------------------------------------------------------------
*/
@@ -637,13 +637,13 @@ Purpose:
To set a threshold for doing collective IO for each chunk
Description:
The library will calculate the percentage of the number of process holding selections at each chunk. If that percentage of number of process in the individual chunk is greater than the threshold set by the user, the library will do collective chunk IO for this chunk; otherwise, independent IO will be done for this chunk.
-Parameters:
- hid_t dxpl_id
+Parameters:
+ hid_t dxpl_id
in: Data transfer property list identifier
- unsigned percent_num_proc_per_chunk
+ unsigned percent_num_proc_per_chunk
in: the threshold of the percentage of the number of process holding selections per chunk
-Returns:
-Returns a non-negative value if successful. Otherwise returns a negative value.
+Returns:
+Returns a non-negative value if successful. Otherwise returns a negative value.
*
@@ -1701,7 +1701,7 @@ H5FD_mpio_write(H5FD_t *_file, H5FD_mem_t type, hid_t dxpl_id, haddr_t addr,
/* The metadata cache now only writes from process 0, which makes
* this synchronization incorrect. I'm leaving this code commented
* out instead of deleting it to remind us that we should re-write
- * this function so that a metadata write from any other process
+ * this function so that a metadata write from any other process
* should flag an error.
* -- JRM 9/1/05
*/
@@ -1772,13 +1772,13 @@ done:
#if 0 /* JRM */
/* Since metadata writes are now done by process 0 only, this broadcast
- * is no longer needed. I leave it in and commented out to remind us
+ * is no longer needed. I leave it in and commented out to remind us
* that we need to re-work this function to reflect this reallity.
*
* -- JRM 9/1/05
*/
- /* if only one process writes, need to broadcast the ret_value to
- * other processes
+ /* if only one process writes, need to broadcast the ret_value to
+ * other processes
*/
if (type!=H5FD_MEM_DRAW) {
if (MPI_SUCCESS != (mpi_code=MPI_Bcast(&ret_value, sizeof(ret_value), MPI_BYTE, H5_PAR_META_WRITE, file->comm)))
diff --git a/src/H5FDmpiposix.c b/src/H5FDmpiposix.c
index de491f0..2809539 100644
--- a/src/H5FDmpiposix.c
+++ b/src/H5FDmpiposix.c
@@ -913,7 +913,7 @@ done:
* John Mainzer -- 9/21/05
* Modified code to turn off the
* H5FD_FEAT_ACCUMULATE_METADATA_WRITE flag.
- * With the movement of all cache writes to process 0,
+ * With the movement of all cache writes to process 0,
* this flag has become problematic in PHDF5.
*
*-------------------------------------------------------------------------
@@ -1233,10 +1233,10 @@ H5FD_mpiposix_write(H5FD_t *_file, H5FD_mem_t type, hid_t dxpl_id, haddr_t addr,
/* Metadata specific actions */
/* All metadata is now written from process 0 -- thus this function
- * needs to be re-written to reflect this. For now I have simply
- * commented out the code that attempts to synchronize metadata
+ * needs to be re-written to reflect this. For now I have simply
+ * commented out the code that attempts to synchronize metadata
* writes between processes, but we should really just flag an error
- * whenever any process other than process 0 attempts to write
+ * whenever any process other than process 0 attempts to write
* metadata.
* -- JRM 9/1/05
*/
@@ -1394,7 +1394,7 @@ H5FD_mpiposix_flush(H5FD_t *_file, hid_t UNUSED dxpl_id, unsigned UNUSED closing
if(file->mpi_rank == H5_PAR_META_WRITE) {
#ifdef WIN32
/* Map the posix file handle to a Windows file handle */
- filehandle = _get_osfhandle(file->fd);
+ filehandle = _get_osfhandle(file->fd);
/* Translate 64-bit integers into form Windows wants */
/* [This algorithm is from the Windows documentation for SetFilePointer()] */
diff --git a/src/H5FDmulti.c b/src/H5FDmulti.c
index 652bd53..e7de49f 100644
--- a/src/H5FDmulti.c
+++ b/src/H5FDmulti.c
@@ -1631,7 +1631,7 @@ H5FD_multi_alloc(H5FD_t *_file, H5FD_mem_t type, hid_t dxpl_id, hsize_t size)
if ( addr + size > file->eoa ) {
if ( H5FD_multi_set_eoa(_file, addr + size) < 0 ) {
-
+
H5Epush_ret(func, H5E_ERR_CLS, H5E_INTERNAL, H5E_BADVALUE, \
"can't set eoa", HADDR_UNDEF)
}
diff --git a/src/H5FS.c b/src/H5FS.c
index 87fb4dd..5094405 100644
--- a/src/H5FS.c
+++ b/src/H5FS.c
@@ -1342,7 +1342,7 @@ HDfprintf(stderr, "%s: sect->size = %Hu, sect->addr = %a, sect->type = %u\n", FU
#ifdef QAK
HDfprintf(stderr, "%s: Returning space\n", FUNC);
#endif /* QAK */
-
+
/* Attempt to merge returned section with existing sections */
if(H5FS_sect_merge(f, dxpl_id, fspace, &sect, op_data) < 0)
HGOTO_ERROR(H5E_FSPACE, H5E_CANTMERGE, FAIL, "can't merge sections")
diff --git a/src/H5FSprivate.h b/src/H5FSprivate.h
index 281bb57..4ce9d88 100644
--- a/src/H5FSprivate.h
+++ b/src/H5FSprivate.h
@@ -117,7 +117,7 @@ typedef herr_t (*H5FS_operator_t)(const H5FS_section_info_t *sect,
/*****************************/
/* Library-private Variables */
/*****************************/
-
+
/* Declare a free list to manage the H5FS_section_class_t sequence information */
H5FL_SEQ_EXTERN(H5FS_section_class_t);
diff --git a/src/H5G.c b/src/H5G.c
index 34d3c56..c3e300a 100644
--- a/src/H5G.c
+++ b/src/H5G.c
@@ -292,9 +292,9 @@ done:
*
* Usage: H5Gcreate_expand(loc_id, char *name, gcpl_id, gapl_id)
* hid_t loc_id; IN: File or group identifier
- * const char *name; IN: Absolute or relative name of the new group
- * hid_t gcpl_id; IN: Property list for group creation
- * hid_t gapl_id; IN: Property list for group access
+ * const char *name; IN: Absolute or relative name of the new group
+ * hid_t gcpl_id; IN: Property list for group creation
+ * hid_t gapl_id; IN: Property list for group access
*
* Example: To create missing groups "A" and "B01" along the given path "/A/B01/grp"
* hid_t create_id = H5Pcreate(H5P_GROUP_CREATE);
@@ -1066,23 +1066,23 @@ done:
/*-------------------------------------------------------------------------
* Function: H5Gcopy
*
- * Purpose: Copy an object (group or dataset) to destination location
+ * Purpose: Copy an object (group or dataset) to destination location
* within a file or cross files. PLIST_ID is a property list
* which is used to pass user options and properties to the
- * copy.
+ * copy.
*
* OPTIONS THAT MAY APPLY TO COPY IN THE FUTURE.
* H5G_COPY_CREATE_INTERMEDIATE_GROUP_FLAG
* Do not create missing groups when create a group (default)
* Create missing groups when create a group
* H5G_COPY_SHALLOW_HIERARCHY_FLAG
- * Recursively copy all objects below the group (default)
+ * Recursively copy all objects below the group (default)
* Only immediate members.
* H5G_COPY_EXPAND_SOFT_LINK_FLAG
- * Keep soft links as they are (default)
+ * Keep soft links as they are (default)
* Expand them into new objects
* H5G_COPY_EXPAND_EXT_LINK_FLAG
- * Keep external links as they are (default)
+ * Keep external links as they are (default)
* Expand them into new objects
* H5G_COPY_EXPAND_OBJ_REFERENCE_FLAG
* Update only the values of object references (default)
@@ -1094,26 +1094,26 @@ done:
* PROPERTIES THAT MAY APPLY TO COPY IN FUTURE
* Change data layout such as chunk size
* Add filter such as data compression.
- * Add an attribute to the copied object(s) that say the date/time
+ * Add an attribute to the copied object(s) that say the date/time
* for the copy or other information about the source file.
*
* Usage: H5Gcopy(src_loc_id, src_name, dst_loc_id, dst_name, plist_id)
- * hid_t src_loc_id IN: Source file or group identifier.
+ * hid_t src_loc_id IN: Source file or group identifier.
* const char *src_name IN: Name of the source object to be copied
- * hid_t dst_loc_id IN: Destination file or group identifier
- * const char *dst_name IN: Name of the destination object
- * hid_t plist_id IN: Properties which apply to the copy
- *
+ * hid_t dst_loc_id IN: Destination file or group identifier
+ * const char *dst_name IN: Name of the destination object
+ * hid_t plist_id IN: Properties which apply to the copy
+ *
*
* Return: Non-negative on success/Negative on failure
*
- * Programmer: Peter Cao
- * June 4, 2005
+ * Programmer: Peter Cao
+ * June 4, 2005
*
*-------------------------------------------------------------------------
*/
herr_t
-H5Gcopy(hid_t src_loc_id, const char *src_name, hid_t dst_loc_id,
+H5Gcopy(hid_t src_loc_id, const char *src_name, hid_t dst_loc_id,
const char *dst_name, hid_t plist_id)
{
H5G_loc_t loc; /* Source group group location */
@@ -2987,12 +2987,12 @@ H5G_unmount(H5G_t *grp)
/*-------------------------------------------------------------------------
* Function: H5G_copy
*
- * Purpose: Copy an object to destination location
+ * Purpose: Copy an object to destination location
*
* Return: Non-negative on success/Negative on failure
*
- * Programmer: Peter Cao
- * June 4, 2005
+ * Programmer: Peter Cao
+ * June 4, 2005
*
*-------------------------------------------------------------------------
*/
diff --git a/src/H5Gloc.c b/src/H5Gloc.c
index a9e907f..57212b7 100644
--- a/src/H5Gloc.c
+++ b/src/H5Gloc.c
@@ -37,7 +37,7 @@
/* User data for looking up an object in a group */
typedef struct {
- H5G_loc_t *loc; /* Group location to set */
+ H5G_loc_t *loc; /* Group location to set */
} H5G_loc_ud1_t;
/* Private macros */
diff --git a/src/H5Gname.c b/src/H5Gname.c
index cc4e77b..fdae809 100644
--- a/src/H5Gname.c
+++ b/src/H5Gname.c
@@ -530,7 +530,7 @@ H5G_name_move_path(H5RS_str_t **path_r_ptr, const char *full_suffix, const char
/* Get pointer to path to update */
path = H5RS_get_str(*path_r_ptr);
HDassert(path);
-
+
/* Check if path needs to be updated */
full_suffix_len = HDstrlen(full_suffix);
path_len = HDstrlen(path);
diff --git a/src/H5Gnode.c b/src/H5Gnode.c
index d6915ea..90ee688 100644
--- a/src/H5Gnode.c
+++ b/src/H5Gnode.c
@@ -1897,7 +1897,7 @@ H5G_node_shared_free (void *_shared)
*
* Return: 0(zero) on success/Negative on failure
*
- * Programmer: Peter Cao
+ * Programmer: Peter Cao
* Sept 10, 2005
*
*-------------------------------------------------------------------------
@@ -1997,7 +1997,7 @@ H5G_node_copy(H5F_t *f, hid_t dxpl_id, const void UNUSED *_lt_key, haddr_t addr,
lnk.type = H5G_LINK_SOFT;
lnk.u.soft.name = H5HL_offset_into(f, heap, src_ent->cache.slink.lval_offset);
} /* else if */
- else
+ else
HDassert(0 && "Unknown entry type");
/* Set up common link data */
@@ -2023,7 +2023,7 @@ H5G_node_copy(H5F_t *f, hid_t dxpl_id, const void UNUSED *_lt_key, haddr_t addr,
if(H5G_stab_insert_real(udata->dst_file, udata->dst_stab, name, &lnk, dxpl_id) < 0)
HGOTO_ERROR(H5E_DATATYPE, H5E_CANTINIT, H5B_ITER_ERROR, "unable to insert the name")
} /* end of for (i=0; i<sn->nsyms; i++) */
-
+
done:
if (heap && H5HL_unprotect(f, dxpl_id, heap, udata->src_heap_addr, H5AC__NO_FLAGS_SET) < 0)
HDONE_ERROR(H5E_SYM, H5E_PROTECT, H5B_ITER_ERROR, "unable to unprotect symbol name")
diff --git a/src/H5Gobj.c b/src/H5Gobj.c
index 8846927..88b8cdf 100644
--- a/src/H5Gobj.c
+++ b/src/H5Gobj.c
@@ -48,7 +48,7 @@ typedef struct {
/* User data for looking up an object in a group */
typedef struct {
H5O_link_t *lnk; /* Link information to set for object */
- H5O_loc_t *oloc; /* Object location to set */
+ H5O_loc_t *oloc; /* Object location to set */
} H5G_obj_ud2_t;
/* Private macros */
@@ -119,7 +119,7 @@ H5G_obj_create(H5F_t *f, hid_t dxpl_id,
HDassert(link_size);
/* Compute size of header to use for creation */
- hdr_size = linfo_size +
+ hdr_size = linfo_size +
ginfo_size +
(ginfo->est_num_entries * (link_size + ginfo->est_name_len));
#else /* H5_GROUP_REVISION */
diff --git a/src/H5Gpublic.h b/src/H5Gpublic.h
index fd322a6..9300e8d 100644
--- a/src/H5Gpublic.h
+++ b/src/H5Gpublic.h
@@ -149,7 +149,7 @@ H5_DLL hid_t H5Gcreate_expand(hid_t loc_id, const char *name, hid_t gcpl_id,
hid_t gapl_id);
H5_DLL hid_t H5Gget_create_plist(hid_t group_id);
#endif /* H5_GROUP_REVISION */
-H5_DLL herr_t H5Gcopy(hid_t src_loc_id, const char *src_name, hid_t dst_loc_id,
+H5_DLL herr_t H5Gcopy(hid_t src_loc_id, const char *src_name, hid_t dst_loc_id,
const char *dst_name, hid_t plist_id);
#ifdef __cplusplus
diff --git a/src/H5HFcache.c b/src/H5HFcache.c
index d896a3e..15e0605 100644
--- a/src/H5HFcache.c
+++ b/src/H5HFcache.c
@@ -650,7 +650,7 @@ H5HF_cache_dblock_load(H5F_t *f, hid_t dxpl_id, haddr_t addr, const void *_size,
H5F_addr_decode(f, &p, &heap_addr);
if(H5F_addr_ne(heap_addr, dblock->hdr->heap_addr))
HGOTO_ERROR(H5E_HEAP, H5E_CANTLOAD, NULL, "incorrect heap header address for direct block")
-
+
/* Address of parent block */
dblock->parent = par_info->iblock;
dblock->par_entry = par_info->entry;
@@ -959,7 +959,7 @@ HDfprintf(stderr, "%s: Load indirect block, addr = %a\n", FUNC, addr);
H5F_addr_decode(f, &p, &heap_addr);
if(H5F_addr_ne(heap_addr, iblock->hdr->heap_addr))
HGOTO_ERROR(H5E_HEAP, H5E_CANTLOAD, NULL, "incorrect heap header address for direct block")
-
+
/* Address of parent block */
iblock->parent = par_info->iblock;
iblock->par_entry = par_info->entry;
diff --git a/src/H5HFhdr.c b/src/H5HFhdr.c
index 836d1e6..5aefe7b 100644
--- a/src/H5HFhdr.c
+++ b/src/H5HFhdr.c
@@ -95,7 +95,7 @@ H5FL_DEFINE(H5HF_hdr_t);
/*-------------------------------------------------------------------------
* Function: H5HF_hdr_alloc
*
- * Purpose: Allocate shared fractal heap header
+ * Purpose: Allocate shared fractal heap header
*
* Return: Non-negative on success/Negative on failure
*
diff --git a/src/H5HFiter.c b/src/H5HFiter.c
index ef926e8..94f0b8b 100644
--- a/src/H5HFiter.c
+++ b/src/H5HFiter.c
@@ -166,7 +166,7 @@ HDfprintf(stderr, "%s: offset = %Hu\n", FUNC, offset);
<Adjust offset for block offset for row>
<Make new block level the current context>
<Goto 1>
-
+
*/
do {
/* Walk down the rows in the doubling table until we've found the correct row for the next block */
diff --git a/src/H5HFprivate.h b/src/H5HFprivate.h
index b9ae0f4..4379dee 100644
--- a/src/H5HFprivate.h
+++ b/src/H5HFprivate.h
@@ -85,7 +85,7 @@ typedef struct H5HF_t H5HF_t;
/*****************************/
/* Library-private Variables */
/*****************************/
-
+
/***************************************/
/* Library-private Function Prototypes */
/***************************************/
diff --git a/src/H5HL.c b/src/H5HL.c
index e86be3d..cdfe49b 100644
--- a/src/H5HL.c
+++ b/src/H5HL.c
@@ -319,16 +319,16 @@ done:
*
* John Mainzer, 8/10/05
* Reworked this function for a different role.
- *
- * It used to be called during cache eviction, where it
- * attempted to size the disk space allocation for the
+ *
+ * It used to be called during cache eviction, where it
+ * attempted to size the disk space allocation for the
* actual size of the heap. However, this causes problems
* in the parallel case, as the reuslting disk allocations
* may not be synchronized.
*
- * It is now called from H5HL_remove(), where it is used to
+ * It is now called from H5HL_remove(), where it is used to
* reduce heap size in response to an entry deletion. This
- * means that the function should either do nothing, or
+ * means that the function should either do nothing, or
* reduce the size of the disk allocation.
*
*-------------------------------------------------------------------------
@@ -546,8 +546,8 @@ H5HL_serialize(H5F_t *f, H5HL_t *heap, uint8_t *buf)
*
* John Mainzer, 2005-08-10
* Removed call to H5HL_minimize_heap_space(). It does disk space
- * allocation, which can cause problems if done at flush time.
- * Instead, disk space allocation/deallocation is now done at
+ * allocation, which can cause problems if done at flush time.
+ * Instead, disk space allocation/deallocation is now done at
* insert/remove time.
*
*-------------------------------------------------------------------------
@@ -956,7 +956,7 @@ H5HL_remove_free(H5HL_t *heap, H5HL_free_t *fl)
*
* John Mainzer, 8/10/05
* Modified code to allocate file space as needed, instead
- * of allocating it on eviction.
+ * of allocating it on eviction.
*
*-------------------------------------------------------------------------
*/
@@ -1068,9 +1068,9 @@ H5HL_insert(H5F_t *f, hid_t dxpl_id, haddr_t addr, size_t buf_size, const void *
else { /* ...if we can't, allocate a new chunk & release the old */
haddr_t new_addr;
- /* The new allocation may fail -- to avoid the possiblity of
+ /* The new allocation may fail -- to avoid the possiblity of
* file corruption, allocate the new heap first, and then
- * deallocate the old.
+ * deallocate the old.
*/
/* allocate new disk space for the heap */
diff --git a/src/H5O.c b/src/H5O.c
index 18eee25..14b0b09 100644
--- a/src/H5O.c
+++ b/src/H5O.c
@@ -140,7 +140,7 @@ const H5O_msg_class_t *const H5O_msg_class_g[] = {
/* Header object ID to class mapping */
/*
* Initialize the object class info table. Begin with the most general types
- * and end with the most specific. For instance, any object that has a
+ * and end with the most specific. For instance, any object that has a
* datatype message is a datatype but only some of them are datasets.
*/
const H5O_obj_class_t *const H5O_obj_class_g[] = {
@@ -221,9 +221,9 @@ static herr_t H5O_iterate_real(const H5O_loc_t *loc, const H5O_msg_class_t *type
H5AC_protect_t prot, hbool_t internal, void *op, void *op_data, hid_t dxpl_id);
static H5G_obj_t H5O_obj_type_real(H5O_t *oh);
static const H5O_obj_class_t *H5O_obj_class(H5O_t *oh);
-static void * H5O_copy_mesg_file(const H5O_msg_class_t *type, H5F_t *file_src, void *mesg_src,
+static void * H5O_copy_mesg_file(const H5O_msg_class_t *type, H5F_t *file_src, void *mesg_src,
H5F_t *file_dst, hid_t dxpl_id, H5O_copy_t *cpy_info, void *udata);
-static herr_t H5O_copy_header_real(const H5O_loc_t *oloc_src, H5O_loc_t *oloc_dst /*out */,
+static herr_t H5O_copy_header_real(const H5O_loc_t *oloc_src, H5O_loc_t *oloc_dst /*out */,
hid_t dxpl_id, H5O_copy_t *cpy_info);
static herr_t H5O_copy_free_addrmap_cb(void *item, void *key, void *op_data);
@@ -1674,10 +1674,10 @@ done:
*-------------------------------------------------------------------------
*/
herr_t
-H5O_touch_oh(H5F_t *f,
- hid_t dxpl_id,
- H5O_t *oh,
- hbool_t force,
+H5O_touch_oh(H5F_t *f,
+ hid_t dxpl_id,
+ H5O_t *oh,
+ hbool_t force,
unsigned * oh_flags_ptr)
{
unsigned idx;
@@ -2117,7 +2117,7 @@ done:
} /* end H5O_remove_real() */
-/*-------------------------------------------------------------------------
+/*-------------------------------------------------------------------------
*
* Function: H5O_alloc_msgs
*
@@ -2140,7 +2140,7 @@ H5O_alloc_msgs(H5O_t *oh, size_t min_alloc)
herr_t ret_value = SUCCEED; /* Return value */
FUNC_ENTER_NOAPI_NOINIT(H5O_alloc_msgs)
-
+
/* check args */
HDassert(oh);
@@ -2164,7 +2164,7 @@ done:
} /* H5O_alloc_msgs() */
-/*-------------------------------------------------------------------------
+/*-------------------------------------------------------------------------
*
* Function: H5O_move_msgs_forward
*
@@ -2186,7 +2186,7 @@ H5O_move_msgs_forward(H5F_t *f, H5O_t *oh, hid_t dxpl_id)
htri_t ret_value; /* Return value */
FUNC_ENTER_NOAPI_NOINIT(H5O_move_msgs_forward)
-
+
/* check args */
HDassert(oh);
@@ -2234,14 +2234,14 @@ H5O_move_msgs_forward(H5F_t *f, H5O_t *oh, hid_t dxpl_id)
/* Mark messages dirty */
curr_msg->dirty = TRUE;
nonnull_msg->dirty = TRUE;
-
+
/* Set the flag to indicate that the null message
* was packed - if its not at the end its chunk,
* we'll move it again on the next pass.
*/
packed_msg = TRUE;
} /* end if */
-
+
/* Break out of loop */
break;
} /* end if */
@@ -2354,7 +2354,7 @@ done:
} /* H5O_move_msgs_forward() */
-/*-------------------------------------------------------------------------
+/*-------------------------------------------------------------------------
*
* Function: H5O_merge_null
*
@@ -2376,7 +2376,7 @@ H5O_merge_null(H5F_t *f, H5O_t *oh)
htri_t ret_value; /* Return value */
FUNC_ENTER_NOAPI_NOINIT_NOFUNC(H5O_merge_null)
-
+
/* check args */
HDassert(oh != NULL);
@@ -2459,7 +2459,7 @@ H5O_merge_null(H5F_t *f, H5O_t *oh)
} /* H5O_merge_null() */
-/*-------------------------------------------------------------------------
+/*-------------------------------------------------------------------------
*
* Function: H5O_remove_empty_chunks
*
@@ -2607,7 +2607,7 @@ done:
} /* H5O_remove_empty_chunks() */
-/*-------------------------------------------------------------------------
+/*-------------------------------------------------------------------------
*
* Function: H5O_condense_header
*
@@ -2670,15 +2670,15 @@ done:
} /* H5O_condense_header() */
-/*-------------------------------------------------------------------------
+/*-------------------------------------------------------------------------
*
* Function: H5O_alloc_extend_chunk
*
* Purpose: Attempt to extend a chunk that is allocated on disk.
*
- * If the extension is successful, and if the last message
- * of the chunk is the null message, then that message will
- * be extended with the chunk. Otherwise a new null message
+ * If the extension is successful, and if the last message
+ * of the chunk is the null message, then that message will
+ * be extended with the chunk. Otherwise a new null message
* is created.
*
* f is the file in which the chunk will be written. It is
@@ -2686,7 +2686,7 @@ done:
* this chunk.
*
* Return: TRUE: The chunk has been extended, and *msg_idx
- * contains the message index for null message
+ * contains the message index for null message
* which is large enough to hold size bytes.
*
* FALSE: The chunk cannot be extended, and *msg_idx
@@ -2699,10 +2699,10 @@ done:
*-------------------------------------------------------------------------
*/
static htri_t
-H5O_alloc_extend_chunk(H5F_t *f,
- H5O_t *oh,
- unsigned chunkno,
- size_t size,
+H5O_alloc_extend_chunk(H5F_t *f,
+ H5O_t *oh,
+ unsigned chunkno,
+ size_t size,
unsigned * msg_idx)
{
size_t delta; /* Change in chunk's size */
@@ -2747,7 +2747,7 @@ H5O_alloc_extend_chunk(H5F_t *f,
delta = H5O_ALIGN(delta);
/* determine whether the chunk can be extended */
- tri_result = H5MF_can_extend(f, H5FD_MEM_OHDR, oh->chunk[chunkno].addr,
+ tri_result = H5MF_can_extend(f, H5FD_MEM_OHDR, oh->chunk[chunkno].addr,
(hsize_t)(oh->chunk[chunkno].size), (hsize_t)delta);
if(tri_result == FALSE) { /* can't extend -- we are done */
HGOTO_DONE(FALSE);
@@ -2829,12 +2829,12 @@ done:
/*-------------------------------------------------------------------------
* Function: H5O_alloc_new_chunk
*
- * Purpose: Allocates a new chunk for the object header, including
+ * Purpose: Allocates a new chunk for the object header, including
* file space.
*
- * One of the other chunks will get an object continuation
- * message. If there isn't room in any other chunk for the
- * object continuation message, then some message from
+ * One of the other chunks will get an object continuation
+ * message. If there isn't room in any other chunk for the
+ * object continuation message, then some message from
* another chunk is moved into this chunk to make room.
*
* SIZE need not be aligned.
@@ -2853,9 +2853,9 @@ done:
*-------------------------------------------------------------------------
*/
static unsigned
-H5O_alloc_new_chunk(H5F_t *f,
- hid_t dxpl_id,
- H5O_t *oh,
+H5O_alloc_new_chunk(H5F_t *f,
+ hid_t dxpl_id,
+ H5O_t *oh,
size_t size)
{
size_t cont_size; /*continuation message size */
@@ -2926,9 +2926,9 @@ H5O_alloc_new_chunk(H5F_t *f,
* If we must move some other message to make room for the null
* message, then make sure the new chunk has enough room for that
* other message.
- *
+ *
* Move attributes first, then link messages, then other messages.
- *
+ *
*/
if(found_null < 0) {
if(found_attr >= 0)
@@ -3069,11 +3069,11 @@ done:
*-------------------------------------------------------------------------
*/
static unsigned
-H5O_alloc(H5F_t *f,
- hid_t dxpl_id,
- H5O_t *oh,
- const H5O_msg_class_t *type,
- size_t size,
+H5O_alloc(H5F_t *f,
+ hid_t dxpl_id,
+ H5O_t *oh,
+ const H5O_msg_class_t *type,
+ size_t size,
unsigned * oh_flags_ptr)
{
H5O_mesg_t *msg; /* Pointer to newly allocated message */
@@ -3112,7 +3112,7 @@ H5O_alloc(H5F_t *f,
/* check to see if we can extend one of the chunks. If we can,
* do so. Otherwise, we will have to allocate a new chunk.
*
- * Note that in this new version of this function, all chunks
+ * Note that in this new version of this function, all chunks
* must have file space allocated to them.
*/
for(chunkno = 0; chunkno < oh->nchunks; chunkno++) {
@@ -3122,14 +3122,14 @@ H5O_alloc(H5F_t *f,
tri_result = H5O_alloc_extend_chunk(f, oh, chunkno, size, &idx);
if(tri_result == TRUE)
- break;
+ break;
else if(tri_result == FALSE)
idx = UFAIL;
else
HGOTO_ERROR(H5E_OHDR, H5E_SYSTEM, UFAIL, "H5O_alloc_extend_chunk failed unexpectedly")
} /* end for */
- /* if idx is still UFAIL, we were not able to extend a chunk.
+ /* if idx is still UFAIL, we were not able to extend a chunk.
* Create a new one.
*/
if(idx == UFAIL)
@@ -3902,7 +3902,7 @@ done:
*
* Note: Same algorithm as H5O_obj_type_real()
*
- * Return: Success: An object class
+ * Return: Success: An object class
* Failure: NULL
*
* Programmer: Quincey Koziol
@@ -4019,21 +4019,21 @@ H5O_loc_copy(H5O_loc_t *dst, const H5O_loc_t *src, H5_copy_depth_t depth)
/*-------------------------------------------------------------------------
* Function: H5O_copy_mesg_file
- *
+ *
* Purpose: Copies a message to file. If MESG is is the null pointer then a null
* pointer is returned with no error.
*
* Return: Success: Ptr to the new message
*
* Failure: NULL
- *
- * Programmer: Peter Cao
- * June 4, 2005
- *
+ *
+ * Programmer: Peter Cao
+ * June 4, 2005
+ *
*-------------------------------------------------------------------------
*/
static void *
-H5O_copy_mesg_file(const H5O_msg_class_t *type, H5F_t *file_src, void *native_src,
+H5O_copy_mesg_file(const H5O_msg_class_t *type, H5F_t *file_src, void *native_src,
H5F_t *file_dst, hid_t dxpl_id, H5O_copy_t *cpy_info, void *udata)
{
void *ret_value;
@@ -4069,7 +4069,7 @@ done:
*-------------------------------------------------------------------------
*/
static herr_t
-H5O_copy_header_real(const H5O_loc_t *oloc_src, H5O_loc_t *oloc_dst /*out */,
+H5O_copy_header_real(const H5O_loc_t *oloc_src, H5O_loc_t *oloc_dst /*out */,
hid_t dxpl_id, H5O_copy_t *cpy_info)
{
H5O_addr_map_t *addr_map = NULL; /* Address mapping of object copied */
@@ -4129,8 +4129,8 @@ H5O_copy_header_real(const H5O_loc_t *oloc_src, H5O_loc_t *oloc_dst /*out */,
HGOTO_ERROR(H5E_RESOURCE, H5E_NOSPACE, FAIL, "memory allocation failed")
/* need to allocate all the chunks for the destination before copy the chunk message
- because continuation chunk message will need to know the chunk address of address of
- continuation block.
+ because continuation chunk message will need to know the chunk address of address of
+ continuation block.
*/
for(chunkno = 0; chunkno < oh_src->nchunks; chunkno++) {
size_t chunk_size = oh_src->chunk[chunkno].size;
@@ -4138,7 +4138,7 @@ H5O_copy_header_real(const H5O_loc_t *oloc_src, H5O_loc_t *oloc_dst /*out */,
/* '0th' chunk is preceded by object header prefix */
if(0 == chunkno) {
/* Allocate file space for the first chunk & object header prefix */
- if(HADDR_UNDEF == (addr_new = H5MF_alloc(oloc_dst->file, H5FD_MEM_OHDR, dxpl_id, (hsize_t)hdr_size + chunk_size)))
+ if(HADDR_UNDEF == (addr_new = H5MF_alloc(oloc_dst->file, H5FD_MEM_OHDR, dxpl_id, (hsize_t)hdr_size + chunk_size)))
HGOTO_ERROR(H5E_RESOURCE, H5E_NOSPACE, FAIL, "file allocation failed for object header")
/* Set first chunk's address */
@@ -4263,12 +4263,12 @@ H5O_copy_header_real(const H5O_loc_t *oloc_src, H5O_loc_t *oloc_dst /*out */,
/* Copy the source message */
if(H5O_CONT_ID == mesg_src->type->id) {
- if((mesg_dst->native = H5O_copy_mesg_file(copy_type, oloc_src->file, mesg_src->native,
+ if((mesg_dst->native = H5O_copy_mesg_file(copy_type, oloc_src->file, mesg_src->native,
oloc_dst->file, dxpl_id, cpy_info, oh_dst->chunk)) == NULL)
HGOTO_ERROR(H5E_OHDR, H5E_CANTCOPY, FAIL, "unable to copy object header message")
} /* end if */
else {
- if((mesg_dst->native = H5O_copy_mesg_file(copy_type, oloc_src->file, mesg_src->native,
+ if((mesg_dst->native = H5O_copy_mesg_file(copy_type, oloc_src->file, mesg_src->native,
oloc_dst->file, dxpl_id, cpy_info, udata)) == NULL)
HGOTO_ERROR(H5E_OHDR, H5E_CANTCOPY, FAIL, "unable to copy object header message")
} /* end else */
@@ -4301,8 +4301,8 @@ H5O_copy_header_real(const H5O_loc_t *oloc_src, H5O_loc_t *oloc_dst /*out */,
if(H5SL_insert(cpy_info->map_list, addr_map, &(addr_map->src_addr)) < 0)
HGOTO_ERROR(H5E_OHDR, H5E_CANTINSERT, FAIL, "can't insert object into skip list")
- /* "post copy" loop over messages, to fix up any messages which require a complete
- * object header for destination object
+ /* "post copy" loop over messages, to fix up any messages which require a complete
+ * object header for destination object
*/
for(mesgno = 0; mesgno < oh_src->nmesgs; mesgno++) {
/* Set up convenience variables */
@@ -4329,7 +4329,7 @@ H5O_copy_header_real(const H5O_loc_t *oloc_src, H5O_loc_t *oloc_dst /*out */,
LOAD_NATIVE(oloc_dst->file, dxpl_id, mesg_dst, FAIL)
/* Perform "post copy" operation on messge */
- if((copy_type->post_copy_file)(oloc_src, mesg_src->native, oloc_dst,
+ if((copy_type->post_copy_file)(oloc_src, mesg_src->native, oloc_dst,
mesg_dst->native, &modified, dxpl_id, cpy_info) < 0)
HGOTO_ERROR(H5E_OHDR, H5E_CANTINIT, FAIL, "unable to perform 'post copy' operation on message")
@@ -4391,7 +4391,7 @@ done:
*-------------------------------------------------------------------------
*/
herr_t
-H5O_copy_header_map(const H5O_loc_t *oloc_src, H5O_loc_t *oloc_dst /*out */,
+H5O_copy_header_map(const H5O_loc_t *oloc_src, H5O_loc_t *oloc_dst /*out */,
hid_t dxpl_id, H5O_copy_t *cpy_info, hbool_t inc_depth)
{
H5O_addr_map_t *addr_map; /* Address mapping of object copied */
diff --git a/src/H5Oattr.c b/src/H5Oattr.c
index d13216b..f0c15e7 100644
--- a/src/H5Oattr.c
+++ b/src/H5Oattr.c
@@ -640,14 +640,14 @@ done:
* Function: H5O_attr_pre_copy_file
*
* Purpose: Perform any necessary actions before copying message between
- * files for attribute messages.
+ * files for attribute messages.
*
* Return: Success: Non-negative
*
* Failure: Negative
*
* Programmer: Quincey Koziol
- * Monday, June 26, 2006
+ * Monday, June 26, 2006
*
*-------------------------------------------------------------------------
*/
@@ -682,16 +682,16 @@ H5O_attr_pre_copy_file(H5F_t UNUSED *file_src, const H5O_msg_class_t UNUSED *typ
* Failure: NULL
*
* Programmer: Quincey Koziol
- * November 1, 2005
+ * November 1, 2005
*
- * Modifications: Peter Cao
+ * Modifications: Peter Cao
* December 17, 2005
* Datatype conversion for variable length datatype
*
*-------------------------------------------------------------------------
*/
static void *
-H5O_attr_copy_file(H5F_t UNUSED *file_src, void *native_src, H5F_t *file_dst,
+H5O_attr_copy_file(H5F_t UNUSED *file_src, void *native_src, H5F_t *file_dst,
hid_t dxpl_id, H5O_copy_t *cpy_info, void UNUSED *udata)
{
H5A_t *attr_src = (H5A_t *)native_src;
@@ -819,7 +819,7 @@ H5O_attr_copy_file(H5F_t UNUSED *file_src, void *native_src, H5F_t *file_dst,
HGOTO_ERROR(H5E_DATATYPE, H5E_CANTINIT, NULL, "unable to convert between src and mem datatypes")
if(NULL == (tpath_mem_dst = H5T_path_find(dt_mem, attr_dst->dt, NULL, NULL, dxpl_id, FALSE)))
HGOTO_ERROR(H5E_DATATYPE, H5E_CANTINIT, NULL, "unable to convert between mem and dst datatypes")
-
+
/* Determine largest datatype size */
if(0 == (src_dt_size = H5T_get_size(attr_src->dt)))
HGOTO_ERROR(H5E_DATATYPE, H5E_CANTINIT, NULL, "unable to determine datatype size")
@@ -839,39 +839,39 @@ H5O_attr_copy_file(H5F_t UNUSED *file_src, void *native_src, H5F_t *file_dst,
/* Create dataspace for number of elements in buffer */
buf_dim = nelmts;
-
+
/* Create the space and set the initial extent */
if(NULL == (buf_space = H5S_create_simple((unsigned)1, &buf_dim, NULL)))
HGOTO_ERROR(H5E_DATASPACE, H5E_CANTCREATE, NULL, "can't create simple dataspace")
-
+
/* Atomize */
if((buf_sid = H5I_register(H5I_DATASPACE, buf_space)) < 0) {
H5S_close(buf_space);
HGOTO_ERROR(H5E_ATOM, H5E_CANTREGISTER, NULL, "unable to register dataspace ID")
} /* end if */
-
+
/* Allocate memory for recclaim buf */
if(NULL == (reclaim_buf = H5FL_BLK_MALLOC(attr_buf, buf_size)))
HGOTO_ERROR(H5E_RESOURCE, H5E_NOSPACE, NULL, "memory allocation NULLed for raw data chunk")
-
+
/* Allocate memory for copying the chunk */
if(NULL == (buf = H5FL_BLK_MALLOC(attr_buf, buf_size)))
HGOTO_ERROR(H5E_RESOURCE, H5E_NOSPACE, NULL, "memory allocation NULLed for raw data chunk")
-
+
HDmemcpy(buf, attr_src->data, attr_src->data_size);
-
+
/* Convert from source file to memory */
if(H5T_convert(tpath_src_mem, tid_src, tid_mem, nelmts, (size_t)0, (size_t)0, buf, NULL, dxpl_id) < 0)
HGOTO_ERROR(H5E_DATATYPE, H5E_CANTINIT, NULL, "datatype conversion NULLed")
-
+
HDmemcpy(reclaim_buf, buf, buf_size);
-
+
/* Convert from memory to destination file */
if(H5T_convert(tpath_mem_dst, tid_mem, tid_dst, nelmts, (size_t)0, (size_t)0, buf, NULL, dxpl_id) < 0)
HGOTO_ERROR(H5E_DATATYPE, H5E_CANTINIT, NULL, "datatype conversion NULLed")
-
+
HDmemcpy(attr_dst->data, buf, attr_dst->data_size);
-
+
if(H5D_vlen_reclaim(tid_mem, buf_space, H5P_DATASET_XFER_DEFAULT, reclaim_buf) < 0)
HGOTO_ERROR(H5E_DATASET, H5E_BADITER, NULL, "unable to reclaim variable-length data")
} /* type conversion */
diff --git a/src/H5Ocont.c b/src/H5Ocont.c
index 6cb5735..13a9d47 100644
--- a/src/H5Ocont.c
+++ b/src/H5Ocont.c
@@ -41,7 +41,7 @@ static herr_t H5O_cont_encode(H5F_t *f, uint8_t *p, const void *_mesg);
static size_t H5O_cont_size(const H5F_t *f, const void *_mesg);
static herr_t H5O_cont_free(void *mesg);
static herr_t H5O_cont_delete(H5F_t *f, hid_t dxpl_id, const void *_mesg, hbool_t adj_link);
-static void *H5O_cont_copy_file(H5F_t *file_src, void *mesg_src, H5F_t *file_dst,
+static void *H5O_cont_copy_file(H5F_t *file_src, void *mesg_src, H5F_t *file_dst,
hid_t dxpl_id, H5O_copy_t *cpy_info, void *udata);
static herr_t H5O_cont_debug(H5F_t *f, hid_t dxpl_id, const void *_mesg, FILE * stream,
int indent, int fwidth);
@@ -253,13 +253,13 @@ done:
*
* Failure: NULL
*
- * Programmer: Peter Cao
- * September 22, 2005
+ * Programmer: Peter Cao
+ * September 22, 2005
*
*-------------------------------------------------------------------------
*/
static void *
-H5O_cont_copy_file(H5F_t UNUSED *file_src, void *mesg_src, H5F_t UNUSED *file_dst,
+H5O_cont_copy_file(H5F_t UNUSED *file_src, void *mesg_src, H5F_t UNUSED *file_dst,
hid_t UNUSED dxpl_id, H5O_copy_t UNUSED *cpy_info, void *udata)
{
H5O_cont_t *cont_src = (H5O_cont_t *) mesg_src;
diff --git a/src/H5Odtype.c b/src/H5Odtype.c
index 93470c5..b5b441a 100644
--- a/src/H5Odtype.c
+++ b/src/H5Odtype.c
@@ -610,7 +610,7 @@ H5O_dtype_encode_helper(uint8_t **pp, const H5T_t *dt)
case H5T_ORDER_BE:
flags |= 0x01;
break;
- case H5T_ORDER_VAX: /*turn on 1st and 6th (reserved before adding VAX) bits*/
+ case H5T_ORDER_VAX: /*turn on 1st and 6th (reserved before adding VAX) bits*/
flags |= 0x41;
has_vax = TRUE;
break;
@@ -1211,7 +1211,7 @@ H5O_dtype_set_share(H5F_t UNUSED *f, void *_mesg/*in,out*/,
* Failure: Negative
*
* Programmer: Quincey Koziol
- * November 21, 2005
+ * November 21, 2005
*
*-------------------------------------------------------------------------
*/
diff --git a/src/H5Oefl.c b/src/H5Oefl.c
index afa46f1..cd94d69 100644
--- a/src/H5Oefl.c
+++ b/src/H5Oefl.c
@@ -33,7 +33,7 @@ static herr_t H5O_efl_encode(H5F_t *f, uint8_t *p, const void *_mesg);
static void *H5O_efl_copy(const void *_mesg, void *_dest, unsigned update_flags);
static size_t H5O_efl_size(const H5F_t *f, const void *_mesg);
static herr_t H5O_efl_reset(void *_mesg);
-static void *H5O_efl_copy_file(H5F_t *file_src, void *mesg_src, H5F_t *file_dst,
+static void *H5O_efl_copy_file(H5F_t *file_src, void *mesg_src, H5F_t *file_dst,
hid_t dxpl_id, H5O_copy_t *cpy_info, void *udata);
static herr_t H5O_efl_debug(H5F_t *f, hid_t dxpl_id, const void *_mesg, FILE * stream,
int indent, int fwidth);
@@ -427,15 +427,15 @@ done:
*
* Failure: NULL
*
- * Programmer: Peter Cao
- * September 29, 2005
+ * Programmer: Peter Cao
+ * September 29, 2005
*
* Modifications:
*
*-------------------------------------------------------------------------
*/
static void *
-H5O_efl_copy_file(H5F_t UNUSED *file_src, void *mesg_src, H5F_t *file_dst,
+H5O_efl_copy_file(H5F_t UNUSED *file_src, void *mesg_src, H5F_t *file_dst,
hid_t dxpl_id, H5O_copy_t UNUSED *cpy_info, void UNUSED *_udata)
{
H5O_efl_t *efl_src = (H5O_efl_t *) mesg_src;
diff --git a/src/H5Olayout.c b/src/H5Olayout.c
index b6008c8..bff1dfb 100644
--- a/src/H5Olayout.c
+++ b/src/H5Olayout.c
@@ -39,7 +39,7 @@ static size_t H5O_layout_size(const H5F_t *f, const void *_mesg);
static herr_t H5O_layout_reset(void *_mesg);
static herr_t H5O_layout_free(void *_mesg);
static herr_t H5O_layout_delete(H5F_t *f, hid_t dxpl_id, const void *_mesg, hbool_t adj_link);
-static void *H5O_layout_copy_file(H5F_t *file_src, void *mesg_src, H5F_t *file_dst,
+static void *H5O_layout_copy_file(H5F_t *file_src, void *mesg_src, H5F_t *file_dst,
hid_t dxpl_id, H5O_copy_t *cpy_info, void *udata);
static herr_t H5O_layout_debug(H5F_t *f, hid_t dxpl_id, const void *_mesg, FILE * stream,
int indent, int fwidth);
@@ -613,15 +613,15 @@ done:
*
* Failure: NULL
*
- * Programmer: Peter Cao
- * July 23, 2005
+ * Programmer: Peter Cao
+ * July 23, 2005
*
* Modifications:
*
*-------------------------------------------------------------------------
*/
static void *
-H5O_layout_copy_file(H5F_t *file_src, void *mesg_src, H5F_t *file_dst, hid_t dxpl_id,
+H5O_layout_copy_file(H5F_t *file_src, void *mesg_src, H5F_t *file_dst, hid_t dxpl_id,
H5O_copy_t UNUSED *cpy_info, void *_udata)
{
H5D_copy_file_ud_t *udata = (H5D_copy_file_ud_t *)_udata; /* Dataset copying user data */
@@ -677,7 +677,7 @@ H5O_layout_copy_file(H5F_t *file_src, void *mesg_src, H5F_t *file_dst, hid_t dxp
layout_dst->u.chunk.addr = HADDR_UNDEF;
/* create chunked layout */
- if(H5D_istore_copy(file_src, layout_src, file_dst, layout_dst,
+ if(H5D_istore_copy(file_src, layout_src, file_dst, layout_dst,
udata->src_dtype, udata->src_pline, dxpl_id) < 0)
HGOTO_ERROR(H5E_IO, H5E_CANTINIT, NULL, "unable to copy chunked storage")
diff --git a/src/H5Olinfo.c b/src/H5Olinfo.c
index 1b84191..8017002 100644
--- a/src/H5Olinfo.c
+++ b/src/H5Olinfo.c
@@ -282,7 +282,7 @@ H5O_linfo_free(void *mesg)
*-------------------------------------------------------------------------
*/
static void *
-H5O_linfo_copy_file(H5F_t UNUSED *file_src, void *native_src, H5F_t UNUSED *file_dst,
+H5O_linfo_copy_file(H5F_t UNUSED *file_src, void *native_src, H5F_t UNUSED *file_dst,
hid_t UNUSED dxpl_id, H5O_copy_t *cpy_info, void UNUSED *udata)
{
H5O_linfo_t *linfo_src = (H5O_linfo_t *) native_src;
diff --git a/src/H5Olink.c b/src/H5Olink.c
index bc45326..c7c00ca 100644
--- a/src/H5Olink.c
+++ b/src/H5Olink.c
@@ -47,7 +47,7 @@ static herr_t H5O_link_pre_copy_file(H5F_t *file_src, const H5O_msg_class_t *typ
void *mesg_src, hbool_t *deleted, const H5O_copy_t *cpy_info, void *udata);
static void *H5O_link_copy_file(H5F_t *file_src, void *native_src,
H5F_t *file_dst, hid_t dxpl_id, H5O_copy_t *cpy_info, void *udata);
-static herr_t H5O_link_post_copy_file(const H5O_loc_t *parent_src_oloc, const void *mesg_src, H5O_loc_t *dst_oloc,
+static herr_t H5O_link_post_copy_file(const H5O_loc_t *parent_src_oloc, const void *mesg_src, H5O_loc_t *dst_oloc,
void *mesg_dst, hbool_t *modified, hid_t dxpl_id, H5O_copy_t *cpy_info);
static herr_t H5O_link_debug(H5F_t *f, hid_t dxpl_id, const void *_mesg,
FILE * stream, int indent, int fwidth);
@@ -468,14 +468,14 @@ done:
* Function: H5O_link_pre_copy_file
*
* Purpose: Perform any necessary actions before copying message between
- * files for link messages.
+ * files for link messages.
*
* Return: Success: Non-negative
*
* Failure: Negative
*
* Programmer: Quincey Koziol
- * Monday, June 26, 2006
+ * Monday, June 26, 2006
*
*-------------------------------------------------------------------------
*/
@@ -512,12 +512,12 @@ H5O_link_pre_copy_file(H5F_t UNUSED *file_src, const H5O_msg_class_t UNUSED *typ
* Failure: NULL
*
* Programmer: Quincey Koziol
- * November 7, 2005
+ * November 7, 2005
*
*-------------------------------------------------------------------------
*/
static void *
-H5O_link_copy_file(H5F_t UNUSED *file_src, void *native_src, H5F_t UNUSED *file_dst,
+H5O_link_copy_file(H5F_t UNUSED *file_src, void *native_src, H5F_t UNUSED *file_dst,
hid_t UNUSED dxpl_id, H5O_copy_t UNUSED *cpy_info, void UNUSED *udata)
{
H5O_link_t *link_src = (H5O_link_t *) native_src;
@@ -580,12 +580,12 @@ done:
* Return: Non-negative on success/Negative on failure
*
* Programmer: Quincey Koziol
- * November 7, 2005
+ * November 7, 2005
*
*-------------------------------------------------------------------------
*/
-static herr_t
-H5O_link_post_copy_file(const H5O_loc_t *parent_src_oloc, const void *mesg_src, H5O_loc_t *dst_oloc, void *mesg_dst,
+static herr_t
+H5O_link_post_copy_file(const H5O_loc_t *parent_src_oloc, const void *mesg_src, H5O_loc_t *dst_oloc, void *mesg_dst,
hbool_t *modified, hid_t dxpl_id, H5O_copy_t *cpy_info)
{
H5O_link_t *link_src = (H5O_link_t *)mesg_src; /* Casting away const OK... -QAK */
diff --git a/src/H5Opkg.h b/src/H5Opkg.h
index cdcfe0f..092de03 100644
--- a/src/H5Opkg.h
+++ b/src/H5Opkg.h
@@ -164,7 +164,7 @@ H5_DLLVAR const H5O_msg_class_t H5O_MSG_DTYPE[1];
H5_DLLVAR const H5O_msg_class_t H5O_MSG_FILL[1];
/* New Fill Value Message. (0x0005) */
-/*
+/*
* The new fill value message is fill value plus
* space allocation time and fill value writing time and whether fill
* value is defined.
@@ -208,7 +208,7 @@ H5_DLLVAR const H5O_msg_class_t H5O_MSG_NAME[1];
H5_DLLVAR const H5O_msg_class_t H5O_MSG_MTIME[1];
/* Shared Object Message. (0x000f) */
-/*
+/*
* This message ID never really appears in an object
* header. Instead, bit 2 of the `Flags' field will be set and the ID field
* will be the ID of the pointed-to message.
@@ -222,7 +222,7 @@ H5_DLLVAR const H5O_msg_class_t H5O_MSG_CONT[1];
H5_DLLVAR const H5O_msg_class_t H5O_MSG_STAB[1];
/* New Modification Time Message. (0x0012) */
-/*
+/*
* The message is just a `time_t'.
*/
H5_DLLVAR const H5O_msg_class_t H5O_MSG_MTIME_NEW[1];
diff --git a/src/H5Opline.c b/src/H5Opline.c
index 9658e07..29cd0fd 100644
--- a/src/H5Opline.c
+++ b/src/H5Opline.c
@@ -435,8 +435,8 @@ H5O_pline_free (void *mesg)
*
* Failure: Negative
*
- * Programmer: Peter Cao
- * December 27, 2005
+ * Programmer: Peter Cao
+ * December 27, 2005
*
*-------------------------------------------------------------------------
*/
diff --git a/src/H5Oprivate.h b/src/H5Oprivate.h
index ee3f5da..1c4108a 100644
--- a/src/H5Oprivate.h
+++ b/src/H5Oprivate.h
@@ -72,7 +72,7 @@ typedef struct H5O_copy_t {
hbool_t expand_soft_link; /* Flag to expand soft links */
hbool_t expand_ext_link; /* Flag to expand external links */
hbool_t expand_obj_ref; /* Flag to expand object references */
- hbool_t copy_without_attr; /* Flag to not copy attributes */
+ hbool_t copy_without_attr; /* Flag to not copy attributes */
int curr_depth; /* Current depth in hierarchy copied */
int max_depth; /* Maximum depth in hierarchy to copy */
H5SL_t *map_list; /* Skip list to hold address mappings */
@@ -357,9 +357,9 @@ H5_DLL herr_t H5O_get_info(H5O_loc_t *loc, H5O_stat_t *ostat, hid_t dxpl_id);
H5_DLL herr_t H5O_iterate(const H5O_loc_t *loc, unsigned type_id, H5O_operator_t op,
void *op_data, hid_t dxpl_id);
H5_DLL H5G_obj_t H5O_obj_type(H5O_loc_t *loc, hid_t dxpl_id);
-H5_DLL herr_t H5O_copy_header(const H5O_loc_t *oloc_src, H5O_loc_t *oloc_dst /*out */,
+H5_DLL herr_t H5O_copy_header(const H5O_loc_t *oloc_src, H5O_loc_t *oloc_dst /*out */,
hid_t dxpl_id, unsigned cpy_option);
-H5_DLL herr_t H5O_copy_header_map(const H5O_loc_t *oloc_src, H5O_loc_t *oloc_dst /*out */,
+H5_DLL herr_t H5O_copy_header_map(const H5O_loc_t *oloc_src, H5O_loc_t *oloc_dst /*out */,
hid_t dxpl_id, H5O_copy_t *cpy_info, hbool_t inc_depth);
H5_DLL herr_t H5O_debug_id(unsigned type_id, H5F_t *f, hid_t dxpl_id, const void *mesg, FILE *stream, int indent, int fwidth);
H5_DLL herr_t H5O_debug(H5F_t *f, hid_t dxpl_id, haddr_t addr, FILE * stream, int indent,
diff --git a/src/H5Oshared.c b/src/H5Oshared.c
index dc5ea6f..226f300 100644
--- a/src/H5Oshared.c
+++ b/src/H5Oshared.c
@@ -423,12 +423,12 @@ done:
* Failure: NULL
*
* Programmer: Quincey Koziol
- * November 1, 2005
+ * November 1, 2005
*
*-------------------------------------------------------------------------
*/
static void *
-H5O_shared_copy_file(H5F_t UNUSED *file_src, void *native_src, H5F_t *file_dst,
+H5O_shared_copy_file(H5F_t UNUSED *file_src, void *native_src, H5F_t *file_dst,
hid_t dxpl_id, H5O_copy_t *cpy_info, void UNUSED *udata)
{
H5O_shared_t *shared_src = (H5O_shared_t *)native_src;
@@ -470,14 +470,14 @@ done:
* Function: H5O_shared_pre_copy_file
*
* Purpose: Perform any necessary actions before copying message between
- * files for shared messages.
+ * files for shared messages.
*
* Return: Success: Non-negative
*
* Failure: Negative
*
- * Programmer: Peter Cao
- * Saturday, February 11, 2006
+ * Programmer: Peter Cao
+ * Saturday, February 11, 2006
*
*-------------------------------------------------------------------------
*/
@@ -487,7 +487,7 @@ H5O_shared_pre_copy_file(H5F_t *file_src, const H5O_msg_class_t *type,
void *udata)
{
H5O_shared_t *shared_src = (H5O_shared_t *)native_src;
- void *mesg_native = NULL;
+ void *mesg_native = NULL;
herr_t ret_value = SUCCEED; /* Return value */
FUNC_ENTER_NOAPI_NOINIT(H5O_shared_pre_copy_file)
diff --git a/src/H5Ostab.c b/src/H5Ostab.c
index 7516afd..d641bc5 100644
--- a/src/H5Ostab.c
+++ b/src/H5Ostab.c
@@ -45,7 +45,7 @@ static herr_t H5O_stab_free(void *_mesg);
static herr_t H5O_stab_delete(H5F_t *f, hid_t dxpl_id, const void *_mesg, hbool_t adj_link);
static void *H5O_stab_copy_file(H5F_t *file_src, void *native_src,
H5F_t *file_dst, hid_t dxpl_id, H5O_copy_t *cpy_info, void *udata);
-static herr_t H5O_stab_post_copy_file(const H5O_loc_t *parent_src_oloc, const void *mesg_src, H5O_loc_t *dst_oloc,
+static herr_t H5O_stab_post_copy_file(const H5O_loc_t *parent_src_oloc, const void *mesg_src, H5O_loc_t *dst_oloc,
void *mesg_dst, hbool_t *modified, hid_t dxpl_id, H5O_copy_t *cpy_info);
static herr_t H5O_stab_debug(H5F_t *f, hid_t dxpl_id, const void *_mesg,
FILE * stream, int indent, int fwidth);
@@ -305,13 +305,13 @@ done:
*
* Failure: NULL
*
- * Programmer: Peter Cao
- * September 10, 2005
+ * Programmer: Peter Cao
+ * September 10, 2005
*
*-------------------------------------------------------------------------
*/
static void *
-H5O_stab_copy_file(H5F_t *file_src, void *native_src, H5F_t *file_dst,
+H5O_stab_copy_file(H5F_t *file_src, void *native_src, H5F_t *file_dst,
hid_t dxpl_id, H5O_copy_t UNUSED *cpy_info, void UNUSED *udata)
{
H5O_stab_t *stab_src = (H5O_stab_t *) native_src;
@@ -356,19 +356,19 @@ done:
*
* Return: Non-negative on success/Negative on failure
*
- * Programmer: Peter Cao
- * September 28, 2005
+ * Programmer: Peter Cao
+ * September 28, 2005
*
*-------------------------------------------------------------------------
*/
-static herr_t
-H5O_stab_post_copy_file(const H5O_loc_t *parent_src_oloc, const void *mesg_src, H5O_loc_t *dst_oloc,
+static herr_t
+H5O_stab_post_copy_file(const H5O_loc_t *parent_src_oloc, const void *mesg_src, H5O_loc_t *dst_oloc,
void *mesg_dst, hbool_t UNUSED *modified, hid_t dxpl_id, H5O_copy_t *cpy_info)
{
H5G_bt_it_ud5_t udata; /* B-tree user data */
const H5O_stab_t *stab_src = (const H5O_stab_t *)mesg_src;
H5O_stab_t *stab_dst = (H5O_stab_t *)mesg_dst;
- H5F_t *file_src = parent_src_oloc->file;
+ H5F_t *file_src = parent_src_oloc->file;
herr_t ret_value = SUCCEED; /* Return value */
FUNC_ENTER_NOAPI_NOINIT(H5O_stab_post_copy_file)
diff --git a/src/H5Pocpl.c b/src/H5Pocpl.c
index b00d314..7002b9d 100755
--- a/src/H5Pocpl.c
+++ b/src/H5Pocpl.c
@@ -37,14 +37,14 @@
* unsigned crt_intmd_group; IN: Flag to create intermediate group
* positive value -- to create intermediate group
* otherwise -- do not create intermediate group
- * For example, H5Pset_create_intermediate_group(plist_id, 1) to create intermediate group;
+ * For example, H5Pset_create_intermediate_group(plist_id, 1) to create intermediate group;
*
* Note: XXX: This property should really be an access property. -QAK
* XXX: The property is used only at creation time. It should
* be a creation property. However, the property is not
* saved with the group. In that sense, it should be access
* property. We do not have a good solution for this kind
- * of property. For now, it is used as a creation property.
+ * of property. For now, it is used as a creation property.
* -PXC
*
* Return: Non-negative on success/Negative on failure
@@ -119,18 +119,18 @@ done:
* from one location to another
*
* Usage: H5Pset_copy_group(plist_id, cpy_option)
- * hid_t plist_id; IN: Property list to copy object
+ * hid_t plist_id; IN: Property list to copy object
* unsigned cpy_option; IN: Options to copy object such as
* H5G_COPY_SHALLOW_HIERARCHY_FLAG -- Copy only immediate members
* H5G_COPY_EXPAND_SOFT_LINK_FLAG -- Expand soft links into new objects/
- * H5G_COPY_EXPAND_EXT_LINK_FLAG -- Expand external links into new objects
+ * H5G_COPY_EXPAND_EXT_LINK_FLAG -- Expand external links into new objects
* H5G_COPY_EXPAND_OBJ_REFERENCE_FLAG -- Copy objects that are pointed by references
* H5G_COPY_WITHOUT_ATTR_FLAG -- Copy object without copying attributes
*
* Return: Non-negative on success/Negative on failure
*
* Programmer: Peter Cao
- * March 13, 2006
+ * March 13, 2006
*-------------------------------------------------------------------------
*/
herr_t
@@ -163,12 +163,12 @@ done:
* Function: H5Pget_copy_object
*
* Purpose: Returns the cpy_option, which is set for H5Gcopy(hid_t loc_id,
- * const char* name, ... ) for copying objects
+ * const char* name, ... ) for copying objects
*
* Return: Non-negative on success/Negative on failure
*
* Programmer: Peter Cao
- * March 13, 2006
+ * March 13, 2006
*-------------------------------------------------------------------------
*/
herr_t
diff --git a/src/H5Shyper.c b/src/H5Shyper.c
index 83bebe9..f1b3f37 100644
--- a/src/H5Shyper.c
+++ b/src/H5Shyper.c
@@ -5350,7 +5350,7 @@ done:
RETURNS
>=0 on success, <0 on failure
DESCRIPTION
- Examine the span tree for a hyperslab selection and rebuild
+ Examine the span tree for a hyperslab selection and rebuild
the start/stride/count/block information for the selection, if possible.
GLOBAL VARIABLES
@@ -5374,7 +5374,7 @@ H5S_hyper_rebuild_helper(const H5S_hyper_span_t *span, H5S_hyper_dim_t span_slab
unsigned u;
H5S_hyper_dim_t canon_down_span_slab_info[H5S_MAX_RANK];
hbool_t ret_value = TRUE;
-
+
FUNC_ENTER_NOAPI_NOINIT_NOFUNC(H5S_hyper_rebuild_helper)
if(span) {
@@ -5431,7 +5431,7 @@ H5S_hyper_rebuild_helper(const H5S_hyper_span_t *span, H5S_hyper_dim_t span_slab
} /* end if */
/* Obtain values for stride and block */
- next_stride = span->low - curr_low;
+ next_stride = span->low - curr_low;
next_block = (span->high - span->low) + 1;
/* Compare stride and block in this span, to compare stride,
@@ -5478,7 +5478,7 @@ done:
RETURNS
>=0 on success, <0 on failure
DESCRIPTION
- Examine the span tree for a hyperslab selection and rebuild
+ Examine the span tree for a hyperslab selection and rebuild
the start/stride/count/block information for the selection, if possible.
GLOBAL VARIABLES
@@ -5490,7 +5490,7 @@ done:
REVISION LOG
This routine is the optimization of the old version. The previous version
- can only detect a singluar selection. This version is general enough to
+ can only detect a singluar selection. This version is general enough to
detect any regular selection.
KY, 2005/9/22
--------------------------------------------------------------------------*/
@@ -5520,7 +5520,7 @@ H5S_hyper_rebuild(H5S_t *space)
diminfo=space->select.sel_info.hslab->opt_diminfo;
app_diminfo=space->select.sel_info.hslab->app_diminfo;
- for(curr_dim = 0; curr_dim < rank; curr_dim++) {
+ for(curr_dim = 0; curr_dim < rank; curr_dim++) {
app_diminfo[(rank - curr_dim) - 1].start = diminfo[(rank - curr_dim) - 1].start = top_span_slab_info[curr_dim].start;
app_diminfo[(rank - curr_dim) - 1].stride = diminfo[(rank - curr_dim) - 1].stride = top_span_slab_info[curr_dim].stride;
diff --git a/src/H5Stest.c b/src/H5Stest.c
index 5a1d2b0..0e28b3f 100644
--- a/src/H5Stest.c
+++ b/src/H5Stest.c
@@ -98,12 +98,12 @@ H5S_get_rebuild_status_test(hid_t space_id)
FUNC_ENTER_NOAPI(H5S_get_rebuild_status_test, FAIL)
- /* Get dataspace structures */
- if(NULL == (space = H5I_object_verify(space_id, H5I_DATASPACE)))
+ /* Get dataspace structures */
+ if(NULL == (space = H5I_object_verify(space_id, H5I_DATASPACE)))
HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a dataspace")
ret_value = space->select.sel_info.hslab->diminfo_valid;
-
+
done:
FUNC_LEAVE_NOAPI(ret_value)
} /* H5S_get_rebuild_status_test() */
diff --git a/src/H5T.c b/src/H5T.c
index b955b40..045c42d 100644
--- a/src/H5T.c
+++ b/src/H5T.c
@@ -1289,7 +1289,7 @@ H5T_init_interface(void)
#if H5T_CONV_INTERNAL_FP_ULLONG
status |= H5T_register(H5T_PERS_HARD, "flt_ullong", native_float, native_ullong, H5T_conv_float_ullong, H5AC_dxpl_id, FALSE);
status |= H5T_register(H5T_PERS_HARD, "dbl_ullong", native_double, native_ullong, H5T_conv_double_ullong, H5AC_dxpl_id, FALSE);
-#endif /* H5T_CONV_INTERNAL_FP_ULLONG */
+#endif /* H5T_CONV_INTERNAL_FP_ULLONG */
#if H5T_CONV_INTERNAL_LDOUBLE_ULLONG
status |= H5T_register(H5T_PERS_HARD, "ldbl_ullong", native_ldouble, native_ullong, H5T_conv_ldouble_ullong, H5AC_dxpl_id, FALSE);
#endif /* H5T_CONV_INTERNAL_LDOUBLE_ULLONG */
@@ -2629,11 +2629,11 @@ done:
* Function: H5Tcompiler_conv
*
* Purpose: Finds out whether the library's conversion function from
- * type src_id to type dst_id is a compiler (hard) conversion.
- * A hard conversion uses compiler's casting; a soft conversion
+ * type src_id to type dst_id is a compiler (hard) conversion.
+ * A hard conversion uses compiler's casting; a soft conversion
* uses the library's own conversion function.
*
- * Return: TRUE: hard conversion.
+ * Return: TRUE: hard conversion.
* FALSE: soft conversion.
* FAIL: failed.
*
@@ -4193,11 +4193,11 @@ done:
*
* Modifications:
* Added a parameter IS_API to indicate whether to an API
- * function issued a call to this function. If a API
- * function like H5Tregister() is calling this function to
- * register a new hard conversion function, IS_API is TRUE
- * and the old path is replaced. If a private function like
- * H5T_init_interface() is trying to register hard conversions,
+ * function issued a call to this function. If a API
+ * function like H5Tregister() is calling this function to
+ * register a new hard conversion function, IS_API is TRUE
+ * and the old path is replaced. If a private function like
+ * H5T_init_interface() is trying to register hard conversions,
* IS_API is FALSE and the old hard path is not replaced.
* Tuesday, Sept 13, 2005
*
@@ -4288,9 +4288,9 @@ H5T_path_find(const H5T_t *src, const H5T_t *dst, const char *name,
old_npaths=H5T_g.npaths;
/*
- * If we didn't find the path, if the caller is an API function specifying
- * a new hard conversion function, or if the caller is a private function
- * specifying a new hard conversion and the path is a soft conversion, then
+ * If we didn't find the path, if the caller is an API function specifying
+ * a new hard conversion function, or if the caller is a private function
+ * specifying a new hard conversion and the path is a soft conversion, then
* create a new path and add the new function to the path.
*/
if (!table || (table && func && is_api) || (table && !table->is_hard && func && !is_api)) {
@@ -4311,8 +4311,8 @@ H5T_path_find(const H5T_t *src, const H5T_t *dst, const char *name,
/*
* If a hard conversion function is specified and none is defined for the
- * path, or the caller is an API function, or the caller is a private function but
- * the existing path is a soft function, then add the new conversion to the path
+ * path, or the caller is an API function, or the caller is a private function but
+ * the existing path is a soft function, then add the new conversion to the path
* and initialize its conversion data.
*/
if (func && (!table || (table && is_api) || (table && !table->is_hard && !is_api))) {
@@ -4504,11 +4504,11 @@ H5T_path_bkg(const H5T_path_t *p)
/*-------------------------------------------------------------------------
* Function: H5T_compiler_conv
*
- * Purpose: Private function for H5Tcompiler_conv. Finds out whether the
- * library's conversion function from type SRC to type DST
+ * Purpose: Private function for H5Tcompiler_conv. Finds out whether the
+ * library's conversion function from type SRC to type DST
* is a hard conversion.
*
- * Return: TRUE: hard conversion.
+ * Return: TRUE: hard conversion.
* FALSE: soft conversion.
* FAIL: function failed.
*
diff --git a/src/H5Tconv.c b/src/H5Tconv.c
index dc56c30..1cb229a 100644
--- a/src/H5Tconv.c
+++ b/src/H5Tconv.c
@@ -551,9 +551,9 @@ H5FL_BLK_DEFINE_STATIC(array_seq);
/* Quincey added the condition branch (else if (*((ST*)S) != (ST)((DT)(*((ST*)S))))).
* It handles a special situation when the source is "float" and assigned the value
- * of "INT_MAX". Compilers do roundup making this value "INT_MAX+1". This branch
+ * of "INT_MAX". Compilers do roundup making this value "INT_MAX+1". This branch
* is to check that situation and return exception for some compilers, mainly GCC.
- * The branch if (*((ST*)S) > (DT)(D_MAX) || (sprec < dprec && *((ST*)S) ==
+ * The branch if (*((ST*)S) > (DT)(D_MAX) || (sprec < dprec && *((ST*)S) ==
* (DT)(D_MAX))) is for some compilers like Sun, HP, IBM, and SGI where under
* the same situation the "int" doesn't overflow. SLU - 2005/9/12
*/
@@ -3697,12 +3697,12 @@ H5T_conv_f_f (hid_t src_id, hid_t dst_id, H5T_cdata_t *cdata, size_t nelmts,
for (i = 0; i < tsize; i += 4) {
tmp1 = s[i];
tmp2 = s[i+1];
-
+
s[i] = s[(tsize-2)-i];
s[i+1] = s[(tsize-1)-i];
-
+
s[(tsize-2)-i] = tmp1;
- s[(tsize-1)-i] = tmp2;
+ s[(tsize-1)-i] = tmp2;
}
}
@@ -3790,7 +3790,7 @@ H5T_conv_f_f (hid_t src_id, hid_t dst_id, H5T_cdata_t *cdata, size_t nelmts,
HGOTO_ERROR(H5E_DATATYPE, H5E_CANTCONVERT, FAIL, "can't handle conversion exception")
goto padding;
-#ifdef H5_VMS
+#ifdef H5_VMS
} /*Temporary solution to handle VAX special values*/
#else /*H5_VMS*/
} else if (H5T_bit_find (s, src.u.f.epos, src.u.f.esize,
@@ -4054,12 +4054,12 @@ H5T_conv_f_f (hid_t src_id, hid_t dst_id, H5T_cdata_t *cdata, size_t nelmts,
for (i = 0; i < tsize; i += 4) {
tmp1 = d[i];
tmp2 = d[i+1];
-
+
d[i] = d[(tsize-2)-i];
d[i+1] = d[(tsize-1)-i];
-
+
d[(tsize-2)-i] = tmp1;
- d[(tsize-1)-i] = tmp2;
+ d[(tsize-1)-i] = tmp2;
}
}
@@ -9415,7 +9415,7 @@ H5T_conv_ldouble_llong (hid_t src_id, hid_t dst_id, H5T_cdata_t *cdata,
done:
FUNC_LEAVE_NOAPI(ret_value);
}
-#endif /*H5T_CONV_INTERNAL_LDOUBLE_LLONG*/
+#endif /*H5T_CONV_INTERNAL_LDOUBLE_LLONG*/
/*-------------------------------------------------------------------------
@@ -9433,7 +9433,7 @@ done:
*
*-------------------------------------------------------------------------
*/
-#if H5T_CONV_INTERNAL_LDOUBLE_ULLONG
+#if H5T_CONV_INTERNAL_LDOUBLE_ULLONG
herr_t
H5T_conv_ldouble_ullong (hid_t src_id, hid_t dst_id, H5T_cdata_t *cdata,
size_t nelmts, size_t buf_stride,
@@ -9628,12 +9628,12 @@ H5T_conv_f_i (hid_t src_id, hid_t dst_id, H5T_cdata_t *cdata, size_t nelmts,
for (i = 0; i < tsize; i += 4) {
tmp1 = s[i];
tmp2 = s[i+1];
-
+
s[i] = s[(tsize-2)-i];
s[i+1] = s[(tsize-1)-i];
-
+
s[(tsize-2)-i] = tmp1;
- s[(tsize-1)-i] = tmp2;
+ s[(tsize-1)-i] = tmp2;
}
}
@@ -10058,7 +10058,7 @@ done:
* Wednesday, April 21, 2004
* There is a new design for exception handling like overflow,
* which is passed in as a transfer property.
- *
+ *
* Raymond Lu
* Monday, March 13, 2006
* Added support for VAX floating-point types.
@@ -10083,7 +10083,7 @@ H5T_conv_i_f (hid_t src_id, hid_t dst_id, H5T_cdata_t *cdata, size_t nelmts,
uint8_t *src_rev=NULL; /*order-reversed source buffer */
uint8_t dbuf[64]; /*temp destination buffer */
uint8_t tmp1, tmp2; /*temp variables for swapping bytes*/
-
+
/* Conversion-related variables */
hsize_t expo; /*destination exponent */
hsize_t expo_max; /*maximal possible exponent value */
@@ -10428,12 +10428,12 @@ H5T_conv_i_f (hid_t src_id, hid_t dst_id, H5T_cdata_t *cdata, size_t nelmts,
for (i = 0; i < tsize; i += 4) {
tmp1 = d[i];
tmp2 = d[i+1];
-
+
d[i] = d[(tsize-2)-i];
d[i+1] = d[(tsize-1)-i];
-
+
d[(tsize-2)-i] = tmp1;
- d[(tsize-1)-i] = tmp2;
+ d[(tsize-1)-i] = tmp2;
}
}
@@ -10473,7 +10473,7 @@ done:
* Function: H5T_reverse_order
*
* Purpose: Internal assisting function to reverse the order of
- * a sequence of byte when it's big endian or VAX order.
+ * a sequence of byte when it's big endian or VAX order.
* The byte sequence simulates the endian order.
*
* Return: Success: A pointer to the reversed byte sequence
@@ -10512,6 +10512,6 @@ H5T_reverse_order(uint8_t *rev, uint8_t *s, size_t size, H5T_order_t order)
for (i=0; i<size; i++)
rev[i] = s[i];
}
-
+
FUNC_LEAVE_NOAPI(SUCCEED);
}
diff --git a/src/H5Tpkg.h b/src/H5Tpkg.h
index ee0939e..d9c519d 100644
--- a/src/H5Tpkg.h
+++ b/src/H5Tpkg.h
@@ -80,14 +80,14 @@
#define H5T_CONV_INTERNAL_FP_LDOUBLE 1
#endif /*H5_SIZEOF_LONG_DOUBLE && H5_CONVERT_DENORMAL_FLOAT*/
-/* Define an internal macro for converting all integers to long double. SGI compilers give some
+/* Define an internal macro for converting all integers to long double. SGI compilers give some
* incorrect conversions. */
#if (H5_WANT_DATA_ACCURACY && H5_INTEGER_TO_LDOUBLE_ACCURATE) || (!H5_WANT_DATA_ACCURACY)
#define H5T_CONV_INTERNAL_INTEGER_LDOUBLE 1
#endif
/* Define an internal macro for converting unsigned (long) long to floating numbers.
- * 64-bit Solaris does different rounding. */
+ * 64-bit Solaris does different rounding. */
#if (H5_WANT_DATA_ACCURACY && H5_ULONG_TO_FP_BOTTOM_BIT_ACCURATE) || (!H5_WANT_DATA_ACCURACY)
#define H5T_CONV_INTERNAL_ULONG_FP 1
#endif
@@ -106,7 +106,7 @@
#define H5T_CONV_INTERNAL_LLONG_LDOUBLE 1
#endif
-/* Define an internal macro for converting unsigned long long to floating numbers. SGI compilers give
+/* Define an internal macro for converting unsigned long long to floating numbers. SGI compilers give
* some incorect conversion. 64-bit Solaris does different rounding. Windows Visual Studio 6 does
* not support unsigned long long. */
#if (H5_WANT_DATA_ACCURACY && H5_ULLONG_TO_FP_CAST_WORKS && H5_ULONG_TO_FP_BOTTOM_BIT_ACCURATE) || \
@@ -114,10 +114,10 @@
#define H5T_CONV_INTERNAL_ULLONG_FP 1
#endif
-/* Define an internal macro for converting unsigned long long to long double. SGI compilers give
+/* Define an internal macro for converting unsigned long long to long double. SGI compilers give
* some incorect conversion. 64-bit Solaris does different rounding. Windows Visual Studio 6 does
- * not support unsigned long long. For FreeBSD(sleipnir), the last 2 bytes of mantissa are lost when
- * compiler tries to do the conversion. For Cygwin, compiler doesn't do rounding correctly.
+ * not support unsigned long long. For FreeBSD(sleipnir), the last 2 bytes of mantissa are lost when
+ * compiler tries to do the conversion. For Cygwin, compiler doesn't do rounding correctly.
* Mac OS 10.4 gives some incorrect result. */
#if (H5_WANT_DATA_ACCURACY && H5_ULLONG_TO_FP_CAST_WORKS && H5_ULONG_TO_FP_BOTTOM_BIT_ACCURATE && \
H5_ULLONG_TO_LDOUBLE_PRECISION && H5_LLONG_TO_LDOUBLE_CORRECT) || (!H5_WANT_DATA_ACCURACY && \
@@ -140,14 +140,14 @@
#define H5T_CONV_INTERNAL_LDOUBLE_UINT 1
#endif
-/* Define an internal macro for converting floating numbers to long long. The hard conversion on Windows
+/* Define an internal macro for converting floating numbers to long long. The hard conversion on Windows
* .NET 2003 has a bug and gives wrong exception value. */
#if (H5_WANT_DATA_ACCURACY && !H5_HW_FP_TO_LLONG_NOT_WORKS) || (!H5_WANT_DATA_ACCURACY)
#define H5T_CONV_INTERNAL_FP_LLONG 1
#endif
/* Define an internal macro for converting long double to long long. SGI compilers give some incorrect
- * conversions. Mac OS 10.4 gives incorrect conversions. HP-UX 11.00 compiler generates floating exception.
+ * conversions. Mac OS 10.4 gives incorrect conversions. HP-UX 11.00 compiler generates floating exception.
* The hard conversion on Windows .NET 2003 has a bug and gives wrong exception value. */
#if (H5_WANT_DATA_ACCURACY && !H5_HW_FP_TO_LLONG_NOT_WORKS && H5_LDOUBLE_TO_INTEGER_ACCURATE && \
H5_LDOUBLE_TO_INTEGER_WORKS && H5_LDOUBLE_TO_LLONG_ACCURATE) || \
@@ -155,8 +155,8 @@
#define H5T_CONV_INTERNAL_LDOUBLE_LLONG 1
#endif
-/* Define an internal macro for converting floating numbers to unsigned long long. PGI compiler does
- * roundup when the source fraction part is greater than 0.5. HP-UX compilers set the maximal number
+/* Define an internal macro for converting floating numbers to unsigned long long. PGI compiler does
+ * roundup when the source fraction part is greater than 0.5. HP-UX compilers set the maximal number
* for unsigned long long as 0x7fffffffffffffff during conversion. */
#if (H5_WANT_DATA_ACCURACY && H5_FP_TO_ULLONG_ACCURATE && H5_FP_TO_ULLONG_RIGHT_MAXIMUM) || \
(!H5_WANT_DATA_ACCURACY)
@@ -165,8 +165,8 @@
#define H5T_CONV_INTERNAL_FP_ULLONG 0
#endif
-/* Define an internal macro for converting long double to unsigned long long. SGI compilers give some
- * incorrect conversions. Mac OS 10.4 gives incorrect conversions. HP-UX 11.00 compiler generates
+/* Define an internal macro for converting long double to unsigned long long. SGI compilers give some
+ * incorrect conversions. Mac OS 10.4 gives incorrect conversions. HP-UX 11.00 compiler generates
* floating exception. */
#if (H5_WANT_DATA_ACCURACY && H5_LDOUBLE_TO_INTEGER_ACCURATE && H5_LDOUBLE_TO_INTEGER_WORKS && \
H5_FP_TO_ULLONG_ACCURATE && H5_FP_TO_ULLONG_RIGHT_MAXIMUM && H5_LDOUBLE_TO_LLONG_ACCURATE) || \
diff --git a/src/H5Vprivate.h b/src/H5Vprivate.h
index 7e2473a..5848a57 100644
--- a/src/H5Vprivate.h
+++ b/src/H5Vprivate.h
@@ -303,7 +303,7 @@ H5V_vector_inc(int n, hsize_t *v1, const hsize_t *v2)
}
/* Lookup table for general log2(n) routine */
-static const char LogTable256[] =
+static const char LogTable256[] =
{
0, 0, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3,
4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4,
@@ -352,12 +352,12 @@ H5V_log2_gen(hsize_t n)
if((ttt = (unsigned)(n >> 32)))
if((tt = (unsigned)(n >> 48)))
r = (t = (unsigned)(n >> 56)) ? 56 + LogTable256[t] : 48 + LogTable256[tt & 0xFF];
- else
+ else
r = (t = (unsigned)(n >> 40)) ? 40 + LogTable256[t] : 32 + LogTable256[ttt & 0xFF];
else
if((tt = (unsigned)(n >> 16)))
r = (t = (unsigned)(n >> 24)) ? 24 + LogTable256[t] : 16 + LogTable256[tt & 0xFF];
- else
+ else
r = (t = (unsigned)(n >> 8)) ? 8 + LogTable256[t] : LogTable256[n];
return(r);
@@ -365,9 +365,9 @@ H5V_log2_gen(hsize_t n)
/* Lookup table for specialized log2(n) of power of two routine */
-static const unsigned MultiplyDeBruijnBitPosition[32] =
+static const unsigned MultiplyDeBruijnBitPosition[32] =
{
- 0, 1, 28, 2, 29, 14, 24, 3, 30, 22, 20, 15, 25, 17, 4, 8,
+ 0, 1, 28, 2, 29, 14, 24, 3, 30, 22, 20, 15, 25, 17, 4, 8,
31, 27, 13, 23, 21, 19, 16, 7, 26, 12, 18, 6, 11, 5, 10, 9
};
diff --git a/src/H5private.h b/src/H5private.h
index 39971eb..c216f92 100644
--- a/src/H5private.h
+++ b/src/H5private.h
@@ -803,7 +803,7 @@ H5_DLL int HDrand(void);
#ifdef H5_VMS
#define HDremove(S) HDremove_all(S)
int HDremove_all(char * fname);
-#else
+#else
#define HDremove(S) remove(S)
#endif /*H5_VMS*/
#define HDrename(OLD,NEW) rename(OLD,NEW)
diff --git a/test/Makefile.am b/test/Makefile.am
index 60d05c9..949c52f 100644
--- a/test/Makefile.am
+++ b/test/Makefile.am
@@ -91,7 +91,7 @@ flush2.chkexe_: flush1.chkexe_
# Temporary files. These files are the ones created by setting the
# HDF5_NOCLEANUP environment variable and running `make test' without
# specifying a file prefix or low-level driver. Changing the file
-# prefix or low-level driver with environment variables will influence
+# prefix or low-level driver with environment variables will influence
# the temporary file name in ways that the makefile is not aware of.
CHECK_CLEANFILES+=cmpd_dset.h5 compact_dataset.h5 dataset.h5 extend.h5 istore.h5\
tfile[1-4].h5 th5s[1-3].h5 lheap.h5 fheap.h5 ohdr.h5 stab[1-2].h5 \
diff --git a/test/cache.c b/test/cache.c
index 68adc17..01859f1 100644
--- a/test/cache.c
+++ b/test/cache.c
@@ -3235,7 +3235,7 @@ check_flush_cache__multi_entry(H5C_t * cache_ptr)
/* dirty_flag = */ TRUE,
/* flags = */ H5C__NO_FLAGS_SET,
/* num_pins = */ 1,
- /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
+ /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
-1, -1, -1, -1, -1, -1, -1},
/* pin_idx[MAX_PINS] = */ {100, -1, -1, -1, -1, -1, -1, -1},
/* expected_loaded = */ TRUE,
@@ -3251,7 +3251,7 @@ check_flush_cache__multi_entry(H5C_t * cache_ptr)
/* dirty_flag = */ FALSE,
/* flags = */ H5C__NO_FLAGS_SET,
/* num_pins = */ 2,
- /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
+ /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
PICO_ENTRY_TYPE,
-1, -1, -1, -1, -1, -1},
/* pin_idx[MAX_PINS] = */ {100, 75, -1, -1, -1, -1, -1, -1},
@@ -3268,7 +3268,7 @@ check_flush_cache__multi_entry(H5C_t * cache_ptr)
/* dirty_flag = */ TRUE,
/* flags = */ H5C__NO_FLAGS_SET,
/* num_pins = */ 3,
- /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
+ /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
PICO_ENTRY_TYPE,
PICO_ENTRY_TYPE,
-1, -1, -1, -1, -1},
@@ -3397,7 +3397,7 @@ check_flush_cache__multi_entry(H5C_t * cache_ptr)
/* dirty_flag = */ TRUE,
/* flags = */ H5C__NO_FLAGS_SET,
/* num_pins = */ 1,
- /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
+ /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
-1, -1, -1, -1, -1, -1, -1},
/* pin_idx[MAX_PINS] = */ {100, -1, -1, -1, -1, -1, -1, -1},
/* expected_loaded = */ TRUE,
@@ -3413,7 +3413,7 @@ check_flush_cache__multi_entry(H5C_t * cache_ptr)
/* dirty_flag = */ FALSE,
/* flags = */ H5C__NO_FLAGS_SET,
/* num_pins = */ 2,
- /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
+ /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
PICO_ENTRY_TYPE,
-1, -1, -1, -1, -1, -1},
/* pin_idx[MAX_PINS] = */ {100, 75, -1, -1, -1, -1, -1, -1},
@@ -3430,7 +3430,7 @@ check_flush_cache__multi_entry(H5C_t * cache_ptr)
/* dirty_flag = */ TRUE,
/* flags = */ H5C__NO_FLAGS_SET,
/* num_pins = */ 3,
- /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
+ /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
PICO_ENTRY_TYPE,
PICO_ENTRY_TYPE,
-1, -1, -1, -1, -1},
@@ -3543,7 +3543,7 @@ check_flush_cache__multi_entry(H5C_t * cache_ptr)
/* dirty_flag = */ TRUE,
/* flags = */ H5C__NO_FLAGS_SET,
/* num_pins = */ 1,
- /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
+ /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
-1, -1, -1, -1, -1, -1, -1},
/* pin_idx[MAX_PINS] = */ {100, -1, -1, -1, -1, -1, -1, -1},
/* expected_loaded = */ TRUE,
@@ -3559,7 +3559,7 @@ check_flush_cache__multi_entry(H5C_t * cache_ptr)
/* dirty_flag = */ FALSE,
/* flags = */ H5C__NO_FLAGS_SET,
/* num_pins = */ 1,
- /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
+ /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
-1, -1, -1, -1, -1, -1, -1},
/* pin_idx[MAX_PINS] = */ {100, -1, -1, -1, -1, -1, -1, -1},
/* expected_loaded = */ FALSE,
@@ -3575,7 +3575,7 @@ check_flush_cache__multi_entry(H5C_t * cache_ptr)
/* dirty_flag = */ TRUE,
/* flags = */ H5C__NO_FLAGS_SET,
/* num_pins = */ 1,
- /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
+ /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
-1, -1, -1, -1, -1, -1, -1},
/* pin_idx[MAX_PINS] = */ {100, -1, -1, -1, -1, -1, -1, -1},
/* expected_loaded = */ FALSE,
@@ -3681,7 +3681,7 @@ check_flush_cache__multi_entry(H5C_t * cache_ptr)
/* dirty_flag = */ TRUE,
/* flags = */ H5C__NO_FLAGS_SET,
/* num_pins = */ 1,
- /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
+ /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
-1, -1, -1, -1, -1, -1, -1},
/* pin_idx[MAX_PINS] = */ {100, -1, -1, -1, -1, -1, -1, -1},
/* expected_loaded = */ TRUE,
@@ -3697,7 +3697,7 @@ check_flush_cache__multi_entry(H5C_t * cache_ptr)
/* dirty_flag = */ FALSE,
/* flags = */ H5C__NO_FLAGS_SET,
/* num_pins = */ 1,
- /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
+ /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
-1, -1, -1, -1, -1, -1, -1},
/* pin_idx[MAX_PINS] = */ {100, -1, -1, -1, -1, -1, -1, -1},
/* expected_loaded = */ FALSE,
@@ -3713,7 +3713,7 @@ check_flush_cache__multi_entry(H5C_t * cache_ptr)
/* dirty_flag = */ TRUE,
/* flags = */ H5C__NO_FLAGS_SET,
/* num_pins = */ 1,
- /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
+ /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
-1, -1, -1, -1, -1, -1, -1},
/* pin_idx[MAX_PINS] = */ {100, -1, -1, -1, -1, -1, -1, -1},
/* expected_loaded = */ FALSE,
@@ -3828,7 +3828,7 @@ check_flush_cache__multi_entry(H5C_t * cache_ptr)
/* dirty_flag = */ TRUE,
/* flags = */ H5C__NO_FLAGS_SET,
/* num_pins = */ 1,
- /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
+ /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
-1, -1, -1, -1, -1, -1, -1},
/* pin_idx[MAX_PINS] = */ {100, -1, -1, -1, -1, -1, -1, -1},
/* expected_loaded = */ TRUE,
@@ -3844,7 +3844,7 @@ check_flush_cache__multi_entry(H5C_t * cache_ptr)
/* dirty_flag = */ FALSE,
/* flags = */ H5C__NO_FLAGS_SET,
/* num_pins = */ 1,
- /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
+ /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
-1, -1, -1, -1, -1, -1, -1},
/* pin_idx[MAX_PINS] = */ {100, -1, -1, -1, -1, -1, -1, -1},
/* expected_loaded = */ FALSE,
@@ -3860,7 +3860,7 @@ check_flush_cache__multi_entry(H5C_t * cache_ptr)
/* dirty_flag = */ TRUE,
/* flags = */ H5C__NO_FLAGS_SET,
/* num_pins = */ 1,
- /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
+ /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
-1, -1, -1, -1, -1, -1, -1},
/* pin_idx[MAX_PINS] = */ {100, -1, -1, -1, -1, -1, -1, -1},
/* expected_loaded = */ FALSE,
@@ -3876,7 +3876,7 @@ check_flush_cache__multi_entry(H5C_t * cache_ptr)
/* dirty_flag = */ FALSE,
/* flags = */ H5C__SET_FLUSH_MARKER_FLAG,
/* num_pins = */ 1,
- /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
+ /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
-1, -1, -1, -1, -1, -1, -1},
/* pin_idx[MAX_PINS] = */ {100, -1, -1, -1, -1, -1, -1, -1},
/* expected_loaded = */ TRUE,
@@ -3892,7 +3892,7 @@ check_flush_cache__multi_entry(H5C_t * cache_ptr)
/* dirty_flag = */ TRUE,
/* flags = */ H5C__SET_FLUSH_MARKER_FLAG,
/* num_pins = */ 1,
- /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
+ /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
-1, -1, -1, -1, -1, -1, -1},
/* pin_idx[MAX_PINS] = */ {100, -1, -1, -1, -1, -1, -1, -1},
/* expected_loaded = */ TRUE,
@@ -3908,7 +3908,7 @@ check_flush_cache__multi_entry(H5C_t * cache_ptr)
/* dirty_flag = */ FALSE,
/* flags = */ H5C__SET_FLUSH_MARKER_FLAG,
/* num_pins = */ 1,
- /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
+ /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
-1, -1, -1, -1, -1, -1, -1},
/* pin_idx[MAX_PINS] = */ {100, -1, -1, -1, -1, -1, -1, -1},
/* expected_loaded = */ FALSE,
@@ -3924,7 +3924,7 @@ check_flush_cache__multi_entry(H5C_t * cache_ptr)
/* dirty_flag = */ TRUE,
/* flags = */ H5C__SET_FLUSH_MARKER_FLAG,
/* num_pins = */ 1,
- /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
+ /* pin_type[MAX_PINS] = */ {PICO_ENTRY_TYPE,
-1, -1, -1, -1, -1, -1, -1},
/* pin_idx[MAX_PINS] = */ {100, -1, -1, -1, -1, -1, -1, -1},
/* expected_loaded = */ FALSE,
@@ -4259,8 +4259,8 @@ check_flush_cache__pe_multi_entry_test(H5C_t * cache_ptr,
for ( j = 0; j < spec[i].num_pins; j++ )
{
create_pinned_entry_dependency(cache_ptr,
- spec[i].entry_type,
- spec[i].entry_index,
+ spec[i].entry_type,
+ spec[i].entry_index,
spec[i].pin_type[j],
spec[i].pin_idx[j]);
}
@@ -5709,41 +5709,41 @@ check_flush_cache__single_entry(H5C_t * cache_ptr)
*
* This yields a total of 256 tests.
*
- * The tests and their expected results are given in the spec table
+ * The tests and their expected results are given in the spec table
* below. The values assigned to the expected_cleared, expected_flushed,
* and expected_destroyed fields are somewhat arcane, so the following
* overview may be useful.
*
- * In addition to simply checking to see if the test case runs,
+ * In addition to simply checking to see if the test case runs,
* we also check to see if the desired operations take place on the
* cache entry. Thus expected_cleared is set to TRUE if we expect
* the entry to be flushed, expected_flushed is set to TRUE if we
* we expect the entry to be flushed, and expected_destroyed is set
* to TRUE if we expect the entry to be destroyed.
*
- * In this test, we are working with pinned entries which can't be
+ * In this test, we are working with pinned entries which can't be
* evicted, so expected_destroyed is always FALSE. We could pull it
* from the table, but it is a hold over from the code this test
* was adapted from, and it doesn't do any particular harm.
*
- * In general, we expect an entry to be flushed if it is dirty, and
+ * In general, we expect an entry to be flushed if it is dirty, and
* flush in invoked WITHOUT the H5C__FLUSH_CLEAR_ONLY_FLAG. However,
- * there are exceptions: If flush is invoked with the
+ * there are exceptions: If flush is invoked with the
* H5C__FLUSH_MARKED_ENTRIES_FLAG, only marked entries will be flushed.
*
* Further, unprotecting an entry with the H5C__SET_FLUSH_MARKER_FLAG
* will NOT mark the entry unless the entry has either been marked
* dirty either before or durting the unprotect call. This results in
- * some counterintuitive entries in the table. It make be useful to
+ * some counterintuitive entries in the table. It make be useful to
* look in the test code to see the exact order of operations.
- *
- * Similarly, we expect an entry to be cleared if it is dirty, and
+ *
+ * Similarly, we expect an entry to be cleared if it is dirty, and
* flush is invoked WITH the H5C__FLUSH_CLEAR_ONLY_FLAG. Again, there
- * are exceptions -- If flush is also invoked with the
+ * are exceptions -- If flush is also invoked with the
* H5C__FLUSH_MARKED_ENTRIES_FLAG, only the marked entries will be
* cleared.
- *
- * The above comments about applying unprotect with the
+ *
+ * The above comments about applying unprotect with the
* H5C__SET_FLUSH_MARKER_FLAG apply here as well.
*/
@@ -5766,7 +5766,7 @@ check_flush_cache__single_entry(H5C_t * cache_ptr)
hbool_t expected_flushed;
hbool_t expected_destroyed;
} spec[256] =
- /* pop pop
+ /* pop pop
* ent mark mark
* test entry -ry dirty mark dirty dirty unprot flush expect expect expect
* num type idx flag dirty prot pinned unpin flags flags clear flush destroy
@@ -6053,7 +6053,7 @@ check_flush_cache__single_entry(H5C_t * cache_ptr)
}
return;
-
+
} /* check_flush_cache__single_entry() */
@@ -6247,8 +6247,8 @@ check_flush_cache__single_entry_test(H5C_t * cache_ptr,
* Modifications:
*
* JRM -- 5/17/06
- * Added the pop_mark_dirty_prot and pop_mark_dirty_pinned
- * flags and supporting code to allow us to test the
+ * Added the pop_mark_dirty_prot and pop_mark_dirty_pinned
+ * flags and supporting code to allow us to test the
* H5C_mark_pinned_or_protected_entry_dirty() call. Use the
* call to mark the entry dirty while the entry is protected
* if pop_mark_dirty_prot is TRUE, and to mark the entry
@@ -6316,8 +6316,8 @@ check_flush_cache__pinned_single_entry_test(H5C_t * cache_ptr,
if ( pop_mark_dirty_prot ) {
- mark_pinned_or_protected_entry_dirty(cache_ptr,
- entry_type,
+ mark_pinned_or_protected_entry_dirty(cache_ptr,
+ entry_type,
entry_idx);
}
@@ -6332,8 +6332,8 @@ check_flush_cache__pinned_single_entry_test(H5C_t * cache_ptr,
if ( pop_mark_dirty_pinned ) {
- mark_pinned_or_protected_entry_dirty(cache_ptr,
- entry_type,
+ mark_pinned_or_protected_entry_dirty(cache_ptr,
+ entry_type,
entry_idx);
}
}
@@ -6653,7 +6653,7 @@ check_get_entry_status(void)
/*-------------------------------------------------------------------------
* Function: check_rename_entry()
*
- * Purpose: Verify that H5C_rename_entry behaves as expected. In
+ * Purpose: Verify that H5C_rename_entry behaves as expected. In
* particular, verify that it works correctly with pinned
* entries.
*
@@ -6706,7 +6706,7 @@ check_rename_entry(void)
pass = TRUE;
/* allocate a cache, load entries into it, and then rename
- * them. To the extent possible, verify that the desired
+ * them. To the extent possible, verify that the desired
* actions took place.
*
* At present, we should do the following tests:
@@ -6766,7 +6766,7 @@ check_rename_entry(void)
/*-------------------------------------------------------------------------
* Function: check_rename_entry__run_test()
*
- * Purpose: Run a rename entry test.
+ * Purpose: Run a rename entry test.
*
* Do nothing if pass is FALSE on entry.
*
@@ -6828,7 +6828,7 @@ check_rename_entry__run_test(H5C_t * cache_ptr,
"bad entry_ptr in rename test #%d.",
test_num);
failure_mssg = msg;
-
+
} else if ( spec_ptr->is_pinned ) {
flags |= H5C__PIN_ENTRY_FLAG;
@@ -6868,7 +6868,7 @@ check_rename_entry__run_test(H5C_t * cache_ptr,
( test_ptr != (H5C_cache_entry_t *)entry_ptr ) )
{
test_ptr = test_ptr->next;
- }
+ }
if ( test_ptr == NULL ) {
@@ -7427,7 +7427,7 @@ check_double_pin_err(void)
/* allocate a cache, protect an entry, unprotect it with the pin flag,
* protect it again, and then try to unprotect it again with the pin
- * flag. This should fail. Unpin the entry and destroy the cache
+ * flag. This should fail. Unpin the entry and destroy the cache
* -- should succeed.
*/
@@ -7450,7 +7450,7 @@ check_double_pin_err(void)
if ( pass ) {
result = H5C_unprotect(NULL, -1, -1, cache_ptr, &(types[0]),
- entry_ptr->addr, (void *)entry_ptr,
+ entry_ptr->addr, (void *)entry_ptr,
H5C__PIN_ENTRY_FLAG, 0);
if ( result > 0 ) {
@@ -7486,7 +7486,7 @@ check_double_pin_err(void)
/*-------------------------------------------------------------------------
* Function: check_double_unpin_err()
*
- * Purpose: Verify that an attempt to unpin an unpinned entry will
+ * Purpose: Verify that an attempt to unpin an unpinned entry will
* generate an error.
*
* Return: void
@@ -7514,7 +7514,7 @@ check_double_unpin_err(void)
pass = TRUE;
/* allocate a cache, protect an entry, unprotect it with the unpin flag.
- * -- This should fail.
+ * -- This should fail.
*
* Try again with H5C_unpin_entry -- this should also fail.
*
@@ -7536,7 +7536,7 @@ check_double_unpin_err(void)
if ( pass ) {
result = H5C_unprotect(NULL, -1, -1, cache_ptr, &(types[0]),
- entry_ptr->addr, (void *)entry_ptr,
+ entry_ptr->addr, (void *)entry_ptr,
H5C__UNPIN_ENTRY_FLAG, 0);
if ( result > 0 ) {
@@ -7613,10 +7613,10 @@ check_pin_entry_errs(void)
pass = TRUE;
/* Allocate a cache, protect an entry, unprotect it with no flags,
- * and then call H5C_pin_protected_entry() to pin it -- This should fail.
+ * and then call H5C_pin_protected_entry() to pin it -- This should fail.
*
* Protect the entry again, unprotect it with a pin flag, protect it
- * again, and then call H5C_pin_protected_entry() to pin it -- This
+ * again, and then call H5C_pin_protected_entry() to pin it -- This
* should fail also.
*
* Unprotect the entry with the unpin flag.
@@ -7791,7 +7791,7 @@ check_double_protect_err(void)
* H5C_unprotect().
*
* JRM -- 9/8/05
- * Updated function for the new size change parameter in
+ * Updated function for the new size change parameter in
* H5C_unprotect(). We don't use them for now.
*
*-------------------------------------------------------------------------
@@ -7831,7 +7831,7 @@ check_double_unprotect_err(void)
if ( pass ) {
result = H5C_unprotect(NULL, -1, -1, cache_ptr, &(types[0]),
- entry_ptr->addr, (void *)entry_ptr,
+ entry_ptr->addr, (void *)entry_ptr,
H5C__NO_FLAGS_SET, 0);
if ( result > 0 ) {
@@ -7872,7 +7872,7 @@ check_double_unprotect_err(void)
* entry as the target will generate an error.
*
* 3) a call to H5C_mark_pinned_or_protected_entry_dirty with
- * and unpinned and unprotected entry will generate an
+ * and unpinned and unprotected entry will generate an
* error.
*
* Return: void
@@ -7900,9 +7900,9 @@ check_mark_entry_dirty_errs(void)
pass = TRUE;
/* allocate a cache, protect an entry, and then attempt to mark it dirty
- * with the H5C_mark_pinned_entry_dirty() call -- This should fail.
+ * with the H5C_mark_pinned_entry_dirty() call -- This should fail.
*
- * Then unprotect the entry without pinning it, and try to mark it dirty
+ * Then unprotect the entry without pinning it, and try to mark it dirty
* again -- this should fail too.
*
* Try it again using H5C_mark_pinned_or_protected_entry_dirty -- this
@@ -7960,7 +7960,7 @@ check_mark_entry_dirty_errs(void)
if ( pass ) {
- result = H5C_mark_pinned_or_protected_entry_dirty(cache_ptr,
+ result = H5C_mark_pinned_or_protected_entry_dirty(cache_ptr,
(void *)entry_ptr);
diff --git a/test/cache_api.c b/test/cache_api.c
index c1089dd..f303601 100644
--- a/test/cache_api.c
+++ b/test/cache_api.c
@@ -15,7 +15,7 @@
/* Programmer: John Mainzer
* 11/10/05
*
- * This file contains tests for the API calls associated
+ * This file contains tests for the API calls associated
* with the cache implemented in H5C.c
*/
diff --git a/test/cache_common.c b/test/cache_common.c
index aeb9a25..ad5fe12 100644
--- a/test/cache_common.c
+++ b/test/cache_common.c
@@ -15,7 +15,7 @@
/* Programmer: John Mainzer
* 10/27/05
*
- * This file contains common code for tests of the cache
+ * This file contains common code for tests of the cache
* implemented in H5C.c
*/
#include "h5test.h"
@@ -548,11 +548,11 @@ destroy(H5F_t UNUSED * f,
pinned_base_addr = entries[entry_ptr->pin_type[i]];
pinned_entry_ptr = &(pinned_base_addr[entry_ptr->pin_idx[i]]);
- HDassert( 0 <= pinned_entry_ptr->type );
+ HDassert( 0 <= pinned_entry_ptr->type );
HDassert( pinned_entry_ptr->type < NUMBER_OF_ENTRY_TYPES );
HDassert( pinned_entry_ptr->type == entry_ptr->pin_type[i] );
HDassert( pinned_entry_ptr->index >= 0 );
- HDassert( pinned_entry_ptr->index <=
+ HDassert( pinned_entry_ptr->index <=
max_indices[pinned_entry_ptr->type] );
HDassert( pinned_entry_ptr->index == entry_ptr->pin_idx[i] );
HDassert( pinned_entry_ptr == pinned_entry_ptr->self );
@@ -564,7 +564,7 @@ destroy(H5F_t UNUSED * f,
if ( pinned_entry_ptr->pinning_ref_count <= 0 ) {
- unpin_entry(pinned_entry_ptr->cache_ptr,
+ unpin_entry(pinned_entry_ptr->cache_ptr,
pinned_entry_ptr->type,
pinned_entry_ptr->index);
}
@@ -1015,12 +1015,12 @@ monster_size(H5F_t * f, void * thing, size_t * size_ptr)
*
* Purpose: Do noting if pass is FALSE on entry.
*
- * Otherwise, set up a pinned entry dependency so we can
+ * Otherwise, set up a pinned entry dependency so we can
* test the pinned entry modifications to the flush routine.
*
* Given the types and indicies of the pinned and pinning
* entries, add the pinned entry to the list of pinned
- * entries in the pinning entry, increment the
+ * entries in the pinning entry, increment the
* pinning reference count of the pinned entry, and
* if that count was zero initially, pin the entry.
*
@@ -1048,13 +1048,13 @@ create_pinned_entry_dependency(H5C_t * cache_ptr,
if ( pass ) {
- HDassert( ( 0 <= pinning_type ) &&
+ HDassert( ( 0 <= pinning_type ) &&
( pinning_type < NUMBER_OF_ENTRY_TYPES ) );
- HDassert( ( 0 <= pinning_idx ) &&
+ HDassert( ( 0 <= pinning_idx ) &&
( pinning_idx <= max_indices[pinning_type] ) );
- HDassert( ( 0 <= pinned_type ) &&
+ HDassert( ( 0 <= pinned_type ) &&
( pinned_type < NUMBER_OF_ENTRY_TYPES ) );
- HDassert( ( 0 <= pinned_idx ) &&
+ HDassert( ( 0 <= pinned_idx ) &&
( pinned_idx <= max_indices[pinned_type] ) );
pinning_base_addr = entries[pinning_type];
@@ -1080,7 +1080,7 @@ create_pinned_entry_dependency(H5C_t * cache_ptr,
if ( pinned_entry_ptr->pinning_ref_count == 0 ) {
protect_entry(cache_ptr, pinned_type, pinned_idx);
- unprotect_entry(cache_ptr, pinned_type, pinned_idx, FALSE,
+ unprotect_entry(cache_ptr, pinned_type, pinned_idx, FALSE,
H5C__PIN_ENTRY_FLAG);
}
@@ -1585,7 +1585,7 @@ insert_entry(H5C_t * cache_ptr,
HDfprintf(stdout, "result = %d\n", (int)result);
HDfprintf(stdout, "entry_ptr->header.is_protected = %d\n",
(int)(entry_ptr->header.is_protected));
- HDfprintf(stdout,
+ HDfprintf(stdout,
"entry_ptr->header.type != &(types[type]) = %d\n",
(int)(entry_ptr->header.type != &(types[type])));
HDfprintf(stdout,
@@ -1612,7 +1612,7 @@ insert_entry(H5C_t * cache_ptr,
/*-------------------------------------------------------------------------
* Function: mark_pinned_entry_dirty()
*
- * Purpose: Mark the specified entry as dirty.
+ * Purpose: Mark the specified entry as dirty.
*
* Do nothing if pass is FALSE on entry.
*
@@ -1659,7 +1659,7 @@ mark_pinned_entry_dirty(H5C_t * cache_ptr,
entry_ptr->is_dirty = TRUE;
- result = H5C_mark_pinned_entry_dirty(cache_ptr,
+ result = H5C_mark_pinned_entry_dirty(cache_ptr,
(void *)entry_ptr,
size_changed,
new_size);
@@ -1688,7 +1688,7 @@ mark_pinned_entry_dirty(H5C_t * cache_ptr,
/*-------------------------------------------------------------------------
* Function: mark_pinned_or_protected_entry_dirty()
*
- * Purpose: Mark the specified entry as dirty.
+ * Purpose: Mark the specified entry as dirty.
*
* Do nothing if pass is FALSE on entry.
*
@@ -1727,39 +1727,39 @@ mark_pinned_or_protected_entry_dirty(H5C_t * cache_ptr,
HDassert( entry_ptr->type == type );
HDassert( entry_ptr == entry_ptr->self );
HDassert( entry_ptr->cache_ptr == cache_ptr );
- HDassert( entry_ptr->header.is_protected ||
+ HDassert( entry_ptr->header.is_protected ||
entry_ptr->header.is_pinned );
entry_ptr->is_dirty = TRUE;
- result = H5C_mark_pinned_or_protected_entry_dirty(cache_ptr,
+ result = H5C_mark_pinned_or_protected_entry_dirty(cache_ptr,
(void *)entry_ptr);
- if ( ( result < 0 )
+ if ( ( result < 0 )
||
- ( ( ! (entry_ptr->header.is_protected) )
+ ( ( ! (entry_ptr->header.is_protected) )
&&
- ( ! (entry_ptr->header.is_pinned) )
- )
+ ( ! (entry_ptr->header.is_pinned) )
+ )
||
- ( ( entry_ptr->header.is_protected )
- &&
- ( ! ( entry_ptr->header.dirtied ) )
+ ( ( entry_ptr->header.is_protected )
+ &&
+ ( ! ( entry_ptr->header.dirtied ) )
)
||
( ( ! ( entry_ptr->header.is_protected ) )
- &&
- ( ! ( entry_ptr->header.is_dirty ) )
+ &&
+ ( ! ( entry_ptr->header.is_dirty ) )
)
||
- ( entry_ptr->header.type != &(types[type]) )
+ ( entry_ptr->header.type != &(types[type]) )
||
- ( entry_ptr->size != entry_ptr->header.size )
+ ( entry_ptr->size != entry_ptr->header.size )
||
( entry_ptr->addr != entry_ptr->header.addr ) ) {
pass = FALSE;
- failure_mssg =
+ failure_mssg =
"error in H5C_mark_pinned_or_protected_entry_dirty().";
}
@@ -1951,8 +1951,8 @@ protect_entry(H5C_t * cache_ptr,
failure_mssg = "error in H5C_protect().";
} else {
-
- HDassert( ( entry_ptr->cache_ptr == NULL ) ||
+
+ HDassert( ( entry_ptr->cache_ptr == NULL ) ||
( entry_ptr->cache_ptr == cache_ptr ) );
entry_ptr->cache_ptr = cache_ptr;
diff --git a/test/cache_common.h b/test/cache_common.h
index 9186840..452824e 100644
--- a/test/cache_common.h
+++ b/test/cache_common.h
@@ -105,7 +105,7 @@
#define MONSTER_ALT_BASE_ADDR (haddr_t)(HUGE_ALT_BASE_ADDR + \
(HUGE_ENTRY_SIZE * NUM_HUGE_ENTRIES))
-#define MAX_PINS 8 /* Maximum number of entries that can be
+#define MAX_PINS 8 /* Maximum number of entries that can be
* directly pinned by a single entry.
*/
typedef struct test_entry_t
@@ -116,7 +116,7 @@ typedef struct test_entry_t
struct test_entry_t * self; /* pointer to this entry -- used for
* sanity checking.
*/
- H5C_t * cache_ptr; /* pointer to the cache in which
+ H5C_t * cache_ptr; /* pointer to the cache in which
* the entry resides, or NULL if the
* entry is not in cache.
*/
@@ -156,7 +156,7 @@ typedef struct test_entry_t
hbool_t is_pinned; /* entry is currently pinned in
* the cache.
*/
- int pinning_ref_count; /* Number of entries that
+ int pinning_ref_count; /* Number of entries that
* pin this entry in the cache.
* When this count drops to zero,
* this entry should be unpinned.
@@ -169,7 +169,7 @@ typedef struct test_entry_t
int pin_type[MAX_PINS]; /* array of the types of entries
* pinned by this entry.
*/
- int pin_idx[MAX_PINS]; /* array of the indicies of
+ int pin_idx[MAX_PINS]; /* array of the indicies of
* entries pinned by this entry.
*/
hbool_t loaded; /* entry has been loaded since the
diff --git a/test/cross_read.c b/test/cross_read.c
index 4f7391f..d24ffa9 100755
--- a/test/cross_read.c
+++ b/test/cross_read.c
@@ -16,7 +16,7 @@
* Programmer: Raymond Lu <slu@ncsa.uiuc.edu>
* Thursday, March 23, 2006
*
- * Purpose: Check if floating-point data created on OpenVMS (VAX type), Solaris,
+ * Purpose: Check if floating-point data created on OpenVMS (VAX type), Solaris,
* and Linux machines can be read on the machine running this test.
*/
@@ -116,7 +116,7 @@ static int read_data(char *fname)
H5Tclose(datatype);
H5Dclose(dataset);
H5Fclose(file);
-
+
/* Failure */
if (nerrors) {
printf("total of %d errors out of %d elements\n", nerrors, NX*NY);
diff --git a/test/dt_arith.c b/test/dt_arith.c
index dc12696..21a35b1 100644
--- a/test/dt_arith.c
+++ b/test/dt_arith.c
@@ -58,7 +58,7 @@ const char *FILENAME[] = {
/*
* Count up or down depending on whether the machine is big endian, little
- * endian, or VAX (OpenVMS). If local variable `endian' is H5T_ORDER_BE then
+ * endian, or VAX (OpenVMS). If local variable `endian' is H5T_ORDER_BE then
* the result will be I, otherwise the result will be Z-(I+1). VAX is printed
* as little endian.
*/
@@ -90,7 +90,7 @@ static int skip_overflow_tests_g = 0;
/* OpenVMS doesn't have this feature. Make sure to disable it*/
#ifdef H5_VMS
#undef HANDLE_SIGFPE
-#endif
+#endif
/*
* Decide what values of floating-point number we want to test. They are
@@ -635,7 +635,7 @@ test_hard_query(void)
printf("Can't query conversion function\n");
goto error;
}
-
+
/* Register the hard conversion from int to float. Verify the conversion
* is a hard conversion. */
H5Tregister(H5T_PERS_HARD, "int_flt", H5T_NATIVE_INT, H5T_NATIVE_FLOAT, H5T_conv_int_float);
@@ -659,7 +659,7 @@ test_hard_query(void)
/*-------------------------------------------------------------------------
* Function: expt_handle
*
- * Purpose: Gets called from test_particular_fp_integer() for data type
+ * Purpose: Gets called from test_particular_fp_integer() for data type
* conversion exceptions.
*
* Return: H5T_CONV_HANDLED 1
@@ -679,7 +679,7 @@ expt_handle(H5T_conv_except_t except_type, hid_t UNUSED src_id, hid_t UNUSED dst
signed char fill_value1 = 7;
int fill_value2 = 13;
- if(except_type == H5T_CONV_EXCEPT_RANGE_HI || except_type == H5T_CONV_EXCEPT_RANGE_LOW ||
+ if(except_type == H5T_CONV_EXCEPT_RANGE_HI || except_type == H5T_CONV_EXCEPT_RANGE_LOW ||
except_type == H5T_CONV_EXCEPT_TRUNCATE) {
if(*(hbool_t*)user_data)
*(signed char*)dst_buf = fill_value1;
@@ -696,10 +696,10 @@ expt_handle(H5T_conv_except_t except_type, hid_t UNUSED src_id, hid_t UNUSED dst
*
* Purpose: Tests hard conversions from floating numbers to integers in
* a special situation when the source is "float" and assigned
- * the value of "INT_MAX". A compiler may do roundup making
+ * the value of "INT_MAX". A compiler may do roundup making
* this value "INT_MAX+1". When this float value is casted to
- * int, overflow happens. This test makes sure the library
- * returns exception in this situation.
+ * int, overflow happens. This test makes sure the library
+ * returns exception in this situation.
*
* Also verifies the library handles conversion from double to
* signed char correctly when the value of double is SCHAR_MAX.
@@ -736,7 +736,7 @@ static int test_particular_fp_integer(void)
size_t j;
TESTING("hard particular floating number -> integer conversions");
-
+
if((dxpl_id = H5Pcreate(H5P_DATASET_XFER))<0) {
H5_FAILED();
printf("Can't create data transfer property list\n");
@@ -782,7 +782,7 @@ static int test_particular_fp_integer(void)
printf(" src = ");
for (j=0; j<src_size1; j++)
printf(" %02x", saved_buf1[ENDIAN(src_size1, j, endian)]);
-
+
HDmemcpy(&x, saved_buf1, src_size1);
printf(" %29.20e\n", x);
@@ -812,7 +812,7 @@ static int test_particular_fp_integer(void)
goto error;
}
- memcpy(&dst_i, buf2, dst_size2);
+ memcpy(&dst_i, buf2, dst_size2);
/* Print errors */
if(dst_i != fill_value) {
@@ -826,7 +826,7 @@ static int test_particular_fp_integer(void)
printf(" src = ");
for (j=0; j<src_size2; j++)
printf(" %02x", saved_buf2[ENDIAN(src_size2, j, endian)]);
-
+
HDmemcpy(&x, saved_buf2, src_size2);
printf(" %29.20e\n", x);
@@ -855,7 +855,7 @@ static int test_particular_fp_integer(void)
free(saved_buf1);
if(saved_buf2)
free(saved_buf2);
-
+
PASSED();
return 0;
@@ -2681,7 +2681,7 @@ my_isnan(dtype_t type, void *val)
}
#ifdef H5_VMS
- /* For "float" and "double" on OpenVMS/Alpha, NaN is
+ /* For "float" and "double" on OpenVMS/Alpha, NaN is
* actually a valid value of maximal value.*/
if(!retval) {
if (FLT_FLOAT==type) {
@@ -2726,15 +2726,15 @@ my_isinf(dtype_t type, int endian, unsigned char *val, size_t size,
ssize_t ret1=0, ret2=0;
bits = (unsigned char*)calloc(1, size);
-
+
#ifdef H5_VMS
if(H5T_ORDER_VAX==endian) {
for (i = 0; i < size; i += 4) {
bits[i] = val[(size-2)-i];
bits[i+1] = val[(size-1)-i];
-
+
bits[(size-2)-i] = val[i];
- bits[(size-1)-i] = val[i+1];
+ bits[(size-1)-i] = val[i+1];
}
} else {
for (i=0; i<size; i++)
@@ -2953,9 +2953,9 @@ test_conv_flt_1 (const char *name, int run_test, hid_t src, hid_t dst)
INIT_FP_NORM(float, FLT_MAX, FLT_MIN, FLT_MAX_10_EXP, FLT_MIN_10_EXP,
src_size, dst_size, buf, saved, nelmts);
} else if(src_type == FLT_DOUBLE && dst_type == FLT_FLOAT) {
- /*Temporary solution for VMS. Cap double values between maximal and minimal
+ /*Temporary solution for VMS. Cap double values between maximal and minimal
*destination values because VMS return exception when overflows or underflows.
- *Same below.*/
+ *Same below.*/
INIT_FP_NORM(double, FLT_MAX, FLT_MIN, FLT_MAX_10_EXP, FLT_MIN_10_EXP,
src_size, dst_size, buf, saved, nelmts);
} else if(src_type == FLT_DOUBLE) {
@@ -2989,7 +2989,7 @@ test_conv_flt_1 (const char *name, int run_test, hid_t src, hid_t dst)
} else
goto error;
#endif /*H5_VMS*/
-
+
break;
case TEST_DENORM:
if(src_type == FLT_FLOAT) {
@@ -3129,7 +3129,7 @@ test_conv_flt_1 (const char *name, int run_test, hid_t src, hid_t dst)
continue; /*no error*/
#ifdef H5_VMS
- /* For "float" and "double" on OpenVMS/Alpha, NaN is
+ /* For "float" and "double" on OpenVMS/Alpha, NaN is
* a valid value of maximal value.*/
if (FLT_FLOAT==src_type &&
my_isnan(src_type, saved+j*sizeof(float))) {
@@ -3266,7 +3266,7 @@ test_conv_flt_1 (const char *name, int run_test, hid_t src, hid_t dst)
for (k = 0; k < src_size; k += 4) {
tmp[k] = saved[j*src_size+(src_size-2)-k];
tmp[k+1] = saved[j*src_size+(src_size-1)-k];
-
+
tmp[(src_size-2)-k] = saved[j*src_size+k];
tmp[(src_size-1)-k] = saved[j*src_size+k+1];
}
@@ -3286,7 +3286,7 @@ test_conv_flt_1 (const char *name, int run_test, hid_t src, hid_t dst)
for (k = 0; k < src_size; k += 4) {
tmp[k] = buf[j*dst_size+(dst_size-2)-k];
tmp[k+1] = buf[j*dst_size+(dst_size-1)-k];
-
+
tmp[(dst_size-2)-k] = buf[j*dst_size+k];
tmp[(dst_size-1)-k] = buf[j*dst_size+k+1];
}
@@ -4957,7 +4957,7 @@ run_int_fp_conv(const char *name)
SKIPPED();
HDputs(" Test skipped due to compiler error in handling conversion.");
}
-#endif /* H5_LLONG_TO_LDOUBLE_CORRECT */
+#endif /* H5_LLONG_TO_LDOUBLE_CORRECT */
#if H5_ULLONG_TO_FP_CAST_WORKS && H5_ULLONG_TO_LDOUBLE_PRECISION && H5_LLONG_TO_LDOUBLE_CORRECT
nerrors += test_conv_int_fp(name, TEST_NORMAL, H5T_NATIVE_ULLONG, H5T_NATIVE_LDOUBLE);
#else /* H5_ULLONG_TO_FP_CAST_WORKS && H5_ULLONG_TO_LDOUBLE_PRECISION && H5_LLONG_TO_LDOUBLE_CORRECT */
diff --git a/test/dtypes.c b/test/dtypes.c
index 20743bd..1e082c6 100644
--- a/test/dtypes.c
+++ b/test/dtypes.c
@@ -522,7 +522,7 @@ test_compound_1(void)
printf("Operation not allowed for this type.\n");
goto error;
} /* end if */
-
+
size = 128;
H5E_BEGIN_TRY {
ret = H5Tset_precision(complex_id, size);
@@ -532,7 +532,7 @@ test_compound_1(void)
printf("Operation not allowed for this type.\n");
goto error;
} /* end if */
-
+
H5E_BEGIN_TRY {
ret = H5Tget_pad(complex_id, &lsb, &msb);
} H5E_END_TRY;
@@ -550,7 +550,7 @@ test_compound_1(void)
printf("Operation not allowed for this type.\n");
goto error;
} /* end if */
-
+
H5E_BEGIN_TRY {
lsb = H5Tget_inpad(complex_id);
} H5E_END_TRY;
@@ -3159,7 +3159,7 @@ test_conv_str_3(void)
if (H5Tget_strpad(type)<0) goto error;
if (H5Tset_offset(type, 0)<0) goto error;
if (H5Tget_order(type)<0) goto error;
-
+
H5E_BEGIN_TRY {
ret=H5Tset_precision(type, nelmts);
} H5E_END_TRY;
@@ -3168,7 +3168,7 @@ test_conv_str_3(void)
printf("Operation not allowed for this type.\n");
goto error;
} /* end if */
-
+
H5E_BEGIN_TRY {
size=H5Tget_ebias(type);
} H5E_END_TRY;
@@ -3511,10 +3511,10 @@ test_bitfield_funcs(void)
* First create a bitfield type.
*/
if((type = H5Tcopy(H5T_STD_B32LE))<0) goto error;
-
+
/*
* Offset a 12-byte value in the middle of a 16 and 32 byte
- * field. Pad unused bits with ones.
+ * field. Pad unused bits with ones.
* ____ ____ __10 1010 1010 10__ ____ ____
*/
if(H5Tset_precision(type, 12)<0) goto error;
@@ -3531,7 +3531,7 @@ test_bitfield_funcs(void)
printf("Operation not allowed for this type.\n");
goto error;
} /* end if */
-
+
H5E_BEGIN_TRY {
inpad=H5Tget_inpad(type);
} H5E_END_TRY;
@@ -3811,7 +3811,7 @@ opaque_long(void)
/*-------------------------------------------------------------------------
* Function: opaque_funcs
*
- * Purpose: Test some type functions that are and aren't supposed to
+ * Purpose: Test some type functions that are and aren't supposed to
* work with opaque type.
*
* Return: Success: 0
@@ -3839,7 +3839,7 @@ opaque_funcs(void)
/* Build opaque type */
if ((type=H5Tcreate(H5T_OPAQUE, 4))<0) TEST_ERROR
if (H5Tset_tag(type, "opaque source type")<0) TEST_ERROR
-
+
if ((size=H5Tget_size(type))==0) goto error;
H5E_BEGIN_TRY {
@@ -4351,7 +4351,7 @@ conv_except(H5T_conv_except_t except_type, hid_t UNUSED src_id, hid_t UNUSED dst
user_data->num_precision++;
else if(except_type == H5T_CONV_EXCEPT_TRUNCATE)
user_data->num_truncate++;
- else
+ else
user_data->num_other++;
return(H5T_CONV_UNHANDLED);
diff --git a/test/enum.c b/test/enum.c
index 4e97a25..f626f5c 100644
--- a/test/enum.c
+++ b/test/enum.c
@@ -428,7 +428,7 @@ test_value_dsnt_exist(void)
/*-------------------------------------------------------------------------
* Function: test_funcs
*
- * Purpose: Create an enumeration data type and test some functions
+ * Purpose: Create an enumeration data type and test some functions
* that are or aren't supposed to work with it.
*
* Return: Success: 0
@@ -468,7 +468,7 @@ test_funcs(void)
if ((size=H5Tget_offset(type))<0) goto error;
if (H5Tget_sign(type)<0) goto error;
if (H5Tget_super(type)<0) goto error;
-
+
H5E_BEGIN_TRY {
ret=H5Tset_pad(type, H5T_PAD_ZERO, H5T_PAD_ONE);
} H5E_END_TRY;
diff --git a/test/fheap.c b/test/fheap.c
index 9efa38e..67d021a 100644
--- a/test/fheap.c
+++ b/test/fheap.c
@@ -218,11 +218,11 @@ error:
* man_size
* man_alloc_size
* man_free_space
- *
+ *
* The following fields in the 'state' structure are set to
* the current state, before any block has been created:
* nobjs
- *
+ *
* Return: Success: 0
*
* Failure: 1
@@ -531,11 +531,11 @@ error:
* man_size
* man_alloc_size
* man_free_space
- *
+ *
* The following fields in the 'state' structure are set to
* the current state, before the block has been created:
* nobjs
- *
+ *
* Return: Success: 0
*
* Failure: 1
@@ -754,7 +754,7 @@ fill_root_row(H5HF_t *fh, hid_t dxpl, unsigned row, size_t obj_size,
expand_rows = 1;
else if(POWER_OF_TWO(row))
expand_rows = row;
- else
+ else
expand_rows = 0;
/* Compute first block & all blocks heap size & free space */
@@ -1061,7 +1061,7 @@ error:
* Function: fill_3rd_indirect
*
* Purpose: Insert (small) objects to fill up the free space in all direct
- * heap blocks in a third-level indirect block (which
+ * heap blocks in a third-level indirect block (which
* has one more level of indirect blocks)
*
* Return: Success: 0
@@ -1100,7 +1100,7 @@ error:
* Function: fill_3rd_indirect_row
*
* Purpose: Insert (small) objects to fill up the free space in all direct
- * heap blocks in a row of third-level indirect block (which
+ * heap blocks in a row of third-level indirect block (which
* have one more level of indirect blocks)
*
* Return: Success: 0
@@ -1140,7 +1140,7 @@ error:
* Function: fill_all_3rd_indirect_rows
*
* Purpose: Insert (small) objects to fill up the free space in all direct
- * heap blocks in all rows of third-level indirect blocks (which
+ * heap blocks in all rows of third-level indirect blocks (which
* have one more level of indirect blocks)
*
* Return: Success: 0
@@ -1180,7 +1180,7 @@ error:
* Function: fill_4th_indirect_row
*
* Purpose: Insert (small) objects to fill up the free space in all direct
- * heap blocks in a row of fourth-level indirect blocks (which
+ * heap blocks in a row of fourth-level indirect blocks (which
* have two more levels of indirect blocks)
*
* Return: Success: 0
@@ -1230,7 +1230,7 @@ error:
* Function: fill_all_4th_indirect_rows
*
* Purpose: Insert (small) objects to fill up the free space in all direct
- * heap blocks in all rows of fourth-level indirect blocks (which
+ * heap blocks in all rows of fourth-level indirect blocks (which
* have two more levels of indirect blocks)
*
* Return: Success: 0
@@ -3088,7 +3088,7 @@ test_abs_second_recursive_indirect(hid_t fapl, H5HF_create_t *cparam, fheap_test
FAIL_STACK_ERROR
} /* end if */
- /* Insert one more object, to force creation of second
+ /* Insert one more object, to force creation of second
* recursive indirect block
*/
state.man_alloc_size += DBLOCK_SIZE(fh, 0);
@@ -3406,7 +3406,7 @@ test_abs_start_2nd_recursive_indirect(hid_t fapl, H5HF_create_t *cparam, fheap_t
FAIL_STACK_ERROR
} /* end if */
- /* Insert one more object, to force creation of second
+ /* Insert one more object, to force creation of second
* recursive indirect block
*/
state.man_alloc_size += DBLOCK_SIZE(fh, 0);
@@ -4433,7 +4433,7 @@ error:
* block, fill all direct blocks in the row of indirect
* blocks that are 2 levels deep, fill all indirect blocks
* that are three levels deep, fill all rows of indirect blocks
- * that are four levels deep and start first direct block in
+ * that are four levels deep and start first direct block in
* indirect blocks five levels deep
*
* Return: Success: 0
@@ -5886,7 +5886,7 @@ error:
* Function: test_abs_fill_direct_skip_2nd_indirect_start_block_add_skipped
*
* Purpose: Test filling all direct blocks in root indirect block, then
- * add object too large for all direct blocks in first row of
+ * add object too large for all direct blocks in first row of
* indirect blocks, to force skipping a row of indirect blocks
* (and range of skipped blocks), then backfill all direct blocks
* skipped and extend to next "normal" direct block.
@@ -6254,7 +6254,7 @@ error:
* Function: test_abs_fill_direct_skip_2nd_indirect_skip_2nd_block_add_skipped
*
* Purpose: Test filling all direct blocks in root indirect block, then
- * add object too large for all direct blocks in first row of
+ * add object too large for all direct blocks in first row of
* indirect blocks, to force skipping a row of indirect blocks
* (and range of skipped blocks), then add object that is too
* large for initial block size in skipped indirect blocks, then
@@ -9644,7 +9644,7 @@ test_abs_frag_simple(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar
obj_size = DBLOCK_FREE(fh, 2) - (DBLOCK_SIZE(fh, 0) / 2);
if(add_obj(fh, dxpl, 20, obj_size, &state, NULL))
FAIL_STACK_ERROR
-
+
PASSED()
/* Close the fractal heap */
@@ -9814,7 +9814,7 @@ test_abs_frag_direct(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar
FAIL_STACK_ERROR
} /* end for */
} /* end for */
-
+
/* Check for closing & re-opening the heap */
if(tparam->reopen_heap) {
/* Close heap */
@@ -9840,7 +9840,7 @@ test_abs_frag_direct(hid_t fapl, H5HF_create_t *cparam, fheap_test_param_t *tpar
if(add_obj(fh, dxpl, 10, obj_size, &state, NULL))
FAIL_STACK_ERROR
} /* end for */
-
+
/* Check for closing & re-opening the heap */
if(tparam->reopen_heap) {
/* Close heap */
@@ -9977,7 +9977,7 @@ HDfprintf(stderr, "num_first_indirect_rows = %u\n", num_first_indirect_rows);
FAIL_STACK_ERROR
} /* end for */
} /* end for */
-
+
/* Check for closing & re-opening the heap */
if(tparam->reopen_heap) {
/* Close heap */
diff --git a/test/h5test.c b/test/h5test.c
index 3784001..be843f3 100644
--- a/test/h5test.c
+++ b/test/h5test.c
@@ -293,7 +293,7 @@ h5_fixname(const char *base_name, hid_t fapl, char *fullname, size_t size)
/* Must first check fapl is not H5P_DEFAULT (-1) because H5FD_XXX
* could be of value -1 if it is not defined.
*/
- isppdriver = H5P_DEFAULT != fapl &&
+ isppdriver = H5P_DEFAULT != fapl &&
(H5FD_MPIO==driver || H5FD_MPIPOSIX==driver);
/* Check HDF5_NOCLEANUP environment setting.
@@ -475,7 +475,7 @@ h5_rmprefix(const char *filename)
ret_ptr = filename;
else
ret_ptr++;
-
+
return(ret_ptr);
}
@@ -953,7 +953,7 @@ char* getenv_all(MPI_Comm comm, int root, const char* name)
/* use original getenv */
if(env)
HDfree(env);
- env = HDgetenv(name);
+ env = HDgetenv(name);
}else{
MPI_Comm_rank(comm, &mpi_rank);
MPI_Comm_size(comm, &mpi_size);
diff --git a/test/links.c b/test/links.c
index 3c47463..0d3388c 100644
--- a/test/links.c
+++ b/test/links.c
@@ -516,7 +516,7 @@ toomany(hid_t fapl)
hid_t gid2 = (-1); /* Datatype ID */
char objname[NAME_BUF_SIZE]; /* Object name */
ssize_t name_len; /* Length of object name */
- char filename[NAME_BUF_SIZE];
+ char filename[NAME_BUF_SIZE];
TESTING("too many links");
diff --git a/test/objcopy.c b/test/objcopy.c
index 51f06e6..daf382e 100755
--- a/test/objcopy.c
+++ b/test/objcopy.c
@@ -70,12 +70,12 @@ const char *FILENAME[] = {
#define NUM_ATTRIBUTES 4
#define ATTR_NAME_LEN 40
#define DIM_SIZE_1 12
-#define DIM_SIZE_2 6
+#define DIM_SIZE_2 6
#define CHUNK_SIZE_1 5 /* Not an even fraction of dimension sizes, so we test copying partial chunks */
#define CHUNK_SIZE_2 5
-#define NUM_SUB_GROUPS 20
-#define NUM_WIDE_LOOP_GROUPS 10
-#define NUM_DATASETS 10
+#define NUM_SUB_GROUPS 20
+#define NUM_WIDE_LOOP_GROUPS 10
+#define NUM_DATASETS 10
char src_obj_full_name[215]; /* the full path + name of the object to be copied */
@@ -185,8 +185,8 @@ addr_reset(void)
*
* Return: Non-negative on success/Negative on failure
*
- * Programmer: Peter Cao
- * Saturday, December 17, 2005
+ * Programmer: Peter Cao
+ * Saturday, December 17, 2005
*
* Modifications:
*
@@ -213,7 +213,7 @@ test_copy_attach_attribute_vl(hid_t loc_id)
for(j = 0; j < buf[i].len; j++)
((int *)buf[i].p)[j] = j+1;
} /* end for */
-
+
if ( (aid = H5Acreate(loc_id, "vlen attribute", tid, sid, H5P_DEFAULT)) < 0)
goto done;
@@ -242,8 +242,8 @@ done:
*
* Return: Non-negative on success/Negative on failure
*
- * Programmer: Peter Cao
- * Friday, September 30, 2005
+ * Programmer: Peter Cao
+ * Friday, September 30, 2005
*
* Modifications:
*
@@ -274,8 +274,8 @@ test_copy_attach_attributes(hid_t loc_id, hid_t type_id)
if ( H5Awrite(aid, H5T_NATIVE_INT, attr_data) < 0)
goto done;
- if (aid > 0)
- H5Aclose(aid);
+ if (aid > 0)
+ H5Aclose(aid);
aid = -1;
}
@@ -283,9 +283,9 @@ test_copy_attach_attributes(hid_t loc_id, hid_t type_id)
ret_value = 0;
done:
- if (sid > 0)
+ if (sid > 0)
H5Sclose(sid);
- if (aid > 0)
+ if (aid > 0)
H5Aclose(aid);
return ret_value;
@@ -300,7 +300,7 @@ done:
* Return: Non-negative on success/Negative on failure
*
* Programmer: Quincey Koziol
- * Tuesday, November 1, 2005
+ * Tuesday, November 1, 2005
*
*-------------------------------------------------------------------------
*/
@@ -337,9 +337,9 @@ test_copy_attach_paired_attributes(hid_t loc_id, hid_t loc_id2, hid_t type_id)
return 0;
done:
- if (sid > 0)
+ if (sid > 0)
H5Sclose(sid);
- if (aid > 0)
+ if (aid > 0)
H5Aclose(aid);
return -1;
@@ -354,7 +354,7 @@ done:
* Return: TRUE if attributes are equal/FALSE if they are different
*
* Programmer: Peter Cao
- * Saturday, December 17, 2005
+ * Saturday, December 17, 2005
*
*-------------------------------------------------------------------------
*/
@@ -471,7 +471,7 @@ error:
* Return: TRUE if objects have same attributes/FALSE if they are different
*
* Programmer: Quincey Koziol
- * Monday, October 31, 2005
+ * Monday, October 31, 2005
*
* Note: This isn't very general, the attributes are assumed to be
* those written in test_copy_attach_attributes().
@@ -543,7 +543,7 @@ error:
* Return: TRUE if buffer are equal/FALSE if they are different
*
* Programmer: Quincey Koziol
- * Monday, November 21, 2005
+ * Monday, November 21, 2005
*
*-------------------------------------------------------------------------
*/
@@ -602,7 +602,7 @@ error:
* Return: TRUE if datasets are equal/FALSE if they are different
*
* Programmer: Quincey Koziol
- * Tuesday, October 25, 2005
+ * Tuesday, October 25, 2005
*
*-------------------------------------------------------------------------
*/
@@ -780,7 +780,7 @@ error:
* Return: TRUE if group are equal/FALSE if they are different
*
* Programmer: Quincey Koziol
- * Monday, October 31, 2005
+ * Monday, October 31, 2005
*
*-------------------------------------------------------------------------
*/
@@ -928,8 +928,8 @@ error:
* Return: Success: 0
* Failure: number of errors
*
- * Programmer: Peter Cao
- * Friday, September 30, 2005
+ * Programmer: Peter Cao
+ * Friday, September 30, 2005
*
* Modifications:
*
@@ -973,17 +973,17 @@ test_copy_named_datatype(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the datatype from SRC to DST */
if ( H5Gcopy(fid_src, NAME_DATATYPE_SIMPLE, fid_dst, NAME_DATATYPE_SIMPLE, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the datatype for copy */
+ /* open the datatype for copy */
if ( (tid = H5Topen(fid_src, NAME_DATATYPE_SIMPLE)) < 0) TEST_ERROR;
- /* open the copied datatype */
+ /* open the copied datatype */
if ( (tid2 = H5Topen(fid_dst, NAME_DATATYPE_SIMPLE)) < 0) TEST_ERROR;
/* Compare the datatypes */
@@ -1024,7 +1024,7 @@ error:
* Failure: number of errors
*
* Programmer: Quincey Koziol
- * Tuesday, November 22, 2005
+ * Tuesday, November 22, 2005
*
*-------------------------------------------------------------------------
*/
@@ -1066,17 +1066,17 @@ test_copy_named_datatype_vl(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the datatype from SRC to DST */
if ( H5Gcopy(fid_src, NAME_DATATYPE_VL, fid_dst, NAME_DATATYPE_VL, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the datatype for copy */
+ /* open the datatype for copy */
if ( (tid = H5Topen(fid_src, NAME_DATATYPE_VL)) < 0) TEST_ERROR;
- /* open the copied datatype */
+ /* open the copied datatype */
if ( (tid2 = H5Topen(fid_dst, NAME_DATATYPE_VL)) < 0) TEST_ERROR;
/* Compare the datatypes */
@@ -1117,7 +1117,7 @@ error:
* Failure: number of errors
*
* Programmer: Quincey Koziol
- * Tuesday, November 22, 2005
+ * Tuesday, November 22, 2005
*
*-------------------------------------------------------------------------
*/
@@ -1165,17 +1165,17 @@ test_copy_named_datatype_vl_vl(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the datatype from SRC to DST */
if ( H5Gcopy(fid_src, NAME_DATATYPE_VL_VL, fid_dst, NAME_DATATYPE_VL_VL, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the datatype for copy */
+ /* open the datatype for copy */
if ( (tid = H5Topen(fid_src, NAME_DATATYPE_VL_VL)) < 0) TEST_ERROR;
- /* open the copied datatype */
+ /* open the copied datatype */
if ( (tid2 = H5Topen(fid_dst, NAME_DATATYPE_VL_VL)) < 0) TEST_ERROR;
/* Compare the datatypes */
@@ -1215,8 +1215,8 @@ error:
* Return: Success: 0
* Failure: number of errors
*
- * Programmer: Peter Cao
- * Friday, September 30, 2005
+ * Programmer: Peter Cao
+ * Friday, September 30, 2005
*
* Modifications:
*
@@ -1257,7 +1257,7 @@ test_copy_dataset_simple(hid_t fapl)
/* create 2D dataspace */
if ( (sid = H5Screate_simple(2, dim2d, NULL)) < 0) TEST_ERROR;
-
+
/* create 2D int dataset at SRC file */
if ( (did = H5Dcreate(fid_src, NAME_DATASET_SIMPLE, H5T_NATIVE_INT, sid, H5P_DEFAULT)) < 0) TEST_ERROR;
@@ -1282,17 +1282,17 @@ test_copy_dataset_simple(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the dataset from SRC to DST */
if ( H5Gcopy(fid_src, NAME_DATASET_SIMPLE, fid_dst, NAME_DATASET_SIMPLE, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the dataset for copy */
+ /* open the dataset for copy */
if ( (did = H5Dopen(fid_src, NAME_DATASET_SIMPLE)) < 0) TEST_ERROR;
- /* open the destination dataset */
+ /* open the destination dataset */
if ( (did2 = H5Dopen(fid_dst, NAME_DATASET_SIMPLE)) < 0) TEST_ERROR;
/* Check if the datasets are equal */
@@ -1335,7 +1335,7 @@ error:
* Failure: number of errors
*
* Programmer: Quincey Koziol
- * Monday, October 31, 2005
+ * Monday, October 31, 2005
*
*-------------------------------------------------------------------------
*/
@@ -1367,7 +1367,7 @@ test_copy_dataset_simple_empty(hid_t fapl)
/* create 2D dataspace */
if ( (sid = H5Screate_simple(2, dim2d, NULL)) < 0) TEST_ERROR;
-
+
/* create 2D int dataset at SRC file */
if ( (did = H5Dcreate(fid_src, NAME_DATASET_SIMPLE, H5T_NATIVE_INT, sid, H5P_DEFAULT)) < 0) TEST_ERROR;
@@ -1389,17 +1389,17 @@ test_copy_dataset_simple_empty(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the dataset from SRC to DST */
if ( H5Gcopy(fid_src, NAME_DATASET_SIMPLE, fid_dst, NAME_DATASET_SIMPLE, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the dataset for copy */
+ /* open the dataset for copy */
if ( (did = H5Dopen(fid_src, NAME_DATASET_SIMPLE)) < 0) TEST_ERROR;
- /* open the destination dataset */
+ /* open the destination dataset */
if ( (did2 = H5Dopen(fid_dst, NAME_DATASET_SIMPLE)) < 0) TEST_ERROR;
/* Check if the datasets are equal */
@@ -1440,8 +1440,8 @@ error:
* Return: Success: 0
* Failure: number of errors
*
- * Programmer: Peter Cao
- * Friday, September 30, 2005
+ * Programmer: Peter Cao
+ * Friday, September 30, 2005
*
* Modifications:
*
@@ -1519,17 +1519,17 @@ test_copy_dataset_compound(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the dataset from SRC to DST */
if ( H5Gcopy(fid_src, NAME_DATASET_COMPOUND, fid_dst, NAME_DATASET_COMPOUND, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the dataset for copy */
+ /* open the dataset for copy */
if ( (did = H5Dopen(fid_src, NAME_DATASET_COMPOUND)) < 0) TEST_ERROR;
- /* open the destination dataset */
+ /* open the destination dataset */
if ( (did2 = H5Dopen(fid_dst, NAME_DATASET_COMPOUND)) < 0) TEST_ERROR;
/* Check if the datasets are equal */
@@ -1571,8 +1571,8 @@ error:
* Return: Success: 0
* Failure: number of errors
*
- * Programmer: Peter Cao
- * Friday, September 30, 2005
+ * Programmer: Peter Cao
+ * Friday, September 30, 2005
*
* Modifications:
*
@@ -1647,17 +1647,17 @@ test_copy_dataset_chunked(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the dataset from SRC to DST */
if ( H5Gcopy(fid_src, NAME_DATASET_CHUNKED, fid_dst, NAME_DATASET_CHUNKED, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the dataset for copy */
+ /* open the dataset for copy */
if ( (did = H5Dopen(fid_src, NAME_DATASET_CHUNKED)) < 0) TEST_ERROR;
- /* open the destination dataset */
+ /* open the destination dataset */
if ( (did2 = H5Dopen(fid_dst, NAME_DATASET_CHUNKED)) < 0) TEST_ERROR;
/* Check if the datasets are equal */
@@ -1701,7 +1701,7 @@ error:
* Failure: number of errors
*
* Programmer: Quincey Koziol
- * Monday, October 31, 2005
+ * Monday, October 31, 2005
*
*-------------------------------------------------------------------------
*/
@@ -1764,17 +1764,17 @@ test_copy_dataset_chunked_empty(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the dataset from SRC to DST */
if ( H5Gcopy(fid_src, NAME_DATASET_CHUNKED, fid_dst, NAME_DATASET_CHUNKED, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the dataset for copy */
+ /* open the dataset for copy */
if ( (did = H5Dopen(fid_src, NAME_DATASET_CHUNKED)) < 0) TEST_ERROR;
- /* open the destination dataset */
+ /* open the destination dataset */
if ( (did2 = H5Dopen(fid_dst, NAME_DATASET_CHUNKED)) < 0) TEST_ERROR;
/* Check if the datasets are equal */
@@ -1818,7 +1818,7 @@ error:
* Failure: number of errors
*
* Programmer: Quincey Koziol
- * Monday, October 31, 2005
+ * Monday, October 31, 2005
*
*-------------------------------------------------------------------------
*/
@@ -1902,17 +1902,17 @@ test_copy_dataset_chunked_sparse(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the dataset from SRC to DST */
if ( H5Gcopy(fid_src, NAME_DATASET_CHUNKED, fid_dst, NAME_DATASET_CHUNKED, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the dataset for copy */
+ /* open the dataset for copy */
if ( (did = H5Dopen(fid_src, NAME_DATASET_CHUNKED)) < 0) TEST_ERROR;
- /* open the destination dataset */
+ /* open the destination dataset */
if ( (did2 = H5Dopen(fid_dst, NAME_DATASET_CHUNKED)) < 0) TEST_ERROR;
/* Check if the datasets are equal */
@@ -1955,7 +1955,7 @@ error:
* Failure: number of errors
*
* Programmer: Quincey Koziol
- * Monday, October 31, 2005
+ * Monday, October 31, 2005
*
*-------------------------------------------------------------------------
*/
@@ -2035,17 +2035,17 @@ test_copy_dataset_compressed(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the dataset from SRC to DST */
if ( H5Gcopy(fid_src, NAME_DATASET_CHUNKED, fid_dst, NAME_DATASET_CHUNKED, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the dataset for copy */
+ /* open the dataset for copy */
if ( (did = H5Dopen(fid_src, NAME_DATASET_CHUNKED)) < 0) TEST_ERROR;
- /* open the destination dataset */
+ /* open the destination dataset */
if ( (did2 = H5Dopen(fid_dst, NAME_DATASET_CHUNKED)) < 0) TEST_ERROR;
/* Check if the datasets are equal */
@@ -2091,7 +2091,7 @@ error:
* Failure: number of errors
*
* Programmer: Quincey Koziol
- * Monday, October 31, 2005
+ * Monday, October 31, 2005
*
*-------------------------------------------------------------------------
*/
@@ -2163,17 +2163,17 @@ test_copy_dataset_compact(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the dataset from SRC to DST */
if ( H5Gcopy(fid_src, NAME_DATASET_COMPACT, fid_dst, NAME_DATASET_COMPACT, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the dataset for copy */
+ /* open the dataset for copy */
if ( (did = H5Dopen(fid_src, NAME_DATASET_COMPACT)) < 0) TEST_ERROR;
- /* open the destination dataset */
+ /* open the destination dataset */
if ( (did2 = H5Dopen(fid_dst, NAME_DATASET_COMPACT)) < 0) TEST_ERROR;
/* Check if the datasets are equal */
@@ -2215,8 +2215,8 @@ error:
* Return: Success: 0
* Failure: number of errors
*
- * Programmer: Peter Cao
- * Friday, September 30, 2005
+ * Programmer: Peter Cao
+ * Friday, September 30, 2005
*
* Modifications:
*
@@ -2260,7 +2260,7 @@ test_copy_dataset_external(hid_t fapl)
/* create dataspace */
if ( (sid = H5Screate_simple(1, dim1d, NULL)) < 0) TEST_ERROR;
-
+
/* set dataset creation plist */
size = DIM_SIZE_1 * sizeof (int);
if ( (pid = H5Pcreate(H5P_DATASET_CREATE)) < 0) TEST_ERROR;
@@ -2290,7 +2290,7 @@ test_copy_dataset_external(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Don't change the address in the destination file for this test, it causes the
* external file list's heap to be at a different location and generates a false
* negative for this test. The test is _slightly_ weaker because of this, but
@@ -2304,10 +2304,10 @@ test_copy_dataset_external(hid_t fapl)
/* copy the dataset from SRC to DST */
if ( H5Gcopy(fid_src, NAME_DATASET_EXTERNAL, fid_dst, NAME_DATASET_EXTERNAL, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the dataset for copy */
+ /* open the dataset for copy */
if ( (did = H5Dopen(fid_src, NAME_DATASET_EXTERNAL)) < 0) TEST_ERROR;
- /* open the destination dataset */
+ /* open the destination dataset */
if ( (did2 = H5Dopen(fid_dst, NAME_DATASET_EXTERNAL)) < 0) TEST_ERROR;
/* Check if the datasets are equal */
@@ -2351,7 +2351,7 @@ error:
* Failure: number of errors
*
* Programmer: Quincey Koziol
- * Monday, October 31, 2005
+ * Monday, October 31, 2005
*
*-------------------------------------------------------------------------
*/
@@ -2393,7 +2393,7 @@ test_copy_dataset_named_dtype(hid_t fapl)
/* create named datatype */
if ( (tid = H5Tcopy(H5T_NATIVE_INT)) < 0) TEST_ERROR;
if ( (H5Tcommit(fid_src, NAME_DATATYPE_SIMPLE, tid)) < 0) TEST_ERROR;
-
+
/* create dataset at SRC file */
if ( (did = H5Dcreate(fid_src, NAME_DATASET_NAMED_DTYPE, tid, sid, H5P_DEFAULT)) < 0) TEST_ERROR;
@@ -2418,17 +2418,17 @@ test_copy_dataset_named_dtype(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the dataset from SRC to DST */
if ( H5Gcopy(fid_src, NAME_DATASET_NAMED_DTYPE, fid_dst, NAME_DATASET_NAMED_DTYPE, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the dataset for copy */
+ /* open the dataset for copy */
if ( (did = H5Dopen(fid_src, NAME_DATASET_NAMED_DTYPE)) < 0) TEST_ERROR;
- /* open the destination dataset */
+ /* open the destination dataset */
if ( (did2 = H5Dopen(fid_dst, NAME_DATASET_NAMED_DTYPE)) < 0) TEST_ERROR;
/* Check if the datasets are equal */
@@ -2472,7 +2472,7 @@ error:
* Failure: number of errors
*
* Programmer: Quincey Koziol
- * Tuesday, October 31, 2005
+ * Tuesday, October 31, 2005
*
*-------------------------------------------------------------------------
*/
@@ -2518,7 +2518,7 @@ test_copy_dataset_named_dtype_hier(hid_t fapl)
/* create named datatype _inside_ hierarchy to copy */
if ( (tid = H5Tcopy(H5T_NATIVE_INT)) < 0) TEST_ERROR;
if ( (H5Tcommit(gid, NAME_DATATYPE_SIMPLE, tid)) < 0) TEST_ERROR;
-
+
/* create first dataset at SRC file */
if ( (did = H5Dcreate(gid, NAME_DATASET_NAMED_DTYPE, tid, sid, H5P_DEFAULT)) < 0) TEST_ERROR;
@@ -2555,17 +2555,17 @@ test_copy_dataset_named_dtype_hier(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the dataset from SRC to DST */
if ( H5Gcopy(fid_src, NAME_GROUP_TOP, fid_dst, NAME_GROUP_TOP, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the group for copy */
+ /* open the group for copy */
if ( (gid = H5Gopen(fid_src, NAME_GROUP_TOP)) < 0) TEST_ERROR;
- /* open the destination group */
+ /* open the destination group */
if ( (gid2 = H5Gopen(fid_dst, NAME_GROUP_TOP)) < 0) TEST_ERROR;
/* Check if the groups are equal */
@@ -2611,7 +2611,7 @@ error:
* Failure: number of errors
*
* Programmer: Quincey Koziol
- * Tuesday, October 31, 2005
+ * Tuesday, October 31, 2005
*
*-------------------------------------------------------------------------
*/
@@ -2657,7 +2657,7 @@ test_copy_dataset_named_dtype_hier_outside(hid_t fapl)
/* create named datatype _outside_ hierarchy to copy */
if ( (tid = H5Tcopy(H5T_NATIVE_INT)) < 0) TEST_ERROR;
if ( (H5Tcommit(fid_src, NAME_DATATYPE_SIMPLE, tid)) < 0) TEST_ERROR;
-
+
/* create first dataset at SRC file */
if ( (did = H5Dcreate(gid, NAME_DATASET_NAMED_DTYPE, tid, sid, H5P_DEFAULT)) < 0) TEST_ERROR;
@@ -2694,17 +2694,17 @@ test_copy_dataset_named_dtype_hier_outside(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the dataset from SRC to DST */
if ( H5Gcopy(fid_src, NAME_GROUP_TOP, fid_dst, NAME_GROUP_TOP, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the group for copy */
+ /* open the group for copy */
if ( (gid = H5Gopen(fid_src, NAME_GROUP_TOP)) < 0) TEST_ERROR;
- /* open the destination group */
+ /* open the destination group */
if ( (gid2 = H5Gopen(fid_dst, NAME_GROUP_TOP)) < 0) TEST_ERROR;
/* Check if the groups are equal */
@@ -2743,14 +2743,14 @@ error:
* Function: test_copy_dataset_multi_ohdr_chunks
*
* Purpose: Create a pair of datasets that add attributes in a way that
- * creates lots of object header chunks in SRC file and copy
+ * creates lots of object header chunks in SRC file and copy
* datasets to DST file
*
* Return: Success: 0
* Failure: number of errors
*
* Programmer: Quincey Koziol
- * Tuesday, October 31, 2005
+ * Tuesday, October 31, 2005
*
*-------------------------------------------------------------------------
*/
@@ -2828,17 +2828,17 @@ test_copy_dataset_multi_ohdr_chunks(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the dataset from SRC to DST */
if ( H5Gcopy(fid_src, NAME_GROUP_TOP, fid_dst, NAME_GROUP_TOP, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the group for copy */
+ /* open the group for copy */
if ( (gid = H5Gopen(fid_src, NAME_GROUP_TOP)) < 0) TEST_ERROR;
- /* open the destination group */
+ /* open the destination group */
if ( (gid2 = H5Gopen(fid_dst, NAME_GROUP_TOP)) < 0) TEST_ERROR;
/* Check if the groups are equal */
@@ -2883,7 +2883,7 @@ error:
* Failure: number of errors
*
* Programmer: Quincey Koziol
- * Tuesday, October 31, 2005
+ * Tuesday, October 31, 2005
*
*-------------------------------------------------------------------------
*/
@@ -2929,7 +2929,7 @@ test_copy_dataset_attr_named_dtype(hid_t fapl)
/* create named datatype _outside_ hierarchy to copy */
if ( (tid = H5Tcopy(H5T_NATIVE_INT)) < 0) TEST_ERROR;
if ( (H5Tcommit(fid_src, NAME_DATATYPE_SIMPLE, tid)) < 0) TEST_ERROR;
-
+
/* create first dataset at SRC file */
if ( (did = H5Dcreate(gid, NAME_DATASET_MULTI_OHDR, tid, sid, H5P_DEFAULT)) < 0) TEST_ERROR;
@@ -2969,17 +2969,17 @@ test_copy_dataset_attr_named_dtype(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the dataset from SRC to DST */
if ( H5Gcopy(fid_src, NAME_GROUP_TOP, fid_dst, NAME_GROUP_TOP, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the group for copy */
+ /* open the group for copy */
if ( (gid = H5Gopen(fid_src, NAME_GROUP_TOP)) < 0) TEST_ERROR;
- /* open the destination group */
+ /* open the destination group */
if ( (gid2 = H5Gopen(fid_dst, NAME_GROUP_TOP)) < 0) TEST_ERROR;
/* Check if the groups are equal */
@@ -3024,8 +3024,8 @@ error:
* Return: Success: 0
* Failure: number of errors
*
- * Programmer: Peter Cao
- * Friday, September 30, 2005
+ * Programmer: Peter Cao
+ * Friday, September 30, 2005
*
*-------------------------------------------------------------------------
*/
@@ -3070,7 +3070,7 @@ test_copy_dataset_contig_vl(hid_t fapl)
/* create datatype */
if ( (tid = H5Tvlen_create(H5T_NATIVE_INT)) < 0) TEST_ERROR;
-
+
/* create dataset at SRC file */
if ( (did = H5Dcreate(fid_src, NAME_DATASET_VL, tid, sid, H5P_DEFAULT)) < 0) TEST_ERROR;
@@ -3089,17 +3089,17 @@ test_copy_dataset_contig_vl(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the dataset from SRC to DST */
if ( H5Gcopy(fid_src, NAME_DATASET_VL, fid_dst, NAME_DATASET_VL, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the dataset for copy */
+ /* open the dataset for copy */
if ( (did = H5Dopen(fid_src, NAME_DATASET_VL)) < 0) TEST_ERROR;
- /* open the destination dataset */
+ /* open the destination dataset */
if ( (did2 = H5Dopen(fid_dst, NAME_DATASET_VL)) < 0) TEST_ERROR;
/* Check if the datasets are equal */
@@ -3153,8 +3153,8 @@ error:
* Return: Success: 0
* Failure: number of errors
*
- * Programmer: Peter Cao
- * Saturday, December 10, 2005
+ * Programmer: Peter Cao
+ * Saturday, December 10, 2005
*
*-------------------------------------------------------------------------
*/
@@ -3201,7 +3201,7 @@ test_copy_dataset_chunked_vl(hid_t fapl)
/* create datatype */
if ( (tid = H5Tvlen_create(H5T_NATIVE_INT)) < 0) TEST_ERROR;
-
+
/* create and set chunk plist */
if ( (pid = H5Pcreate(H5P_DATASET_CREATE)) < 0) TEST_ERROR;
if ( H5Pset_chunk(pid, 1, chunk_dim1d) < 0) TEST_ERROR;
@@ -3227,17 +3227,17 @@ test_copy_dataset_chunked_vl(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the dataset from SRC to DST */
if ( H5Gcopy(fid_src, NAME_DATASET_VL, fid_dst, NAME_DATASET_VL, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the dataset for copy */
+ /* open the dataset for copy */
if ( (did = H5Dopen(fid_src, NAME_DATASET_VL)) < 0) TEST_ERROR;
- /* open the destination dataset */
+ /* open the destination dataset */
if ( (did2 = H5Dopen(fid_dst, NAME_DATASET_VL)) < 0) TEST_ERROR;
/* Check if the datasets are equal */
@@ -3291,8 +3291,8 @@ error:
* Return: Success: 0
* Failure: number of errors
*
- * Programmer: Peter Cao
- * Sunday, December 11, 2005
+ * Programmer: Peter Cao
+ * Sunday, December 11, 2005
*
*-------------------------------------------------------------------------
*/
@@ -3342,7 +3342,7 @@ test_copy_dataset_compact_vl(hid_t fapl)
/* create and set compact plist */
if ( (pid = H5Pcreate(H5P_DATASET_CREATE)) < 0) TEST_ERROR;
if ( H5Pset_layout(pid, H5D_COMPACT) < 0) TEST_ERROR;
-
+
/* create dataset at SRC file */
if ( (did = H5Dcreate(fid_src, NAME_DATASET_VL, tid, sid, pid)) < 0) TEST_ERROR;
@@ -3364,17 +3364,17 @@ test_copy_dataset_compact_vl(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the dataset from SRC to DST */
if ( H5Gcopy(fid_src, NAME_DATASET_VL, fid_dst, NAME_DATASET_VL, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the dataset for copy */
+ /* open the dataset for copy */
if ( (did = H5Dopen(fid_src, NAME_DATASET_VL)) < 0) TEST_ERROR;
- /* open the destination dataset */
+ /* open the destination dataset */
if ( (did2 = H5Dopen(fid_dst, NAME_DATASET_VL)) < 0) TEST_ERROR;
/* Check if the datasets are equal */
@@ -3422,14 +3422,14 @@ error:
/*-------------------------------------------------------------------------
* Function: test_copy_attribute_vl
*
- * Purpose: Create a simple dataset with vlen attributes in SRC file
+ * Purpose: Create a simple dataset with vlen attributes in SRC file
* and copy it to DST file (Note: dataset has no data)
*
* Return: Success: 0
* Failure: number of errors
*
- * Programmer: Peter Cao
- * Saturday, December , 2005
+ * Programmer: Peter Cao
+ * Saturday, December , 2005
*
*-------------------------------------------------------------------------
*/
@@ -3462,7 +3462,7 @@ test_copy_attribute_vl(hid_t fapl)
/* create 2D dataspace */
if ( (sid = H5Screate_simple(2, dim2d, NULL)) < 0) TEST_ERROR;
-
+
/* create 2D int dataset at SRC file */
if ( (did = H5Dcreate(fid_src, NAME_DATASET_SIMPLE, H5T_NATIVE_INT, sid, H5P_DEFAULT)) < 0) TEST_ERROR;
@@ -3491,10 +3491,10 @@ test_copy_attribute_vl(hid_t fapl)
/* copy the dataset from SRC to DST */
if ( H5Gcopy(fid_src, NAME_DATASET_SIMPLE, fid_dst, NAME_DATASET_SIMPLE, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the dataset for copy */
+ /* open the dataset for copy */
if ( (did = H5Dopen(fid_src, NAME_DATASET_SIMPLE)) < 0) TEST_ERROR;
- /* open the destination dataset */
+ /* open the destination dataset */
if ( (did2 = H5Dopen(fid_dst, NAME_DATASET_SIMPLE)) < 0) TEST_ERROR;
/* Check if the attributes are equal */
@@ -3537,14 +3537,14 @@ error:
/*-------------------------------------------------------------------------
* Function: test_copy_dataset_compressed_vl
*
- * Purpose: Create a compressed, chunked, VLEN dataset in SRC
+ * Purpose: Create a compressed, chunked, VLEN dataset in SRC
* file and copy it to DST file
*
* Return: Success: 0
* Failure: number of errors
*
- * Programmer: Peter Cao
- * Tuesday, December 27, 2005
+ * Programmer: Peter Cao
+ * Tuesday, December 27, 2005
*
*-------------------------------------------------------------------------
*/
@@ -3576,7 +3576,7 @@ test_copy_dataset_compressed_vl(hid_t fapl)
for (j = 0; j < DIM_SIZE_2; j++) {
buf[i][j].len = j + 1;
buf[i][j].p = (int *)HDmalloc(buf[i][j].len * sizeof(int));
- for (k = 0; k < (int)buf[i][j].len; k++)
+ for (k = 0; k < (int)buf[i][j].len; k++)
((int *)buf[i][j].p)[k] = i * 10000 + j * 100 + k;
}
}
@@ -3634,10 +3634,10 @@ test_copy_dataset_compressed_vl(hid_t fapl)
/* copy the dataset from SRC to DST */
if ( H5Gcopy(fid_src, NAME_DATASET_CHUNKED, fid_dst, NAME_DATASET_CHUNKED, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the dataset for copy */
+ /* open the dataset for copy */
if ( (did = H5Dopen(fid_src, NAME_DATASET_CHUNKED)) < 0) TEST_ERROR;
- /* open the destination dataset */
+ /* open the destination dataset */
if ( (did2 = H5Dopen(fid_dst, NAME_DATASET_CHUNKED)) < 0) TEST_ERROR;
/* Check if the datasets are equal */
@@ -3693,8 +3693,8 @@ error:
* Return: Success: 0
* Failure: number of errors
*
- * Programmer: Peter Cao
- * Friday, September 30, 2005
+ * Programmer: Peter Cao
+ * Friday, September 30, 2005
*
* Modifications:
*
@@ -3738,17 +3738,17 @@ test_copy_group_empty(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the group from SRC to DST */
if ( H5Gcopy(fid_src, NAME_GROUP_EMPTY, fid_dst, NAME_GROUP_EMPTY, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the group for copy */
+ /* open the group for copy */
if ( (gid = H5Gopen(fid_src, NAME_GROUP_EMPTY)) < 0) TEST_ERROR;
- /* open the destination group */
+ /* open the destination group */
if ( (gid2 = H5Gopen(fid_dst, NAME_GROUP_EMPTY)) < 0) TEST_ERROR;
/* Check if the groups are equal */
@@ -3788,8 +3788,8 @@ error:
* Return: Success: 0
* Failure: number of errors
*
- * Programmer: Peter Cao
- * Friday, September 30, 2005
+ * Programmer: Peter Cao
+ * Friday, September 30, 2005
*
* Modifications:
*
@@ -3842,7 +3842,7 @@ test_copy_group(hid_t fapl)
/* add a dataset to the group */
if ( (did = H5Dcreate(fid_src, NAME_GROUP_DATASET, H5T_NATIVE_INT, sid, H5P_DEFAULT) ) < 0) TEST_ERROR;
if ( H5Dwrite(did, H5T_NATIVE_INT, H5S_ALL, H5S_ALL, H5P_DEFAULT, buf) < 0) TEST_ERROR;
-
+
/* close dataspace */
if ( H5Sclose(sid) < 0) TEST_ERROR;
@@ -3869,17 +3869,17 @@ test_copy_group(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the group from SRC to DST */
if ( H5Gcopy(fid_src, NAME_GROUP_TOP, fid_dst, NAME_GROUP_TOP, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the group for copy */
+ /* open the group for copy */
if ( (gid = H5Gopen(fid_src, NAME_GROUP_TOP)) < 0) TEST_ERROR;
- /* open the destination group */
+ /* open the destination group */
if ( (gid2 = H5Gopen(fid_dst, NAME_GROUP_TOP)) < 0) TEST_ERROR;
/* Check if the groups are equal */
@@ -3923,7 +3923,7 @@ error:
* Failure: number of errors
*
* Programmer: Quincey Koziol
- * Tuesday, November 1, 2005
+ * Tuesday, November 1, 2005
*
*-------------------------------------------------------------------------
*/
@@ -4011,17 +4011,17 @@ test_copy_group_deep(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the group from SRC to DST */
if ( H5Gcopy(fid_src, NAME_GROUP_TOP, fid_dst, NAME_GROUP_TOP, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the group for copy */
+ /* open the group for copy */
if ( (gid = H5Gopen(fid_src, NAME_GROUP_TOP)) < 0) TEST_ERROR;
- /* open the destination group */
+ /* open the destination group */
if ( (gid2 = H5Gopen(fid_dst, NAME_GROUP_TOP)) < 0) TEST_ERROR;
/* Check if the groups are equal */
@@ -4065,7 +4065,7 @@ error:
* Failure: number of errors
*
* Programmer: Quincey Koziol
- * Tuesday, November 1, 2005
+ * Tuesday, November 1, 2005
*
*-------------------------------------------------------------------------
*/
@@ -4122,17 +4122,17 @@ test_copy_group_loop(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the group from SRC to DST */
if ( H5Gcopy(fid_src, NAME_GROUP_TOP, fid_dst, NAME_GROUP_TOP, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the group for copy */
+ /* open the group for copy */
if ( (gid = H5Gopen(fid_src, NAME_GROUP_TOP)) < 0) TEST_ERROR;
- /* open the destination group */
+ /* open the destination group */
if ( (gid2 = H5Gopen(fid_dst, NAME_GROUP_TOP)) < 0) TEST_ERROR;
/* Check if the groups are equal */
@@ -4175,7 +4175,7 @@ error:
* Failure: number of errors
*
* Programmer: Quincey Koziol
- * Tuesday, November 1, 2005
+ * Tuesday, November 1, 2005
*
* Note: Create groups w/lots of entries in each level, so that "dense"
* group form is used.
@@ -4251,17 +4251,17 @@ test_copy_group_wide_loop(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the group from SRC to DST */
if ( H5Gcopy(fid_src, NAME_GROUP_TOP, fid_dst, NAME_GROUP_TOP, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the group for copy */
+ /* open the group for copy */
if ( (gid = H5Gopen(fid_src, NAME_GROUP_TOP)) < 0) TEST_ERROR;
- /* open the destination group */
+ /* open the destination group */
if ( (gid2 = H5Gopen(fid_dst, NAME_GROUP_TOP)) < 0) TEST_ERROR;
/* Check if the groups are equal */
@@ -4303,8 +4303,8 @@ error:
* Return: Success: 0
* Failure: number of errors
*
- * Programmer: Peter Cao
- * Friday, September 30, 2005
+ * Programmer: Peter Cao
+ * Friday, September 30, 2005
*
* Modifications:
*
@@ -4356,7 +4356,7 @@ test_copy_group_links(hid_t fapl)
/* add a dataset to the group */
if ( (did = H5Dcreate(fid_src, NAME_LINK_DATASET, H5T_NATIVE_INT, sid, H5P_DEFAULT) ) < 0) TEST_ERROR;
if ( H5Dwrite(did, H5T_NATIVE_INT, H5S_ALL, H5S_ALL, H5P_DEFAULT, buf) < 0) TEST_ERROR;
-
+
/* close dataspace */
if ( H5Sclose(sid) < 0) TEST_ERROR;
@@ -4384,17 +4384,17 @@ test_copy_group_links(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the group from SRC to DST */
if ( H5Gcopy(fid_src, NAME_GROUP_LINK, fid_dst, NAME_GROUP_LINK, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the group for copy */
+ /* open the group for copy */
if ( (gid = H5Gopen(fid_src, NAME_GROUP_LINK)) < 0) TEST_ERROR;
- /* open the destination group */
+ /* open the destination group */
if ( (gid2 = H5Gopen(fid_dst, NAME_GROUP_LINK)) < 0) TEST_ERROR;
/* Check if the groups are equal */
@@ -4438,7 +4438,7 @@ error:
* Failure: number of errors
*
* Programmer: Quincey Koziol
- * Tuesday, September 30, 2005
+ * Tuesday, September 30, 2005
*
*-------------------------------------------------------------------------
*/
@@ -4488,7 +4488,7 @@ test_copy_soft_link(hid_t fapl)
/* add a dataset to the group */
if ( (did = H5Dcreate(fid_src, NAME_LINK_DATASET, H5T_NATIVE_INT, sid, H5P_DEFAULT) ) < 0) TEST_ERROR;
if ( H5Dwrite(did, H5T_NATIVE_INT, H5S_ALL, H5S_ALL, H5P_DEFAULT, buf) < 0) TEST_ERROR;
-
+
/* close dataspace */
if ( H5Sclose(sid) < 0) TEST_ERROR;
@@ -4510,17 +4510,17 @@ test_copy_soft_link(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the dataset from SRC to DST */
if ( H5Gcopy(fid_src, NAME_LINK_SOFT, fid_dst, NAME_DATASET_SIMPLE, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the dataset through the soft link for copy */
+ /* open the dataset through the soft link for copy */
if ( (did = H5Dopen(fid_src, NAME_LINK_SOFT)) < 0) TEST_ERROR;
- /* open the destination dataset */
+ /* open the destination dataset */
if ( (did2 = H5Dopen(fid_dst, NAME_DATASET_SIMPLE)) < 0) TEST_ERROR;
/* Check if the datasets are equal */
@@ -4564,7 +4564,7 @@ error:
* Failure: number of errors
*
* Programmer: Quincey Koziol
- * Tuesday, November 8, 2005
+ * Tuesday, November 8, 2005
*
*-------------------------------------------------------------------------
*/
@@ -4604,7 +4604,7 @@ test_copy_exist(hid_t fapl)
/* create 2D dataspace */
if ( (sid = H5Screate_simple(2, dim2d, NULL)) < 0) TEST_ERROR;
-
+
/* create 2D int dataset at SRC file */
if ( (did = H5Dcreate(fid_src, NAME_DATASET_SIMPLE, H5T_NATIVE_INT, sid, H5P_DEFAULT)) < 0) TEST_ERROR;
@@ -4629,7 +4629,7 @@ test_copy_exist(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
@@ -4666,13 +4666,13 @@ error:
* Function: test_copy_path
*
* Purpose: Create a simple dataset in SRC file and copy it to DST file
- * using a full path name
+ * using a full path name
*
* Return: Success: 0
* Failure: number of errors
*
* Programmer: Quincey Koziol
- * Tuesday, November 8, 2005
+ * Tuesday, November 8, 2005
*
*-------------------------------------------------------------------------
*/
@@ -4713,7 +4713,7 @@ test_copy_path(hid_t fapl)
/* create 2D dataspace */
if ( (sid = H5Screate_simple(2, dim2d, NULL)) < 0) TEST_ERROR;
-
+
/* create 2D int dataset at SRC file */
if ( (did = H5Dcreate(fid_src, NAME_DATASET_SIMPLE, H5T_NATIVE_INT, sid, H5P_DEFAULT)) < 0) TEST_ERROR;
@@ -4738,7 +4738,7 @@ test_copy_path(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
@@ -4761,10 +4761,10 @@ test_copy_path(hid_t fapl)
/* copy the dataset from SRC to DST, using full path */
if ( H5Gcopy(fid_src, NAME_DATASET_SIMPLE, fid_dst, NAME_DATASET_SUB_SUB, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the dataset for copy */
+ /* open the dataset for copy */
if ( (did = H5Dopen(fid_src, NAME_DATASET_SIMPLE)) < 0) TEST_ERROR;
- /* open the destination dataset */
+ /* open the destination dataset */
if ( (did2 = H5Dopen(fid_dst, NAME_DATASET_SUB_SUB)) < 0) TEST_ERROR;
/* Check if the datasets are equal */
@@ -4807,7 +4807,7 @@ error:
* Failure: number of errors
*
* Programmer: Quincey Koziol
- * Tuesday, November 8, 2005
+ * Tuesday, November 8, 2005
*
*-------------------------------------------------------------------------
*/
@@ -4839,7 +4839,7 @@ test_copy_same_file_named_datatype(hid_t fapl)
/* copy the datatype from SRC to DST */
if ( H5Gcopy(fid, NAME_DATATYPE_SIMPLE, fid, NAME_DATATYPE_SIMPLE2, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the copied datatype */
+ /* open the copied datatype */
if ( (tid2 = H5Topen(fid, NAME_DATATYPE_SIMPLE2)) < 0) TEST_ERROR;
/* Compare the datatypes */
@@ -4876,7 +4876,7 @@ error:
* Failure: number of errors
*
* Programmer: Quincey Koziol
- * Saturday, November 5, 2005
+ * Saturday, November 5, 2005
*
*-------------------------------------------------------------------------
*/
@@ -4957,7 +4957,7 @@ test_copy_dataset_compact_named_vl(hid_t fapl)
/* create and set compact plist */
if ( (pid = H5Pcreate(H5P_DATASET_CREATE)) < 0) TEST_ERROR;
if ( H5Pset_layout(pid, H5D_COMPACT) < 0) TEST_ERROR;
-
+
/* create dataset at SRC file */
if ( (did = H5Dcreate(fid_src, NAME_DATASET_VL, tid, sid, pid)) < 0) TEST_ERROR;
@@ -4982,17 +4982,17 @@ test_copy_dataset_compact_named_vl(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the dataset from SRC to DST */
if ( H5Gcopy(fid_src, NAME_DATASET_VL, fid_dst, NAME_DATASET_VL, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the dataset for copy */
+ /* open the dataset for copy */
if ( (did = H5Dopen(fid_src, NAME_DATASET_VL)) < 0) TEST_ERROR;
- /* open the destination dataset */
+ /* open the destination dataset */
if ( (did2 = H5Dopen(fid_dst, NAME_DATASET_VL)) < 0) TEST_ERROR;
/* Check if the datasets are equal */
@@ -5122,17 +5122,17 @@ test_copy_dataset_contig_named_vl(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the dataset from SRC to DST */
if ( H5Gcopy(fid_src, NAME_DATASET_VL, fid_dst, NAME_DATASET_VL, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the dataset for copy */
+ /* open the dataset for copy */
if ( (did = H5Dopen(fid_src, NAME_DATASET_VL)) < 0) TEST_ERROR;
- /* open the destination dataset */
+ /* open the destination dataset */
if ( (did2 = H5Dopen(fid_dst, NAME_DATASET_VL)) < 0) TEST_ERROR;
/* Check if the datasets are equal */
@@ -5245,7 +5245,7 @@ test_copy_dataset_chunked_named_vl(hid_t fapl)
/* create and set chunk plist */
if ( (pid = H5Pcreate(H5P_DATASET_CREATE)) < 0) TEST_ERROR;
if ( H5Pset_chunk(pid, 1, chunk_dim1d) < 0) TEST_ERROR;
-
+
/* create dataset at SRC file */
if ( (did = H5Dcreate(fid_src, NAME_DATASET_VL, tid, sid, pid)) < 0) TEST_ERROR;
@@ -5270,17 +5270,17 @@ test_copy_dataset_chunked_named_vl(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the dataset from SRC to DST */
if ( H5Gcopy(fid_src, NAME_DATASET_VL, fid_dst, NAME_DATASET_VL, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the dataset for copy */
+ /* open the dataset for copy */
if ( (did = H5Dopen(fid_src, NAME_DATASET_VL)) < 0) TEST_ERROR;
- /* open the destination dataset */
+ /* open the destination dataset */
if ( (did2 = H5Dopen(fid_dst, NAME_DATASET_VL)) < 0) TEST_ERROR;
/* Check if the datasets are equal */
@@ -5395,7 +5395,7 @@ test_copy_dataset_compressed_named_vl(hid_t fapl)
if ( (pid = H5Pcreate(H5P_DATASET_CREATE)) < 0) TEST_ERROR;
if ( H5Pset_chunk(pid, 1, chunk_dim1d) < 0) TEST_ERROR;
if ( H5Pset_deflate(pid, 9) < 0) TEST_ERROR;
-
+
/* create dataset at SRC file */
if ( (did = H5Dcreate(fid_src, NAME_DATASET_VL, tid, sid, pid)) < 0) TEST_ERROR;
@@ -5420,17 +5420,17 @@ test_copy_dataset_compressed_named_vl(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the dataset from SRC to DST */
if ( H5Gcopy(fid_src, NAME_DATASET_VL, fid_dst, NAME_DATASET_VL, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the dataset for copy */
+ /* open the dataset for copy */
if ( (did = H5Dopen(fid_src, NAME_DATASET_VL)) < 0) TEST_ERROR;
- /* open the destination dataset */
+ /* open the destination dataset */
if ( (did2 = H5Dopen(fid_dst, NAME_DATASET_VL)) < 0) TEST_ERROR;
/* Check if the datasets are equal */
@@ -5480,14 +5480,14 @@ error:
/*-------------------------------------------------------------------------
* Function: test_copy_dataset_compact_vl_vl
*
- * Purpose: Create a compact dataset w/nested VLEN datatype
+ * Purpose: Create a compact dataset w/nested VLEN datatype
* in SRC file and copy it to DST file
*
* Return: Success: 0
* Failure: number of errors
*
- * Programmer: Peter Cao
- * Saturday, February 11, 2006
+ * Programmer: Peter Cao
+ * Saturday, February 11, 2006
*
*-------------------------------------------------------------------------
*/
@@ -5554,7 +5554,7 @@ test_copy_dataset_compact_vl_vl(hid_t fapl)
/* create and set compact plist */
if ( (pid = H5Pcreate(H5P_DATASET_CREATE)) < 0) TEST_ERROR;
if ( H5Pset_layout(pid, H5D_COMPACT) < 0) TEST_ERROR;
-
+
/* create dataset at SRC file */
if ( (did = H5Dcreate(fid_src, NAME_DATASET_VL_VL, tid2, sid, pid)) < 0) TEST_ERROR;
@@ -5576,17 +5576,17 @@ test_copy_dataset_compact_vl_vl(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the dataset from SRC to DST */
if ( H5Gcopy(fid_src, NAME_DATASET_VL_VL, fid_dst, NAME_DATASET_VL_VL, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the dataset for copy */
+ /* open the dataset for copy */
if ( (did = H5Dopen(fid_src, NAME_DATASET_VL_VL)) < 0) TEST_ERROR;
- /* open the destination dataset */
+ /* open the destination dataset */
if ( (did2 = H5Dopen(fid_dst, NAME_DATASET_VL_VL)) < 0) TEST_ERROR;
/* Check if the datasets are equal */
@@ -5635,14 +5635,14 @@ error:
/*-------------------------------------------------------------------------
* Function: test_copy_dataset_contig_vl_vl
*
- * Purpose: Create a compact dataset w/nested VLEN datatype
+ * Purpose: Create a compact dataset w/nested VLEN datatype
* in SRC file and copy it to DST file
*
* Return: Success: 0
* Failure: number of errors
*
- * Programmer: Peter Cao
- * Saturday, February 11, 2006
+ * Programmer: Peter Cao
+ * Saturday, February 11, 2006
*
*-------------------------------------------------------------------------
*/
@@ -5708,7 +5708,7 @@ test_copy_dataset_contig_vl_vl(hid_t fapl)
/* create and set compact plist */
if ( (pid = H5Pcreate(H5P_DATASET_CREATE)) < 0) TEST_ERROR;
-
+
/* create dataset at SRC file */
if ( (did = H5Dcreate(fid_src, NAME_DATASET_VL_VL, tid2, sid, H5P_DEFAULT)) < 0) TEST_ERROR;
@@ -5730,17 +5730,17 @@ test_copy_dataset_contig_vl_vl(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the dataset from SRC to DST */
if ( H5Gcopy(fid_src, NAME_DATASET_VL_VL, fid_dst, NAME_DATASET_VL_VL, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the dataset for copy */
+ /* open the dataset for copy */
if ( (did = H5Dopen(fid_src, NAME_DATASET_VL_VL)) < 0) TEST_ERROR;
- /* open the destination dataset */
+ /* open the destination dataset */
if ( (did2 = H5Dopen(fid_dst, NAME_DATASET_VL_VL)) < 0) TEST_ERROR;
/* Check if the datasets are equal */
@@ -5863,7 +5863,7 @@ test_copy_dataset_chunked_vl_vl(hid_t fapl)
/* create and set chunk plist */
if ( (pid = H5Pcreate(H5P_DATASET_CREATE)) < 0) TEST_ERROR;
if ( H5Pset_chunk(pid, 1, chunk_dim1d) < 0) TEST_ERROR;
-
+
/* create dataset at SRC file */
if ( (did = H5Dcreate(fid_src, NAME_DATASET_VL_VL, tid2, sid, pid)) < 0) TEST_ERROR;
@@ -5885,16 +5885,16 @@ test_copy_dataset_chunked_vl_vl(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the dataset from SRC to DST */
if ( H5Gcopy(fid_src, NAME_DATASET_VL_VL, fid_dst, NAME_DATASET_VL_VL, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the dataset for copy */
+ /* open the dataset for copy */
if ( (did = H5Dopen(fid_src, NAME_DATASET_VL_VL)) < 0) TEST_ERROR;
- /* open the destination dataset */
+ /* open the destination dataset */
if ( (did2 = H5Dopen(fid_dst, NAME_DATASET_VL_VL)) < 0) TEST_ERROR;
/* Check if the datasets are equal */
@@ -6020,7 +6020,7 @@ test_copy_dataset_compressed_vl_vl(hid_t fapl)
if ( (pid = H5Pcreate(H5P_DATASET_CREATE)) < 0) TEST_ERROR;
if ( H5Pset_chunk(pid, 1, chunk_dim1d) < 0) TEST_ERROR;
if ( H5Pset_deflate(pid, 9) < 0) TEST_ERROR;
-
+
/* create dataset at SRC file */
if ( (did = H5Dcreate(fid_src, NAME_DATASET_VL_VL, tid2, sid, pid)) < 0) TEST_ERROR;
@@ -6042,16 +6042,16 @@ test_copy_dataset_compressed_vl_vl(hid_t fapl)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
+
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
/* copy the dataset from SRC to DST */
if ( H5Gcopy(fid_src, NAME_DATASET_VL_VL, fid_dst, NAME_DATASET_VL_VL, H5P_DEFAULT) < 0) TEST_ERROR;
- /* open the dataset for copy */
+ /* open the dataset for copy */
if ( (did = H5Dopen(fid_src, NAME_DATASET_VL_VL)) < 0) TEST_ERROR;
- /* open the destination dataset */
+ /* open the destination dataset */
if ( (did2 = H5Dopen(fid_dst, NAME_DATASET_VL_VL)) < 0) TEST_ERROR;
/* Check if the datasets are equal */
@@ -6107,8 +6107,8 @@ error:
* Return: Success: 0
* Failure: number of errors
*
- * Programmer: Peter Cao
- * March 11, 2006
+ * Programmer: Peter Cao
+ * March 11, 2006
*
* Modifications:
*
@@ -6221,8 +6221,8 @@ test_copy_option(hid_t fapl, unsigned flag, const char* test_desciption)
/* create destination file */
if ( (fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR;
-
- /* Create an uncopied object in destination file so that addresses in source and destination
+
+ /* Create an uncopied object in destination file so that addresses in source and destination
files aren't the same */
if ( H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR;
@@ -6240,10 +6240,10 @@ test_copy_option(hid_t fapl, unsigned flag, const char* test_desciption)
if ((flag & H5G_COPY_CREATE_INTERMEDIATE_GROUP_FLAG) > 0) {
if ( H5Gcopy(fid_src, NAME_GROUP_TOP, fid_dst, "/new_g0/new_g00", pid) < 0) TEST_ERROR;
- /* open the group for copy */
+ /* open the group for copy */
if ( (gid = H5Gopen(fid_src, NAME_GROUP_TOP)) < 0) TEST_ERROR;
- /* open the destination group */
+ /* open the destination group */
if ( (gid2 = H5Gopen(fid_dst, "/new_g0/new_g00")) < 0) TEST_ERROR;
} else if ((flag & H5G_COPY_EXPAND_SOFT_LINK_FLAG) > 0) {
@@ -6253,27 +6253,27 @@ test_copy_option(hid_t fapl, unsigned flag, const char* test_desciption)
/* (So group comparison works properly) */
if ( H5Gunlink(fid_src, NAME_DATASET_SUB_SUB) < 0) TEST_ERROR;
- /* open the group for copy */
+ /* open the group for copy */
if ( (gid = H5Gopen(fid_src, NAME_GROUP_LINK2)) < 0) TEST_ERROR;
- /* open the destination group */
+ /* open the destination group */
if ( (gid2 = H5Gopen(fid_dst, NAME_GROUP_LINK)) < 0) TEST_ERROR;
} else if(flag & H5G_COPY_WITHOUT_ATTR_FLAG) {
if ( H5Gcopy(fid_src, NAME_GROUP_TOP, fid_dst, NAME_GROUP_TOP, pid) < 0) TEST_ERROR;
- /* open the group for copy */
+ /* open the group for copy */
if ( (gid = H5Gopen(fid_src, NAME_GROUP_TOP)) < 0) TEST_ERROR;
- /* open the destination group */
+ /* open the destination group */
if ( (gid2 = H5Gopen(fid_dst, NAME_GROUP_TOP)) < 0) TEST_ERROR;
} else if(flag & H5G_COPY_SHALLOW_HIERARCHY_FLAG) {
if ( H5Gcopy(fid_src, NAME_GROUP_TOP, fid_dst, NAME_GROUP_TOP, pid) < 0) TEST_ERROR;
- /* open the group for copy */
+ /* open the group for copy */
if ( (gid = H5Gopen(fid_src, NAME_GROUP_TOP)) < 0) TEST_ERROR;
- /* open the destination group */
+ /* open the destination group */
if ( (gid2 = H5Gopen(fid_dst, NAME_GROUP_TOP)) < 0) TEST_ERROR;
/* Set the copy depth */
@@ -6320,20 +6320,20 @@ error:
/*-------------------------------------------------------------------------
- * Function: main
+ * Function: main
*
- * Purpose: Test H5Gcopy()
+ * Purpose: Test H5Gcopy()
*
* Return: Non-negative on success/Negative on failure
*
- * Programmer: Peter Cao
- * Friday, September 30, 2005
+ * Programmer: Peter Cao
+ * Friday, September 30, 2005
*
* Modifications:
*
*-------------------------------------------------------------------------
*/
-int
+int
main(void)
{
int nerrors = 0;
@@ -6378,18 +6378,18 @@ main(void)
nerrors += test_copy_group(fapl);
nerrors += test_copy_group_deep(fapl);
nerrors += test_copy_group_loop(fapl);
- nerrors += test_copy_group_wide_loop(fapl);
- nerrors += test_copy_group_links(fapl);
- nerrors += test_copy_soft_link(fapl);
- nerrors += test_copy_exist(fapl);
- nerrors += test_copy_path(fapl);
- nerrors += test_copy_same_file_named_datatype(fapl);
+ nerrors += test_copy_group_wide_loop(fapl);
+ nerrors += test_copy_group_links(fapl);
+ nerrors += test_copy_soft_link(fapl);
+ nerrors += test_copy_exist(fapl);
+ nerrors += test_copy_path(fapl);
+ nerrors += test_copy_same_file_named_datatype(fapl);
nerrors += test_copy_option(fapl, H5G_COPY_WITHOUT_ATTR_FLAG, "H5Gcopy(): without attributes");
nerrors += test_copy_option(fapl, H5G_COPY_CREATE_INTERMEDIATE_GROUP_FLAG, "H5Gcopy(): with missing groups");
nerrors += test_copy_option(fapl, H5G_COPY_EXPAND_SOFT_LINK_FLAG, "H5Gcopy(): expand soft link");
nerrors += test_copy_option(fapl, H5G_COPY_SHALLOW_HIERARCHY_FLAG, "H5Gcopy(): shallow group copy");
-/* TODO: not implemented
+/* TODO: not implemented
nerrors += test_copy_option(fapl, H5G_COPY_EXPAND_EXT_LINK_FLAG, "H5Gcopy: expand external link");
nerrors += test_copy_option(fapl, H5G_COPY_EXPAND_EXPAND_OBJ_REFERENCE_FLAG, "H5Gcopy: expand object reference");
*/
@@ -6397,7 +6397,7 @@ main(void)
/* TODO: Add more tests for copying objects in same file */
-/* TODO: Add more tests for copying objects in mounted files
+/* TODO: Add more tests for copying objects in mounted files
nerrors += test_copy_mount(fapl);
*/
diff --git a/test/stab.c b/test/stab.c
index 09a5438..945dca6 100644
--- a/test/stab.c
+++ b/test/stab.c
@@ -290,7 +290,7 @@ lifecycle(hid_t fapl)
unsigned nmsgs; /* Number of messages in group's header */
H5G_stat_t obj_stat; /* Object info */
char objname[NAME_BUF_SIZE]; /* Object name */
- char filename[NAME_BUF_SIZE];
+ char filename[NAME_BUF_SIZE];
off_t empty_size; /* Size of an empty file */
unsigned u; /* Local index variable */
off_t file_size; /* Size of each file created */
@@ -505,7 +505,7 @@ long_compact(hid_t fapl)
hid_t gid = (-1); /* Group ID */
hid_t gid2 = (-1); /* Group ID */
char *objname; /* Object name */
- char filename[NAME_BUF_SIZE];
+ char filename[NAME_BUF_SIZE];
off_t empty_size; /* Size of an empty file */
off_t file_size; /* Size of each file created */
@@ -750,7 +750,7 @@ no_compact(hid_t fapl)
hid_t gid2 = (-1); /* Datatype ID */
hid_t gcpl = (-1); /* Group creation property list ID */
char objname[NAME_BUF_SIZE]; /* Object name */
- char filename[NAME_BUF_SIZE];
+ char filename[NAME_BUF_SIZE];
off_t empty_size; /* Size of an empty file */
off_t file_size; /* Size of each file created */
size_t lheap_size_hint; /* Local heap size */
@@ -875,7 +875,7 @@ gcpl_on_root(hid_t fapl)
hid_t gcpl = (-1); /* Group creation property list ID */
unsigned max_compact; /* Maximum # of links to store in group compactly */
unsigned min_dense; /* Minimum # of links to store in group "densely" */
- char filename[NAME_BUF_SIZE];
+ char filename[NAME_BUF_SIZE];
TESTING("setting root group creation properties");
diff --git a/test/testframe.c b/test/testframe.c
index 639bded..e628d14 100644
--- a/test/testframe.c
+++ b/test/testframe.c
@@ -378,7 +378,7 @@ int SetTestVerbosity(int newval)
/*
* Retrieve the TestExpress mode for the testing framework
- Values:
+ Values:
0: Exhaustive run
Tests should take as long as necessary
1: Full run. Default if HDF5TestExpress is not defined
@@ -398,7 +398,7 @@ int SetTestVerbosity(int newval)
sub-tests.
The standard system for test times is a Linux machine running in
NFS space (to catch tests that involve a great deal of disk I/O).
-
+
Implementation:
I think this can be easily implemented in the test library (libh5test.a)
so that all tests can just call it to check the status of $HDF5TestExpress.
diff --git a/test/tfile.c b/test/tfile.c
index fd0f02c..19772ca 100644
--- a/test/tfile.c
+++ b/test/tfile.c
@@ -1659,8 +1659,8 @@ test_file_getname(void)
static void
test_file_double_root_open(void)
{
- hid_t file1_id, file2_id;
- hid_t grp1_id, grp2_id;
+ hid_t file1_id, file2_id;
+ hid_t grp1_id, grp2_id;
herr_t ret; /* Generic return value */
/* Output message about test being performed */
@@ -1698,8 +1698,8 @@ test_file_double_root_open(void)
static void
test_file_double_group_open(void)
{
- hid_t file1_id, file2_id;
- hid_t grp1_id, grp2_id;
+ hid_t file1_id, file2_id;
+ hid_t grp1_id, grp2_id;
herr_t ret; /* Generic return value */
/* Output message about test being performed */
@@ -1737,9 +1737,9 @@ test_file_double_group_open(void)
static void
test_file_double_dataset_open(void)
{
- hid_t file1_id, file2_id;
- hid_t dset1_id, dset2_id;
- hid_t space_id;
+ hid_t file1_id, file2_id;
+ hid_t dset1_id, dset2_id;
+ hid_t space_id;
herr_t ret; /* Generic return value */
/* Output message about test being performed */
@@ -1785,8 +1785,8 @@ test_file_double_dataset_open(void)
static void
test_file_double_datatype_open(void)
{
- hid_t file1_id, file2_id;
- hid_t type1_id, type2_id;
+ hid_t file1_id, file2_id;
+ hid_t type1_id, type2_id;
herr_t ret; /* Generic return value */
/* Output message about test being performed */
diff --git a/test/tselect.c b/test/tselect.c
index a8f199f..030d8b7 100644
--- a/test/tselect.c
+++ b/test/tselect.c
@@ -147,7 +147,7 @@
#define SPACERE3_RANK 3
#define SPACERE3_DIM0 8
#define SPACERE3_DIM1 12
-#define SPACERE3_DIM2 8
+#define SPACERE3_DIM2 8
#define SPACERE4_RANK 4
#define SPACERE4_DIM0 8
#define SPACERE4_DIM1 12
@@ -6558,8 +6558,8 @@ test_shape_same(void)
**
** test_space_rebuild(): Tests selection rebuild routine,
** We will test whether selection in span-tree form can be rebuilt
-** into a regular selection.
-**
+** into a regular selection.
+**
**
****************************************************************/
static void
@@ -6567,12 +6567,12 @@ test_space_rebuild(void)
{
/* regular space IDs in span-tree form */
- hid_t sid_reg1,sid_reg2,sid_reg3,sid_reg4,sid_reg5;
-
- /* Original regular Space IDs */
- hid_t sid_reg_ori1,sid_reg_ori2,sid_reg_ori3,sid_reg_ori4,sid_reg_ori5;
+ hid_t sid_reg1,sid_reg2,sid_reg3,sid_reg4,sid_reg5;
+
+ /* Original regular Space IDs */
+ hid_t sid_reg_ori1,sid_reg_ori2,sid_reg_ori3,sid_reg_ori4,sid_reg_ori5;
- /* Irregular space IDs */
+ /* Irregular space IDs */
hid_t sid_irreg1,sid_irreg2,sid_irreg3,sid_irreg4,sid_irreg5;
/* rebuild status state */
@@ -6589,22 +6589,22 @@ test_space_rebuild(void)
/* The start of the hyperslab */
hsize_t start1[SPACERE1_RANK],start2[SPACERE2_RANK],
start3[SPACERE3_RANK],start4[SPACERE4_RANK],
- start5[SPACERE5_RANK];
+ start5[SPACERE5_RANK];
/* The stride of the hyperslab */
hsize_t stride1[SPACERE1_RANK],stride2[SPACERE2_RANK],
stride3[SPACERE3_RANK],stride4[SPACERE4_RANK],
- stride5[SPACERE5_RANK];
+ stride5[SPACERE5_RANK];
/* The number of blocks for the hyperslab */
hsize_t count1[SPACERE1_RANK],count2[SPACERE2_RANK],
count3[SPACERE3_RANK],count4[SPACERE4_RANK],
- count5[SPACERE5_RANK];
+ count5[SPACERE5_RANK];
/* The size of each block for the hyperslab */
hsize_t block1[SPACERE1_RANK],block2[SPACERE2_RANK],
block3[SPACERE3_RANK],block4[SPACERE4_RANK],
- block5[SPACERE5_RANK];
+ block5[SPACERE5_RANK];
/* Declarations for special test of rebuild */
hid_t sid_spec;
@@ -6612,7 +6612,7 @@ test_space_rebuild(void)
/* Output message about test being performed */
MESSAGE(6, ("Testing functionality to rebuild regular hyperslab selection\n"));
-
+
MESSAGE(7, ("Testing functionality to rebuild 1-D hyperslab selection\n"));
@@ -6621,7 +6621,7 @@ test_space_rebuild(void)
sid_reg_ori1 = H5Screate_simple(SPACERE1_RANK,dims1,NULL);
/* Build up the original one dimensional regular selection */
- start1[0] = 1;
+ start1[0] = 1;
count1[0] = 3;
stride1[0] = 5;
block1[0] = 4;
@@ -6631,19 +6631,19 @@ test_space_rebuild(void)
/* Build up one dimensional regular selection with H5_SELECT_OR,
inside HDF5, it will be treated as an irregular selection. */
- start1[0] = 1;
+ start1[0] = 1;
count1[0] = 2;
stride1[0] = 5;
block1[0] = 4;
ret = H5Sselect_hyperslab(sid_reg1,H5S_SELECT_SET,start1,stride1,count1,block1);
- CHECK(ret, FAIL, "H5Sselect_hyperslab");
+ CHECK(ret, FAIL, "H5Sselect_hyperslab");
- start1[0] = 11;
+ start1[0] = 11;
count1[0] = 1;
stride1[0] = 5;
block1[0] = 4;
ret = H5Sselect_hyperslab(sid_reg1,H5S_SELECT_OR,start1,stride1,count1,block1);
- CHECK(ret, FAIL, "H5Sselect_hyperslab");
+ CHECK(ret, FAIL, "H5Sselect_hyperslab");
rebuild_stat = FALSE;
rebuild_stat = H5S_get_rebuild_status_test(sid_reg1);
@@ -6661,24 +6661,24 @@ test_space_rebuild(void)
/* For irregular hyperslab */
sid_irreg1 = H5Screate_simple(SPACERE1_RANK,dims1,NULL);
-
+
/* Build up one dimensional irregular selection with H5_SELECT_OR */
- start1[0] = 1;
+ start1[0] = 1;
count1[0] = 2;
stride1[0] = 5;
block1[0] = 4;
ret = H5Sselect_hyperslab(sid_irreg1,H5S_SELECT_SET,start1,stride1,count1,block1);
- CHECK(ret, FAIL, "H5Sselect_hyperslab");
+ CHECK(ret, FAIL, "H5Sselect_hyperslab");
start1[0] = 12; /* Just one position switch */
count1[0] = 1;
stride1[0] = 5;
block1[0] = 4;
ret = H5Sselect_hyperslab(sid_irreg1,H5S_SELECT_OR,start1,stride1,count1,block1);
- CHECK(ret, FAIL, "H5Sselect_hyperslab");
+ CHECK(ret, FAIL, "H5Sselect_hyperslab");
rebuild_stat = TRUE;
- rebuild_stat = H5S_get_rebuild_status_test(sid_irreg1);
+ rebuild_stat = H5S_get_rebuild_status_test(sid_irreg1);
assert(rebuild_stat!=FAIL);
/* In this case, rebuild_stat should be FALSE. */
if(rebuild_stat){
@@ -6686,14 +6686,14 @@ test_space_rebuild(void)
CHECK(ret,FAIL,"H5S_hyper_rebuild");
}/* No need to do shape comparision */
-
+
MESSAGE(7, ("Testing functionality to rebuild 2-D hyperslab selection\n"));
/* Create 2-D dataspace */
sid_reg2 = H5Screate_simple(SPACERE2_RANK,dims2,NULL);
sid_reg_ori2 = H5Screate_simple(SPACERE2_RANK,dims2,NULL);
/* Build up the original two dimensional regular selection */
- start2[0] = 2;
+ start2[0] = 2;
count2[0] = 2;
stride2[0] = 7;
block2[0] = 5;
@@ -6714,7 +6714,7 @@ test_space_rebuild(void)
block2[1] = 2;
ret = H5Sselect_hyperslab(sid_reg2,H5S_SELECT_SET,start2,stride2,count2,block2);
- CHECK(ret, FAIL, "H5Sselect_hyperslab");
+ CHECK(ret, FAIL, "H5Sselect_hyperslab");
start2[1] = 7; /* 7 = start(1) + count(2) * stride(3) */
count2[1] = 1;
@@ -6722,10 +6722,10 @@ test_space_rebuild(void)
block2[1] = 2;
ret = H5Sselect_hyperslab(sid_reg2,H5S_SELECT_OR,start2,stride2,count2,block2);
- CHECK(ret, FAIL, "H5Sselect_hyperslab");
+ CHECK(ret, FAIL, "H5Sselect_hyperslab");
rebuild_stat = FALSE;
- rebuild_stat = H5S_get_rebuild_status_test(sid_reg2);
+ rebuild_stat = H5S_get_rebuild_status_test(sid_reg2);
assert(rebuild_stat!=FAIL);
/* In this case, rebuild_stat should be TRUE. */
if(!rebuild_stat){
@@ -6742,7 +6742,7 @@ test_space_rebuild(void)
sid_irreg2 = H5Screate_simple(SPACERE2_RANK,dims2,NULL);
/* Build up two dimensional irregular selection with H5_SELECT_OR */
- start2[0] = 2;
+ start2[0] = 2;
count2[0] = 2;
stride2[0] = 7;
block2[0] = 5;
@@ -6751,15 +6751,15 @@ test_space_rebuild(void)
stride2[1] = 3;
block2[1] = 2;
ret = H5Sselect_hyperslab(sid_irreg2,H5S_SELECT_SET,start2,stride2,count2,block2);
- CHECK(ret, FAIL, "H5Sselect_hyperslab");
+ CHECK(ret, FAIL, "H5Sselect_hyperslab");
start2[1] = 4;
- count2[1] = 2;
+ count2[1] = 2;
stride2[1] = 4;
block2[1] = 3; /* Just add one element for the block */
-
+
ret = H5Sselect_hyperslab(sid_irreg2,H5S_SELECT_OR,start2,stride2,count2,block2);
- CHECK(ret, FAIL, "H5Sselect_hyperslab");
+ CHECK(ret, FAIL, "H5Sselect_hyperslab");
rebuild_stat = TRUE;
rebuild_stat = H5S_get_rebuild_status_test(sid_irreg2);
@@ -6777,7 +6777,7 @@ test_space_rebuild(void)
sid_reg_ori3 = H5Screate_simple(SPACERE3_RANK,dims3,NULL);
/* Build up the original three dimensional regular selection */
- start3[0] = 2;
+ start3[0] = 2;
count3[0] = 2;
stride3[0] = 3;
block3[0] = 2;
@@ -6790,7 +6790,7 @@ test_space_rebuild(void)
count3[2] = 2;
stride3[2] = 4;
block3[2] = 2;
-
+
ret = H5Sselect_hyperslab(sid_reg_ori3,H5S_SELECT_SET,start3,stride3,count3,block3);
CHECK(ret, FAIL, "H5Sselect_hyperslab");
@@ -6803,7 +6803,7 @@ test_space_rebuild(void)
block3[2] = 2;
ret = H5Sselect_hyperslab(sid_reg3,H5S_SELECT_SET,start3,stride3,count3,block3);
- CHECK(ret, FAIL, "H5Sselect_hyperslab");
+ CHECK(ret, FAIL, "H5Sselect_hyperslab");
start3[2] = 5;
count3[2] = 1;
@@ -6811,7 +6811,7 @@ test_space_rebuild(void)
block3[2] = 2;
ret = H5Sselect_hyperslab(sid_reg3,H5S_SELECT_OR,start3,stride3,count3,block3);
- CHECK(ret, FAIL, "H5Sselect_hyperslab");
+ CHECK(ret, FAIL, "H5Sselect_hyperslab");
rebuild_stat = FALSE;
rebuild_stat = H5S_get_rebuild_status_test(sid_reg3);
@@ -6831,7 +6831,7 @@ test_space_rebuild(void)
sid_irreg3 = H5Screate_simple(SPACERE3_RANK,dims3,NULL);
/* Build up three dimensional irregular selection with H5_SELECT_OR */
- start3[0] = 2;
+ start3[0] = 2;
count3[0] = 2;
stride3[0] = 3;
block3[0] = 2;
@@ -6846,15 +6846,15 @@ test_space_rebuild(void)
block3[2] = 1;
ret = H5Sselect_hyperslab(sid_irreg3,H5S_SELECT_SET,start3,stride3,count3,block3);
- CHECK(ret, FAIL, "H5Sselect_hyperslab");
+ CHECK(ret, FAIL, "H5Sselect_hyperslab");
start3[2] = 3;
- count3[2] = 2;
+ count3[2] = 2;
stride3[2] = 3; /* Just add one element for the stride */
- block3[2] = 1;
-
+ block3[2] = 1;
+
ret = H5Sselect_hyperslab(sid_irreg3,H5S_SELECT_OR,start3,stride3,count3,block3);
- CHECK(ret, FAIL, "H5Sselect_hyperslab");
+ CHECK(ret, FAIL, "H5Sselect_hyperslab");
rebuild_stat = TRUE;
rebuild_stat = H5S_get_rebuild_status_test(sid_irreg3);
@@ -6872,7 +6872,7 @@ test_space_rebuild(void)
sid_reg_ori4 = H5Screate_simple(SPACERE4_RANK,dims4,NULL);
/* Build up the original four dimensional regular selection */
- start4[0] = 2;
+ start4[0] = 2;
count4[0] = 2;
stride4[0] = 3;
block4[0] = 2;
@@ -6891,7 +6891,7 @@ test_space_rebuild(void)
count4[3] = 2;
stride4[3] = 4;
block4[3] = 2;
-
+
ret = H5Sselect_hyperslab(sid_reg_ori4,H5S_SELECT_SET,start4,stride4,count4,block4);
CHECK(ret, FAIL, "H5Sselect_hyperslab");
@@ -6904,7 +6904,7 @@ test_space_rebuild(void)
block4[3] = 2;
ret = H5Sselect_hyperslab(sid_reg4,H5S_SELECT_SET,start4,stride4,count4,block4);
- CHECK(ret, FAIL, "H5Sselect_hyperslab");
+ CHECK(ret, FAIL, "H5Sselect_hyperslab");
start4[3] = 5;
count4[3] = 1;
@@ -6913,7 +6913,7 @@ test_space_rebuild(void)
ret = H5Sselect_hyperslab(sid_reg4,H5S_SELECT_OR,start4,stride4,count4,block4);
- CHECK(ret, FAIL, "H5Sselect_hyperslab");
+ CHECK(ret, FAIL, "H5Sselect_hyperslab");
rebuild_stat = FALSE;
@@ -6932,9 +6932,9 @@ test_space_rebuild(void)
/* Testing irregular selection */
sid_irreg4 = H5Screate_simple(SPACERE4_RANK,dims4,NULL);
-
+
/* Build up four dimensional irregular selection with H5_SELECT_OR */
- start4[0] = 2;
+ start4[0] = 2;
count4[0] = 2;
stride4[0] = 3;
block4[0] = 2;
@@ -6954,7 +6954,7 @@ test_space_rebuild(void)
block4[3] = 2; /* sub-block is one element difference */
ret = H5Sselect_hyperslab(sid_irreg4,H5S_SELECT_SET,start4,stride4,count4,block4);
- CHECK(ret, FAIL, "H5Sselect_hyperslab");
+ CHECK(ret, FAIL, "H5Sselect_hyperslab");
start4[2] = 5;
count4[2] = 1;
@@ -6965,9 +6965,9 @@ test_space_rebuild(void)
count4[3] = 2;
stride4[3] = 4;
block4[3] = 3; /* sub-block is one element difference */
-
+
ret = H5Sselect_hyperslab(sid_irreg4,H5S_SELECT_OR,start4,stride4,count4,block4);
- CHECK(ret, FAIL, "H5Sselect_hyperslab");
+ CHECK(ret, FAIL, "H5Sselect_hyperslab");
rebuild_stat = TRUE;
rebuild_stat = H5S_get_rebuild_status_test(sid_irreg4);
@@ -6985,7 +6985,7 @@ test_space_rebuild(void)
sid_reg_ori5 = H5Screate_simple(SPACERE5_RANK,dims5,NULL);
/* Build up the original five dimensional regular selection */
- start5[0] = 2;
+ start5[0] = 2;
count5[0] = 2;
stride5[0] = 3;
block5[0] = 2;
@@ -7004,7 +7004,7 @@ test_space_rebuild(void)
count5[3] = 2;
stride5[3] = 4;
block5[3] = 2;
-
+
start5[4] = 1;
count5[4] = 2;
stride5[4] = 4;
@@ -7021,7 +7021,7 @@ test_space_rebuild(void)
block5[4] = 2;
ret = H5Sselect_hyperslab(sid_reg5,H5S_SELECT_SET,start5,stride5,count5,block5);
- CHECK(ret, FAIL, "H5Sselect_hyperslab");
+ CHECK(ret, FAIL, "H5Sselect_hyperslab");
start5[4] = 5;
count5[4] = 1;
@@ -7030,7 +7030,7 @@ test_space_rebuild(void)
ret = H5Sselect_hyperslab(sid_reg5,H5S_SELECT_OR,start5,stride5,count5,block5);
- CHECK(ret, FAIL, "H5Sselect_hyperslab");
+ CHECK(ret, FAIL, "H5Sselect_hyperslab");
rebuild_stat = FALSE;
@@ -7048,9 +7048,9 @@ test_space_rebuild(void)
}
sid_irreg5 = H5Screate_simple(SPACERE5_RANK,dims5,NULL);
-
+
/* Build up five dimensional irregular selection with H5_SELECT_OR */
- start5[0] = 2;
+ start5[0] = 2;
count5[0] = 2;
stride5[0] = 3;
block5[0] = 2;
@@ -7068,15 +7068,15 @@ test_space_rebuild(void)
start5[3] = 1;
count5[3] = 1;
stride5[3] = 4;
- block5[3] = 2;
+ block5[3] = 2;
start5[4] = 2; /* One element difference */
count5[4] = 1;
stride5[4] = 4;
- block5[4] = 2;
+ block5[4] = 2;
ret = H5Sselect_hyperslab(sid_irreg5,H5S_SELECT_SET,start5,stride5,count5,block5);
- CHECK(ret, FAIL, "H5Sselect_hyperslab");
+ CHECK(ret, FAIL, "H5Sselect_hyperslab");
start5[3] = 5;
count5[3] = 1;
@@ -7086,10 +7086,10 @@ test_space_rebuild(void)
start5[4] = 1; /* One element difference */
count5[4] = 2;
stride5[4] = 4;
- block5[4] = 2;
-
+ block5[4] = 2;
+
ret = H5Sselect_hyperslab(sid_irreg5,H5S_SELECT_OR,start5,stride5,count5,block5);
- CHECK(ret, FAIL, "H5Sselect_hyperslab");
+ CHECK(ret, FAIL, "H5Sselect_hyperslab");
rebuild_stat = TRUE;
rebuild_stat = H5S_get_rebuild_status_test(sid_irreg5);
@@ -7100,12 +7100,12 @@ test_space_rebuild(void)
CHECK(ret,FAIL,"H5S_hyper_rebuild");
}/* No need to do shape comparision */
- /* We use 5-D to test a special case with
+ /* We use 5-D to test a special case with
rebuilding routine TRUE, FALSE and TRUE */
sid_spec = H5Screate_simple(SPACERE5_RANK,dims5,NULL);
/* Build up the original five dimensional regular selection */
- start5[0] = 2;
+ start5[0] = 2;
count5[0] = 2;
stride5[0] = 3;
block5[0] = 2;
@@ -7124,7 +7124,7 @@ test_space_rebuild(void)
count5[3] = 2;
stride5[3] = 4;
block5[3] = 2;
-
+
start5[4] = 1;
count5[4] = 1;
stride5[4] = 4;
@@ -7133,7 +7133,7 @@ test_space_rebuild(void)
ret = H5Sselect_hyperslab(sid_spec,H5S_SELECT_SET,start5,stride5,count5,block5);
CHECK(ret, FAIL, "H5Sselect_hyperslab");
rebuild_stat = FALSE;
- rebuild_stat = H5S_get_rebuild_status_test(sid_spec);
+ rebuild_stat = H5S_get_rebuild_status_test(sid_spec);
/* In this case, rebuild_stat should be TRUE. */
if(!rebuild_stat){
ret = FAIL;
@@ -7145,14 +7145,14 @@ test_space_rebuild(void)
count5[3] = 1;
stride5[3] = 4;
block5[3] = 2;
-
+
start5[4] = 5;
count5[4] = 1;
stride5[4] = 4;
block5[4] = 2;
ret = H5Sselect_hyperslab(sid_spec,H5S_SELECT_OR,start5,stride5,count5,block5);
- CHECK(ret, FAIL, "H5Sselect_hyperslab");
+ CHECK(ret, FAIL, "H5Sselect_hyperslab");
rebuild_stat = TRUE;
rebuild_stat = H5S_get_rebuild_status_test(sid_spec);
@@ -7167,14 +7167,14 @@ test_space_rebuild(void)
count5[3] = 1;
stride5[3] = 4;
block5[3] = 2;
-
+
start5[4] = 5;
count5[4] = 1;
stride5[4] = 4;
block5[4] = 2;
ret = H5Sselect_hyperslab(sid_spec,H5S_SELECT_OR,start5,stride5,count5,block5);
- CHECK(ret, FAIL, "H5Sselect_hyperslab");
+ CHECK(ret, FAIL, "H5Sselect_hyperslab");
rebuild_stat = FALSE;
rebuild_stat = H5S_get_rebuild_status_test(sid_spec);
@@ -7213,8 +7213,8 @@ test_space_rebuild(void)
H5Sclose(sid_spec);
CHECK(ret, FAIL, "H5Sclose");
-}
-
+}
+
/****************************************************************
**
@@ -7868,10 +7868,10 @@ test_select(void)
/* Test "same shape" routine */
test_shape_same();
-
+
/* Test "re-build" routine */
test_space_rebuild();
-
+
/* Test point selections in chunked datasets */
test_select_point_chunk();
diff --git a/test/ttsafe_acreate.c b/test/ttsafe_acreate.c
index 987c145..4f6a531 100644
--- a/test/ttsafe_acreate.c
+++ b/test/ttsafe_acreate.c
@@ -135,7 +135,7 @@ void tts_acreate(void)
TestErrPrintf("unable to open appropriate attribute. Test failed!\n");
else {
ret = H5Aread(attribute, H5T_NATIVE_INT, &buffer);
-
+
if (ret < 0 || buffer != i)
TestErrPrintf("wrong data values. Test failed!\n");
diff --git a/test/ttsafe_cancel.c b/test/ttsafe_cancel.c
index e2f7cce..8204b11 100644
--- a/test/ttsafe_cancel.c
+++ b/test/ttsafe_cancel.c
@@ -148,7 +148,7 @@ void *tts_cancel_thread(void UNUSED *arg)
cleanup_structure->datatype = datatype;
cleanup_structure->dataspace = dataspace;
pthread_cleanup_push(cancellation_cleanup, cleanup_structure);
-
+
datavalue = 1;
ret=H5Dwrite(dataset, H5T_NATIVE_INT, H5S_ALL, H5S_ALL, H5P_DEFAULT, &datavalue);
@@ -177,7 +177,7 @@ void *tts_cancel_thread(void UNUSED *arg)
* execute the cleanup routine.
*/
pthread_cleanup_pop(0);
-
+
return NULL;
}
diff --git a/test/tvltypes.c b/test/tvltypes.c
index a12de08..e3a7160 100644
--- a/test/tvltypes.c
+++ b/test/tvltypes.c
@@ -194,7 +194,7 @@ test_vltypes_funcs(void)
size=H5Tget_ebias(type);
CHECK(size, FAIL, "H5Tget_ebias");
-
+
ret=H5Tset_pad(type, H5T_PAD_ZERO, H5T_PAD_ONE);
CHECK(ret, FAIL, "H5Tset_pad");
@@ -206,7 +206,7 @@ test_vltypes_funcs(void)
ret=H5Tset_offset(type, 16);
CHECK(ret, FAIL, "H5Tset_offset");
-
+
H5E_BEGIN_TRY {
cset=H5Tget_cset(type);
} H5E_END_TRY;
diff --git a/testpar/t_cache.c b/testpar/t_cache.c
index 3bacb8e..4b7d298 100644
--- a/testpar/t_cache.c
+++ b/testpar/t_cache.c
@@ -39,8 +39,8 @@ int nerrors = 0;
int failures = 0;
hbool_t verbose = TRUE; /* used to control error messages */
#if 0
-/* So far we haven't needed this, but that may change.
- * Keep it around for now
+/* So far we haven't needed this, but that may change.
+ * Keep it around for now
*/
hid_t noblock_dxpl_id=(-1);
#endif
@@ -80,11 +80,11 @@ long local_pins = 0;
* struct datum
*
* Instances of struct datum are used to store information on entries
- * that may be loaded into the cache. The individual fields are
+ * that may be loaded into the cache. The individual fields are
* discussed below:
*
* header: Instance of H5C_cache_entry_t used by the for its data.
- * This field is only used on the file processes, not on the
+ * This field is only used on the file processes, not on the
* server process.
*
* This field MUST be the first entry in this structure.
@@ -98,27 +98,27 @@ long local_pins = 0;
*
* dirty: Boolean flag indicating whether the entry is dirty.
*
- * For current purposes, an entry is clean until it is
+ * For current purposes, an entry is clean until it is
* modified, and dirty until written to the server (cache
- * on process 0) or until it is marked clean (all other
+ * on process 0) or until it is marked clean (all other
* caches).
*
* valid: Boolean flag indicating whether the entry contains
* valid data. Attempts to read an entry whose valid
* flag is not set should trigger an error.
*
- * locked: Boolean flag that is set to true iff the entry is in
+ * locked: Boolean flag that is set to true iff the entry is in
* the cache and locked.
*
- * global_pinned: Boolean flag that is set to true iff the entry has
+ * global_pinned: Boolean flag that is set to true iff the entry has
* been pinned collectively in all caches. Since writes must
* be collective across all processes, only entries pinned
* in this fashion may be marked dirty.
*
* local_pinned: Boolean flag that is set to true iff the entry
* has been pinned in the local cache, but probably not all
- * caches. Such pins will typically not be consistant across
- * processes, and thus cannot be marked as dirty unless they
+ * caches. Such pins will typically not be consistant across
+ * processes, and thus cannot be marked as dirty unless they
* happen to overlap some collective operation.
*
* index: Index of this instance of datum in the data_index[] array
@@ -126,7 +126,7 @@ long local_pins = 0;
*
*****************************************************************************/
-struct datum
+struct datum
{
H5C_cache_entry_t header;
haddr_t base_addr;
@@ -143,14 +143,14 @@ struct datum
/*****************************************************************************
* data array
*
- * The data array is an array of instances of datum of size
+ * The data array is an array of instances of datum of size
* NUM_DATA_ENTRIES that is used to track the particulars of all
* the entries that may be loaded into the cache.
*
* It exists on all processes, although the master copy is maintained
* by the server process. If the cache is performing correctly, all
* versions should be effectively identical. By that I mean that
- * the data received from the server should always match that in
+ * the data received from the server should always match that in
* the local version of the data array.
*
*****************************************************************************/
@@ -163,8 +163,8 @@ struct datum data[NUM_DATA_ENTRIES];
/* Many tests use the size of data array as the size of test loops.
* On some machines, this results in unacceptably long test runs.
*
- * To deal with this issue, I have introduced the virt_num_data_entries
- * global, which can be set to a lower value to throtle the length of
+ * To deal with this issue, I have introduced the virt_num_data_entries
+ * global, which can be set to a lower value to throtle the length of
* tests.
*
* Note that this value must always be divisible by 40, and must be an
@@ -172,7 +172,7 @@ struct datum data[NUM_DATA_ENTRIES];
* powers of 10 that meet these criteria.
*
* Further, this value must be consistant across all processes.
- */
+ */
#define STD_VIRT_NUM_DATA_ENTRIES NUM_DATA_ENTRIES
#define EXPRESS_VIRT_NUM_DATA_ENTRIES (NUM_DATA_ENTRIES / 10)
@@ -191,9 +191,9 @@ int virt_num_data_entries = NUM_DATA_ENTRIES;
* This array is necessary, as rename operations can swap the values
* of the base_addr fields of two instances of datum. Without this
* array, we would no longer be able to use a binary search on a sorted
- * list to find the indexes of instances of datum given the values of
+ * list to find the indexes of instances of datum given the values of
* their base_addr fields.
- *
+ *
*****************************************************************************/
int data_index[NUM_DATA_ENTRIES];
@@ -202,7 +202,7 @@ int data_index[NUM_DATA_ENTRIES];
/*****************************************************************************
* struct mssg
*
- * The mssg structure is used as a generic container for messages to
+ * The mssg structure is used as a generic container for messages to
* and from the server. Not all fields are used in all cases.
*
* req: Integer field containing the type of the message.
@@ -219,7 +219,7 @@ int data_index[NUM_DATA_ENTRIES];
*
* ver: Version number of a datum. Not used in all mssgs.
*
- * magic: Magic number for error detection. Must be set to
+ * magic: Magic number for error detection. Must be set to
* MSSG_MAGIC.
*
*****************************************************************************/
@@ -300,7 +300,7 @@ hbool_t serve_write_request(struct mssg_t * mssg_ptr);
herr_t clear_datum(H5F_t * f, void * thing, hbool_t dest);
herr_t destroy_datum(H5F_t UNUSED * f, void * thing);
-herr_t flush_datum(H5F_t *f, hid_t UNUSED dxpl_id, hbool_t dest, haddr_t addr,
+herr_t flush_datum(H5F_t *f, hid_t UNUSED dxpl_id, hbool_t dest, haddr_t addr,
void *thing);
void * load_datum(H5F_t UNUSED *f, hid_t UNUSED dxpl_id, haddr_t addr,
const void UNUSED *udata1, void UNUSED *udata2);
@@ -325,10 +325,10 @@ const H5C_class_t types[NUMBER_OF_ENTRY_TYPES] =
/* test utility functions */
-void insert_entry(H5C_t * cache_ptr, H5F_t * file_ptr,
+void insert_entry(H5C_t * cache_ptr, H5F_t * file_ptr,
int32_t idx, unsigned int flags);
void local_pin_and_unpin_random_entries(H5C_t * cache_ptr, H5F_t * file_ptr,
- int min_idx, int max_idx,
+ int min_idx, int max_idx,
int min_count, int max_count);
void local_pin_random_entry(H5C_t * cache_ptr, H5F_t * file_ptr,
int min_idx, int max_idx);
@@ -355,7 +355,7 @@ hbool_t setup_cache_for_test(hid_t * fid_ptr, H5F_t ** file_ptr_ptr,
H5C_t ** cache_ptr_ptr);
void setup_rand(void);
hbool_t take_down_cache(hid_t fid);
-void unlock_entry(H5C_t * cache_ptr, H5F_t * file_ptr,
+void unlock_entry(H5C_t * cache_ptr, H5F_t * file_ptr,
int32_t type, unsigned int flags);
void unpin_entry(H5C_t * cache_ptr, H5F_t * file_ptr, int32_t idx,
hbool_t global, hbool_t dirty, hbool_t via_unprotect);
@@ -391,19 +391,19 @@ hbool_t smoke_check_5(void);
* Modifications:
*
* None.
- *
+ *
*****************************************************************************/
-void
+void
print_stats(void)
{
- HDfprintf(stdout,
+ HDfprintf(stdout,
"%d: datum clears / pinned clears / destroys = %ld / %ld / %ld\n",
- world_mpi_rank, datum_clears, datum_pinned_clears,
+ world_mpi_rank, datum_clears, datum_pinned_clears,
datum_destroys );
- HDfprintf(stdout,
+ HDfprintf(stdout,
"%d: datum flushes / pinned flushes / loads = %ld / %ld / %ld\n",
- world_mpi_rank, datum_flushes, datum_pinned_flushes,
+ world_mpi_rank, datum_flushes, datum_pinned_flushes,
datum_loads );
HDfprintf(stdout,
"%d: pins: global / global dirty / local = %ld / %ld / %ld\n",
@@ -427,7 +427,7 @@ print_stats(void)
* Modifications:
*
* None.
- *
+ *
*****************************************************************************/
void
@@ -468,7 +468,7 @@ reset_stats(void)
* Modifications:
*
* None.
- *
+ *
*****************************************************************************/
hbool_t
@@ -491,7 +491,7 @@ set_up_file_communicator(void)
nerrors++;
success = FALSE;
if ( verbose ) {
- fprintf(stdout,
+ fprintf(stdout,
"%d:%s: MPI_Comm_group() failed with error %d.\n",
world_mpi_rank, fcn_name, mpi_result);
}
@@ -499,10 +499,10 @@ set_up_file_communicator(void)
}
if ( success ) {
-
+
num_excluded_ranks = 1;
excluded_ranks[0] = world_server_mpi_rank;
- mpi_result = MPI_Group_excl(world_group, num_excluded_ranks,
+ mpi_result = MPI_Group_excl(world_group, num_excluded_ranks,
excluded_ranks, &file_group);
if ( mpi_result != MPI_SUCCESS ) {
@@ -510,7 +510,7 @@ set_up_file_communicator(void)
nerrors++;
success = FALSE;
if ( verbose ) {
- fprintf(stdout,
+ fprintf(stdout,
"%d:%s: MPI_Group_excl() failed with error %d.\n",
world_mpi_rank, fcn_name, mpi_result);
}
@@ -519,7 +519,7 @@ set_up_file_communicator(void)
if ( success ) {
- mpi_result = MPI_Comm_create(world_mpi_comm, file_group,
+ mpi_result = MPI_Comm_create(world_mpi_comm, file_group,
&file_mpi_comm);
if ( mpi_result != MPI_SUCCESS ) {
@@ -527,7 +527,7 @@ set_up_file_communicator(void)
nerrors++;
success = FALSE;
if ( verbose ) {
- fprintf(stdout,
+ fprintf(stdout,
"%d:%s: MPI_Comm_create() failed with error %d.\n",
world_mpi_rank, fcn_name, mpi_result);
}
@@ -541,7 +541,7 @@ set_up_file_communicator(void)
nerrors++;
success = FALSE;
if ( verbose ) {
- fprintf(stdout,
+ fprintf(stdout,
"%d:%s: file_mpi_comm == MPI_COMM_NULL.\n",
world_mpi_rank, fcn_name);
}
@@ -555,7 +555,7 @@ set_up_file_communicator(void)
nerrors++;
success = FALSE;
if ( verbose ) {
- fprintf(stdout,
+ fprintf(stdout,
"%d:%s: file_mpi_comm != MPI_COMM_NULL.\n",
world_mpi_rank, fcn_name);
}
@@ -573,7 +573,7 @@ set_up_file_communicator(void)
nerrors++;
success = FALSE;
if ( verbose ) {
- fprintf(stdout,
+ fprintf(stdout,
"%d:%s: MPI_Comm_size() failed with error %d.\n",
world_mpi_rank, fcn_name, mpi_result);
}
@@ -589,7 +589,7 @@ set_up_file_communicator(void)
nerrors++;
success = FALSE;
if ( verbose ) {
- fprintf(stdout,
+ fprintf(stdout,
"%d:%s: MPI_Comm_rank() failed with error %d.\n",
world_mpi_rank, fcn_name, mpi_result);
}
@@ -609,7 +609,7 @@ set_up_file_communicator(void)
*
* Function: addr_to_datum_index()
*
- * Purpose: Given the base address of a datum, find and return its index
+ * Purpose: Given the base address of a datum, find and return its index
* in the data array.
*
* Return: Success: index of target datum.
@@ -621,7 +621,7 @@ set_up_file_communicator(void)
* Modifications:
*
* None.
- *
+ *
*****************************************************************************/
int
@@ -650,7 +650,7 @@ addr_to_datum_index(haddr_t base_addr)
ret_value = data_index[middle];
bottom = top + 1; /* to force exit from while loop */
- }
+ }
}
return(ret_value);
@@ -662,7 +662,7 @@ addr_to_datum_index(haddr_t base_addr)
*
* Function: init_data()
*
- * Purpose: Initialize the data array, from which cache entries are
+ * Purpose: Initialize the data array, from which cache entries are
* loaded.
*
* Return: Success: TRUE
@@ -674,24 +674,24 @@ addr_to_datum_index(haddr_t base_addr)
* Modifications:
*
* None.
- *
+ *
*****************************************************************************/
void
init_data(void)
{
const char * fcn_name = "init_data()";
- /* The set of address offsets is chosen so as to avoid allowing the
+ /* The set of address offsets is chosen so as to avoid allowing the
* base addresses to fall in a pattern of that will annoy the hash
* table, and to give a good range of entry sizes.
*
- * At present, I am using the first 20 entries of the Fibonacci
+ * At present, I am using the first 20 entries of the Fibonacci
* sequence multiplied by 2. We will see how it works.
*/
const int num_addr_offsets = 20;
- const haddr_t addr_offsets[20] = { 2, 2, 4, 6, 10,
- 16, 26, 42, 68, 110,
- 178, 288, 466, 754, 1220,
+ const haddr_t addr_offsets[20] = { 2, 2, 4, 6, 10,
+ 16, 26, 42, 68, 110,
+ 178, 288, 466, 754, 1220,
1974, 3194, 5168, 8362, 13539};
int i;
int j = 0;
@@ -720,7 +720,7 @@ init_data(void)
j = (j + 1) % num_addr_offsets;
}
-
+
return;
} /* init_data() */
@@ -742,7 +742,7 @@ init_data(void)
* processes. This function ensures that all processes agree
* on whether to do an express test.
*
- * Return: Success: Maximum of the values returned by
+ * Return: Success: Maximum of the values returned by
* GetTestExpress() across all processes.
*
* Failure: -1
@@ -752,7 +752,7 @@ init_data(void)
* Modifications:
*
* None.
- *
+ *
*****************************************************************************/
int
@@ -777,10 +777,10 @@ do_express_test(void)
nerrors++;
max_express_test = -1;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: MPI_Allreduce() failed.\n",
+ HDfprintf(stdout, "%d:%s: MPI_Allreduce() failed.\n",
world_mpi_rank, fcn_name );
}
- }
+ }
return(max_express_test);
@@ -794,7 +794,7 @@ do_express_test(void)
* Purpose: Ensure that all messages sent by this process have been
* processed before proceeding.
*
- * Do this by exchanging sync req / sync ack messages with
+ * Do this by exchanging sync req / sync ack messages with
* the server.
*
* Do nothing if nerrors is greater than zero.
@@ -806,7 +806,7 @@ do_express_test(void)
* Modifications:
*
* None.
- *
+ *
*****************************************************************************/
void
@@ -830,7 +830,7 @@ do_sync(void)
mssg.magic = MSSG_MAGIC;
if ( ! send_mssg(&mssg, FALSE) ) {
-
+
nerrors++;
if ( verbose ) {
HDfprintf(stdout, "%d:%s: send_mssg() failed.\n",
@@ -870,7 +870,7 @@ do_sync(void)
*
* Function: get_max_nerrors()
*
- * Purpose: Do an MPI_Allreduce to obtain the maximum value of nerrors
+ * Purpose: Do an MPI_Allreduce to obtain the maximum value of nerrors
* across all processes. Return this value.
*
* Return: Success: Maximum of the nerrors global variables across
@@ -883,7 +883,7 @@ do_sync(void)
* Modifications:
*
* None.
- *
+ *
*****************************************************************************/
int
@@ -905,10 +905,10 @@ get_max_nerrors(void)
nerrors++;
max_nerrors = -1;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: MPI_Allreduce() failed.\n",
+ HDfprintf(stdout, "%d:%s: MPI_Allreduce() failed.\n",
world_mpi_rank, fcn_name );
}
- }
+ }
return(max_nerrors);
@@ -923,7 +923,7 @@ get_max_nerrors(void)
*
* Function: recv_mssg()
*
- * Purpose: Receive a message from any process in the provided instance
+ * Purpose: Receive a message from any process in the provided instance
* of struct mssg.
*
* Return: Success: TRUE
@@ -936,7 +936,7 @@ get_max_nerrors(void)
*
* JRM -- 5/10/06
* Added mssg_tag_offset parameter and supporting code.
- *
+ *
*****************************************************************************/
#define CACHE_TEST_TAG 99 /* different from any used by the library */
@@ -958,7 +958,7 @@ recv_mssg(struct mssg_t *mssg_ptr,
nerrors++;
success = FALSE;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: bad param(s) on entry.\n",
+ HDfprintf(stdout, "%d:%s: bad param(s) on entry.\n",
world_mpi_rank, fcn_name);
}
} else {
@@ -976,7 +976,7 @@ recv_mssg(struct mssg_t *mssg_ptr,
nerrors++;
success = FALSE;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: MPI_Recv() failed.\n",
+ HDfprintf(stdout, "%d:%s: MPI_Recv() failed.\n",
world_mpi_rank, fcn_name );
}
} else if ( mssg_ptr->magic != MSSG_MAGIC ) {
@@ -992,8 +992,8 @@ recv_mssg(struct mssg_t *mssg_ptr,
nerrors++;
success = FALSE;
if ( verbose ) {
- HDfprintf(stdout,
- "%d:%s: mssg_ptr->src != status.MPI_SOURCE.\n",
+ HDfprintf(stdout,
+ "%d:%s: mssg_ptr->src != status.MPI_SOURCE.\n",
world_mpi_rank, fcn_name);
}
}
@@ -1010,7 +1010,7 @@ recv_mssg(struct mssg_t *mssg_ptr,
*
* Purpose: Send the provided instance of mssg to the indicated target.
*
- * Note that all source and destination ranks are in the
+ * Note that all source and destination ranks are in the
* global communicator.
*
* Return: Success: TRUE
@@ -1023,7 +1023,7 @@ recv_mssg(struct mssg_t *mssg_ptr,
*
* JRM -- 5/10/06
* Added the add_req_to_tag parameter and supporting code.
- *
+ *
*****************************************************************************/
hbool_t
@@ -1048,7 +1048,7 @@ send_mssg(struct mssg_t *mssg_ptr,
nerrors++;
success = FALSE;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: Invalid mssg on entry.\n",
+ HDfprintf(stdout, "%d:%s: Invalid mssg on entry.\n",
world_mpi_rank, fcn_name);
}
}
@@ -1070,7 +1070,7 @@ send_mssg(struct mssg_t *mssg_ptr,
nerrors++;
success = FALSE;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: MPI_Send() failed.\n",
+ HDfprintf(stdout, "%d:%s: MPI_Send() failed.\n",
world_mpi_rank, fcn_name);
}
}
@@ -1097,7 +1097,7 @@ send_mssg(struct mssg_t *mssg_ptr,
* Modifications:
*
* None.
- *
+ *
*****************************************************************************/
hbool_t
@@ -1108,7 +1108,7 @@ setup_derived_types(void)
int i;
int result;
MPI_Datatype mpi_types[8] = {MPI_INT, MPI_INT, MPI_INT, MPI_LONG,
- HADDR_AS_MPI_TYPE, MPI_INT, MPI_INT,
+ HADDR_AS_MPI_TYPE, MPI_INT, MPI_INT,
MPI_UNSIGNED};
int block_len[8] = {1, 1, 1, 1, 1, 1, 1, 1};
MPI_Aint displs[8];
@@ -1127,7 +1127,7 @@ setup_derived_types(void)
nerrors++;
success = FALSE;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: MPI_Address() call failed.\n",
+ HDfprintf(stdout, "%d:%s: MPI_Address() call failed.\n",
world_mpi_rank, fcn_name);
}
@@ -1149,7 +1149,7 @@ setup_derived_types(void)
nerrors++;
success = FALSE;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: MPI_Type_struct() call failed.\n",
+ HDfprintf(stdout, "%d:%s: MPI_Type_struct() call failed.\n",
world_mpi_rank, fcn_name);
}
}
@@ -1164,7 +1164,7 @@ setup_derived_types(void)
nerrors++;
success = FALSE;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: MPI_Type_commit() call failed.\n",
+ HDfprintf(stdout, "%d:%s: MPI_Type_commit() call failed.\n",
world_mpi_rank, fcn_name);
}
}
@@ -1191,7 +1191,7 @@ setup_derived_types(void)
* Modifications:
*
* None.
- *
+ *
*****************************************************************************/
hbool_t
@@ -1208,7 +1208,7 @@ takedown_derived_types(void)
nerrors++;
success = FALSE;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: MPI_Type_free() call failed.\n",
+ HDfprintf(stdout, "%d:%s: MPI_Type_free() call failed.\n",
world_mpi_rank, fcn_name);
}
}
@@ -1243,10 +1243,10 @@ takedown_derived_types(void)
*
* JRM -- 5/10/06
* Updated for sync message.
- *
+ *
*****************************************************************************/
-hbool_t
+hbool_t
server_main(void)
{
const char * fcn_name = "server_main()";
@@ -1260,7 +1260,7 @@ server_main(void)
nerrors++;
success = FALSE;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: This isn't the server process?!?!?\n",
+ HDfprintf(stdout, "%d:%s: This isn't the server process?!?!?\n",
world_mpi_rank, fcn_name);
}
}
@@ -1289,7 +1289,7 @@ server_main(void)
case READ_REQ_REPLY_CODE:
success = FALSE;
- HDfprintf(stdout, "%s: Received read req reply?!?.\n",
+ HDfprintf(stdout, "%s: Received read req reply?!?.\n",
fcn_name);
break;
@@ -1299,7 +1299,7 @@ server_main(void)
case SYNC_ACK_CODE:
success = FALSE;
- HDfprintf(stdout, "%s: Received sync ack?!?.\n",
+ HDfprintf(stdout, "%s: Received sync ack?!?.\n",
fcn_name);
break;
@@ -1317,7 +1317,7 @@ server_main(void)
nerrors++;
success = FALSE;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: Unknown request code.\n",
+ HDfprintf(stdout, "%d:%s: Unknown request code.\n",
world_mpi_rank, fcn_name);
}
break;
@@ -1336,7 +1336,7 @@ server_main(void)
*
* Purpose: Serve a read request.
*
- * The function accepts a pointer to an instance of struct
+ * The function accepts a pointer to an instance of struct
* mssg_t as input. If all sanity checks pass, it sends
* a copy of the indicated datum from the data array to
* the requesting process.
@@ -1350,7 +1350,7 @@ server_main(void)
* Modifications:
*
* None.
- *
+ *
*****************************************************************************/
hbool_t
@@ -1362,14 +1362,14 @@ serve_read_request(struct mssg_t * mssg_ptr)
haddr_t target_addr;
struct mssg_t reply;
- if ( ( mssg_ptr == NULL ) ||
+ if ( ( mssg_ptr == NULL ) ||
( mssg_ptr->req != READ_REQ_CODE ) ||
( mssg_ptr->magic != MSSG_MAGIC ) ) {
nerrors++;
success = FALSE;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: Bad mssg on entry.\n",
+ HDfprintf(stdout, "%d:%s: Bad mssg on entry.\n",
world_mpi_rank, fcn_name);
}
}
@@ -1384,7 +1384,7 @@ serve_read_request(struct mssg_t * mssg_ptr)
nerrors++;
success = FALSE;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: addr lookup failed for %a.\n",
+ HDfprintf(stdout, "%d:%s: addr lookup failed for %a.\n",
world_mpi_rank, fcn_name, target_addr);
}
} else if ( data[target_index].len != mssg_ptr->len ) {
@@ -1392,9 +1392,9 @@ serve_read_request(struct mssg_t * mssg_ptr)
nerrors++;
success = FALSE;
if ( verbose ) {
- HDfprintf(stdout,
+ HDfprintf(stdout,
"%d:%s: data[i].len = %d != mssg->len = %d.\n",
- world_mpi_rank, fcn_name,
+ world_mpi_rank, fcn_name,
data[target_index].len, mssg_ptr->len);
}
} else if ( ! (data[target_index].valid) ) {
@@ -1402,9 +1402,9 @@ serve_read_request(struct mssg_t * mssg_ptr)
nerrors++;
success = FALSE;
if ( verbose ) {
- HDfprintf(stdout,
+ HDfprintf(stdout,
"%d:%s: proc %d read invalid entry. idx/base_addr = %d/%a.\n",
- world_mpi_rank, fcn_name,
+ world_mpi_rank, fcn_name,
mssg_ptr->src, target_index,
target_index,
data[target_index].base_addr);
@@ -1427,7 +1427,7 @@ serve_read_request(struct mssg_t * mssg_ptr)
success = send_mssg(&reply, TRUE);
}
-
+
return(success);
} /* serve_read_request() */
@@ -1439,12 +1439,12 @@ serve_read_request(struct mssg_t * mssg_ptr)
*
* Purpose: Serve a sync request.
*
- * The function accepts a pointer to an instance of struct
- * mssg_t as input. If all sanity checks pass, it sends a
+ * The function accepts a pointer to an instance of struct
+ * mssg_t as input. If all sanity checks pass, it sends a
* sync ack to the requesting process.
*
* This service exist to allow the sending process to ensure
- * that all previous messages have been processed before
+ * that all previous messages have been processed before
* proceeding.
*
* Return: Success: TRUE
@@ -1456,7 +1456,7 @@ serve_read_request(struct mssg_t * mssg_ptr)
* Modifications:
*
* None.
- *
+ *
*****************************************************************************/
hbool_t
@@ -1466,14 +1466,14 @@ serve_sync_request(struct mssg_t * mssg_ptr)
hbool_t success = TRUE;
struct mssg_t reply;
- if ( ( mssg_ptr == NULL ) ||
+ if ( ( mssg_ptr == NULL ) ||
( mssg_ptr->req != SYNC_REQ_CODE ) ||
( mssg_ptr->magic != MSSG_MAGIC ) ) {
nerrors++;
success = FALSE;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: Bad mssg on entry.\n",
+ HDfprintf(stdout, "%d:%s: Bad mssg on entry.\n",
world_mpi_rank, fcn_name);
}
}
@@ -1485,7 +1485,7 @@ serve_sync_request(struct mssg_t * mssg_ptr)
reply.src = world_mpi_rank;
reply.dest = mssg_ptr->src;
reply.mssg_num = -1; /* set by send function */
- reply.base_addr = 0;
+ reply.base_addr = 0;
reply.len = 0;
reply.ver = 0;
reply.magic = MSSG_MAGIC;
@@ -1495,7 +1495,7 @@ serve_sync_request(struct mssg_t * mssg_ptr)
success = send_mssg(&reply, TRUE);
}
-
+
return(success);
} /* serve_sync_request() */
@@ -1507,7 +1507,7 @@ serve_sync_request(struct mssg_t * mssg_ptr)
*
* Purpose: Serve a write request.
*
- * The function accepts a pointer to an instance of struct
+ * The function accepts a pointer to an instance of struct
* mssg_t as input. If all sanity checks pass, it updates
* the version number of the target data array entry as
* specified in the message.
@@ -1521,10 +1521,10 @@ serve_sync_request(struct mssg_t * mssg_ptr)
* Modifications:
*
* JRM -- 5/9/06
- * Added code supporting a write ack message. This is a
- * speculative fix to a bug observed on Cobalt. If it
+ * Added code supporting a write ack message. This is a
+ * speculative fix to a bug observed on Cobalt. If it
* doesn't work, it will help narrow down the possibilities.
- *
+ *
*****************************************************************************/
hbool_t
@@ -1539,14 +1539,14 @@ serve_write_request(struct mssg_t * mssg_ptr)
struct mssg_t reply;
#endif /* DO_WRITE_REQ_ACK */
- if ( ( mssg_ptr == NULL ) ||
+ if ( ( mssg_ptr == NULL ) ||
( mssg_ptr->req != WRITE_REQ_CODE ) ||
( mssg_ptr->magic != MSSG_MAGIC ) ) {
nerrors++;
success = FALSE;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: Bad mssg on entry.\n",
+ HDfprintf(stdout, "%d:%s: Bad mssg on entry.\n",
world_mpi_rank, fcn_name);
}
}
@@ -1561,7 +1561,7 @@ serve_write_request(struct mssg_t * mssg_ptr)
nerrors++;
success = FALSE;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: addr lookup failed for %a.\n",
+ HDfprintf(stdout, "%d:%s: addr lookup failed for %a.\n",
world_mpi_rank, fcn_name, target_addr);
}
} else if ( data[target_index].len != mssg_ptr->len ) {
@@ -1569,9 +1569,9 @@ serve_write_request(struct mssg_t * mssg_ptr)
nerrors++;
success = FALSE;
if ( verbose ) {
- HDfprintf(stdout,
+ HDfprintf(stdout,
"%d:%s: data[i].len = %d != mssg->len = %d.\n",
- world_mpi_rank, fcn_name,
+ world_mpi_rank, fcn_name,
data[target_index].len, mssg_ptr->len);
}
}
@@ -1587,7 +1587,7 @@ serve_write_request(struct mssg_t * mssg_ptr)
success = FALSE;
if ( verbose ) {
HDfprintf(stdout, "%d:%s: new ver = %d <= old ver = %d.\n",
- world_mpi_rank, fcn_name,
+ world_mpi_rank, fcn_name,
new_ver_num, data[target_index].ver);
}
}
@@ -1617,7 +1617,7 @@ serve_write_request(struct mssg_t * mssg_ptr)
#endif /* DO_WRITE_REQ_ACK */
}
-
+
return(success);
} /* serve_write_request() */
@@ -1630,7 +1630,7 @@ serve_write_request(struct mssg_t * mssg_ptr)
/*-------------------------------------------------------------------------
* Function: clear_datum
*
- * Purpose: Mark the datum as clean and destroy it if requested.
+ * Purpose: Mark the datum as clean and destroy it if requested.
* Do not write it to the server, or increment the version.
*
* Return: SUCCEED
@@ -1690,7 +1690,7 @@ clear_datum(H5F_t * f,
* Function: destroy_datum()
*
* Purpose: Destroy the entry. At present, this means do nothing other
- * than verify that the entry is clean. In particular, do not
+ * than verify that the entry is clean. In particular, do not
* write it to the server process.
*
* Return: SUCCEED
@@ -1739,7 +1739,7 @@ destroy_datum(H5F_t UNUSED * f,
/*-------------------------------------------------------------------------
* Function: flush_datum
*
- * Purpose: Flush the entry to the server process and mark it as clean.
+ * Purpose: Flush the entry to the server process and mark it as clean.
* Then destroy the entry if requested.
*
* Return: SUCCEED if successful, and FAIL otherwise.
@@ -1790,7 +1790,7 @@ flush_datum(H5F_t *f,
if ( ( file_mpi_rank != 0 ) && ( entry_ptr->dirty ) ) {
ret_value = FAIL;
- HDfprintf(stdout,
+ HDfprintf(stdout,
"%d:%s: Flushed dirty entry from non-zero file process.",
world_mpi_rank, fcn_name);
}
@@ -1868,7 +1868,7 @@ flush_datum(H5F_t *f,
datum_flushes++;
if ( entry_ptr->header.is_pinned ) {
-
+
datum_pinned_flushes++;
HDassert( entry_ptr->global_pinned || entry_ptr->local_pinned );
}
@@ -1880,7 +1880,7 @@ flush_datum(H5F_t *f,
/*-------------------------------------------------------------------------
* Function: load_datum
*
- * Purpose: Read the requested entry from the server and mark it as
+ * Purpose: Read the requested entry from the server and mark it as
* clean.
*
* Return: SUCCEED if successful, FAIL otherwise.
@@ -1990,7 +1990,7 @@ load_datum(H5F_t UNUSED *f,
if ( mssg.base_addr != entry_ptr->base_addr ) {
- HDfprintf(stdout,
+ HDfprintf(stdout,
"%d:%s: mssg.base_addr != entry_ptr->base_addr.\n",
world_mpi_rank, fcn_name);
HDfprintf(stdout, "%d:%s: mssg.base_addr = %a.\n",
@@ -2042,7 +2042,7 @@ load_datum(H5F_t UNUSED *f,
/*-------------------------------------------------------------------------
* Function: size_datum
*
- * Purpose: Get the size of the specified entry. Just look at the
+ * Purpose: Get the size of the specified entry. Just look at the
* local copy, as size can't change.
*
* Return: SUCCEED
@@ -2131,7 +2131,7 @@ insert_entry(H5C_t * cache_ptr,
(entry_ptr->ver)++;
entry_ptr->dirty = TRUE;
- result = H5AC_set(file_ptr, -1, &(types[0]), entry_ptr->base_addr,
+ result = H5AC_set(file_ptr, -1, &(types[0]), entry_ptr->base_addr,
(void *)(&(entry_ptr->header)), flags);
if ( ( result < 0 ) ||
@@ -2149,7 +2149,7 @@ insert_entry(H5C_t * cache_ptr,
if ( ! (entry_ptr->header.is_dirty) ) {
/* it is possible that we just exceeded the dirty bytes
- * threshold, triggering a write of the newly inserted
+ * threshold, triggering a write of the newly inserted
* entry. Test for this, and only flag an error if this
* is not the case.
*/
@@ -2161,11 +2161,11 @@ insert_entry(H5C_t * cache_ptr,
if ( ! ( ( aux_ptr != NULL ) &&
( aux_ptr->magic == H5AC__H5AC_AUX_T_MAGIC ) &&
( aux_ptr->dirty_bytes == 0 ) ) ) {
-
+
nerrors++;
if ( verbose ) {
HDfprintf(stdout, "%d:%s: data[%d].header.is_dirty = %d.\n",
- world_mpi_rank, fcn_name, idx,
+ world_mpi_rank, fcn_name, idx,
(int)(data[idx].header.is_dirty));
}
}
@@ -2183,7 +2183,7 @@ insert_entry(H5C_t * cache_ptr,
/*****************************************************************************
* Function: local_pin_and_unpin_random_entries()
*
- * Purpose: Pin a random number of randomly selected entries in cache, and
+ * Purpose: Pin a random number of randomly selected entries in cache, and
* then unpin a random number of entries.
*
* Do nothing if nerrors is non-zero on entry.
@@ -2201,8 +2201,8 @@ void
local_pin_and_unpin_random_entries(H5C_t * cache_ptr,
H5F_t * file_ptr,
int min_idx,
- int max_idx,
- int min_count,
+ int max_idx,
+ int min_count,
int max_count)
{
const char * fcn_name = "local_pin_and_unpin_random_entries()";
@@ -2259,8 +2259,8 @@ local_pin_and_unpin_random_entries(H5C_t * cache_ptr,
* Function: local_pin_random_entry()
*
* Purpose: Pin a randomly selected entry in cache, and mark the entry
- * as being locally pinned. Since this entry will not in
- * general be pinned in any other cache, we can't mark it
+ * as being locally pinned. Since this entry will not in
+ * general be pinned in any other cache, we can't mark it
* dirty.
*
* Do nothing if nerrors is non-zero on entry.
@@ -2340,7 +2340,7 @@ local_unpin_all_entries(H5C_t * cache_ptr,
idx = 0;
- while ( idx >= 0 )
+ while ( idx >= 0 )
{
idx = local_unpin_next_pinned_entry(cache_ptr, file_ptr,
idx, via_unprotect);
@@ -2360,8 +2360,8 @@ local_unpin_all_entries(H5C_t * cache_ptr,
*
* Do nothing if nerrors is non-zero on entry.
*
- * Return: Index of the unpinned entry if there is one, or -1 if
- * nerrors is non-zero on entry, or if there is no locally
+ * Return: Index of the unpinned entry if there is one, or -1 if
+ * nerrors is non-zero on entry, or if there is no locally
* pinned entry.
*
* Programmer: John Mainzer
@@ -2391,7 +2391,7 @@ local_unpin_next_pinned_entry(H5C_t * cache_ptr,
idx = start_idx;
- while ( ( i < virt_num_data_entries ) &&
+ while ( ( i < virt_num_data_entries ) &&
( ! ( data[idx].local_pinned ) ) )
{
i++;
@@ -2420,7 +2420,7 @@ local_unpin_next_pinned_entry(H5C_t * cache_ptr,
* Function: lock_and_unlock_random_entries()
*
* Purpose: Obtain a random number in the closed interval [min_count,
- * max_count]. Then protect and unprotect that number of
+ * max_count]. Then protect and unprotect that number of
* random entries.
*
* Do nothing if nerrors is non-zero on entry.
@@ -2554,7 +2554,7 @@ lock_entry(H5C_t * cache_ptr,
HDassert( ! (entry_ptr->locked) );
cache_entry_ptr = H5AC_protect(file_ptr, -1, &(types[0]),
- entry_ptr->base_addr,
+ entry_ptr->base_addr,
NULL, NULL, H5AC_WRITE);
if ( ( cache_entry_ptr != (void *)(&(entry_ptr->header)) ) ||
@@ -2633,12 +2633,12 @@ mark_pinned_entry_dirty(H5C_t * cache_ptr,
nerrors++;
if ( verbose ) {
- HDfprintf(stdout,
+ HDfprintf(stdout,
"%d:%s: error in H5AC_mark_pinned_entry_dirty().\n",
world_mpi_rank, fcn_name);
}
- }
- else
+ }
+ else
{
global_dirty_pins++;
}
@@ -2700,7 +2700,7 @@ mark_pinned_or_protected_entry_dirty(H5C_t * cache_ptr,
world_mpi_rank, fcn_name,
"H5AC_mark_pinned_or_protected_entry_dirty()");
}
- }
+ }
else if ( ! ( entry_ptr->locked ) )
{
global_dirty_pins++;
@@ -2891,9 +2891,9 @@ rename_entry(H5C_t * cache_ptr,
* Purpose: Setup the parallel cache for a test, and return the file id
* and a pointer to the cache's internal data structures.
*
- * To do this, we must create a file, flush it (so that we
+ * To do this, we must create a file, flush it (so that we
* don't have to worry about entries in the metadata cache),
- * look up the address of the metadata cache, and then instruct
+ * look up the address of the metadata cache, and then instruct
* the cache to omit sanity checks on dxpl IDs.
*
* Return: Success: TRUE
@@ -2905,7 +2905,7 @@ rename_entry(H5C_t * cache_ptr,
* Modifications:
*
* None.
- *
+ *
*****************************************************************************/
hbool_t
@@ -2930,13 +2930,13 @@ setup_cache_for_test(hid_t * fid_ptr,
if ( fid < 0 ) {
nerrors++;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: H5Fcreate() failed.\n",
+ HDfprintf(stdout, "%d:%s: H5Fcreate() failed.\n",
world_mpi_rank, fcn_name);
}
} else if ( H5Fflush(fid, H5F_SCOPE_GLOBAL) < 0 ) {
nerrors++;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: H5Fflush() failed.\n",
+ HDfprintf(stdout, "%d:%s: H5Fflush() failed.\n",
world_mpi_rank, fcn_name);
}
} else {
@@ -2946,7 +2946,7 @@ setup_cache_for_test(hid_t * fid_ptr,
if ( file_ptr == NULL ) {
nerrors++;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: Can't get file_ptr.\n",
+ HDfprintf(stdout, "%d:%s: Can't get file_ptr.\n",
world_mpi_rank, fcn_name);
}
} else {
@@ -2956,13 +2956,13 @@ setup_cache_for_test(hid_t * fid_ptr,
if ( cache_ptr == NULL ) {
nerrors++;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: Can't get cache_ptr.\n",
+ HDfprintf(stdout, "%d:%s: Can't get cache_ptr.\n",
world_mpi_rank, fcn_name);
}
} else if ( cache_ptr->magic != H5C__H5C_T_MAGIC ) {
nerrors++;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: Bad cache_ptr magic.\n",
+ HDfprintf(stdout, "%d:%s: Bad cache_ptr magic.\n",
world_mpi_rank, fcn_name);
}
} else {
@@ -2978,21 +2978,21 @@ setup_cache_for_test(hid_t * fid_ptr,
config.version = H5AC__CURR_CACHE_CONFIG_VERSION;
- if ( H5AC_get_cache_auto_resize_config(cache_ptr, &config)
+ if ( H5AC_get_cache_auto_resize_config(cache_ptr, &config)
!= SUCCEED ) {
- HDfprintf(stdout,
- "%d:%s: H5AC_get_cache_auto_resize_config() failed.\n",
+ HDfprintf(stdout,
+ "%d:%s: H5AC_get_cache_auto_resize_config() failed.\n",
world_mpi_rank, fcn_name);
} else {
config.rpt_fcn_enabled = TRUE;
- if ( H5AC_set_cache_auto_resize_config(cache_ptr, &config)
+ if ( H5AC_set_cache_auto_resize_config(cache_ptr, &config)
!= SUCCEED ) {
- HDfprintf(stdout,
+ HDfprintf(stdout,
"%d:%s: H5AC_set_cache_auto_resize_config() failed.\n",
world_mpi_rank, fcn_name);
} else {
@@ -3011,8 +3011,8 @@ setup_cache_for_test(hid_t * fid_ptr,
nerrors++;
if ( verbose ) {
- HDfprintf(stdout,
- "%d:%s: H5C_set_write_done_callback failed.\n",
+ HDfprintf(stdout,
+ "%d:%s: H5C_set_write_done_callback failed.\n",
world_mpi_rank, fcn_name);
}
}
@@ -3029,7 +3029,7 @@ setup_cache_for_test(hid_t * fid_ptr,
*
* Function: setup_noblock_dxpl_id()
*
- * Purpose: Setup the noblock_dxpl_id global. Increment nerrors if
+ * Purpose: Setup the noblock_dxpl_id global. Increment nerrors if
* errors are detected. Do nothing if nerrors is non-zero
* on entry.
*
@@ -3040,22 +3040,22 @@ setup_cache_for_test(hid_t * fid_ptr,
* Modifications:
*
* None.
- *
+ *
*****************************************************************************/
-/* So far we haven't needed this, but that may change.
- * Keep it around for now
+/* So far we haven't needed this, but that may change.
+ * Keep it around for now
*/
#if 0
void
setup_noblock_dxpl_id(void)
{
const char * fcn_name = "setup_noblock_dxpl_id()";
- H5P_genclass_t *xfer_pclass; /* Dataset transfer property list
- * class object
+ H5P_genclass_t *xfer_pclass; /* Dataset transfer property list
+ * class object
*/
H5P_genplist_t *xfer_plist; /* Dataset transfer property list object */
- unsigned block_before_meta_write; /* "block before meta write"
- * property value
+ unsigned block_before_meta_write; /* "block before meta write"
+ * property value
*/
unsigned library_internal = 1; /* "library internal" property value */
H5FD_mpio_xfer_t xfer_mode; /* I/O transfer mode property value */
@@ -3100,13 +3100,13 @@ setup_noblock_dxpl_id(void)
block_before_meta_write=0;
if ( ( nerrors == 0 ) &&
( H5P_insert(xfer_plist, H5AC_BLOCK_BEFORE_META_WRITE_NAME,
- H5AC_BLOCK_BEFORE_META_WRITE_SIZE,
+ H5AC_BLOCK_BEFORE_META_WRITE_SIZE,
&block_before_meta_write,
NULL, NULL, NULL, NULL, NULL, NULL) < 0 ) ) {
nerrors++;
if ( verbose ) {
- HDfprintf(stdout,
+ HDfprintf(stdout,
"%d:%s: can't insert metadata cache dxpl property 1.\n",
world_mpi_rank, fcn_name);
}
@@ -3120,7 +3120,7 @@ setup_noblock_dxpl_id(void)
nerrors++;
if ( verbose ) {
- HDfprintf(stdout,
+ HDfprintf(stdout,
"%d:%s: can't insert metadata cache dxpl property 2.\n",
world_mpi_rank, fcn_name);
}
@@ -3133,7 +3133,7 @@ setup_noblock_dxpl_id(void)
nerrors++;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: unable to set value.\n", world_mpi_rank,
+ HDfprintf(stdout, "%d:%s: unable to set value.\n", world_mpi_rank,
fcn_name);
}
}
@@ -3148,7 +3148,7 @@ setup_noblock_dxpl_id(void)
*
* Function: setup_rand()
*
- * Purpose: Use gettimeofday() to obtain a seed for rand(), print the
+ * Purpose: Use gettimeofday() to obtain a seed for rand(), print the
* seed to stdout, and then pass it to srand().
*
* Increment nerrors if any errors are detected.
@@ -3161,7 +3161,7 @@ setup_noblock_dxpl_id(void)
*
* JRM -- 5/9/06
* Modified function to facilitate setting predefined seeds.
- *
+ *
*****************************************************************************/
void
@@ -3175,14 +3175,14 @@ setup_rand(void)
struct timeval tv;
struct timezone tz;
- if ( ( use_predefined_seeds ) &&
+ if ( ( use_predefined_seeds ) &&
( world_mpi_size == num_predefined_seeds ) ) {
HDassert( world_mpi_rank >= 0 );
HDassert( world_mpi_rank < world_mpi_size );
seed = predefined_seeds[world_mpi_rank];
- HDfprintf(stdout, "%d:%s: predefined_seed = %d.\n",
+ HDfprintf(stdout, "%d:%s: predefined_seed = %d.\n",
world_mpi_rank, fcn_name, seed);
fflush(stdout);
HDsrand(seed);
@@ -3198,7 +3198,7 @@ setup_rand(void)
}
} else {
seed = (unsigned)tv.tv_usec;
- HDfprintf(stdout, "%d:%s: seed = %d.\n",
+ HDfprintf(stdout, "%d:%s: seed = %d.\n",
world_mpi_rank, fcn_name, seed);
fflush(stdout);
HDsrand(seed);
@@ -3216,7 +3216,7 @@ setup_rand(void)
*
* Purpose: Take down the parallel cache after a test.
*
- * To do this, we must close the file, and delete if if
+ * To do this, we must close the file, and delete if if
* possible.
*
* Return: Success: TRUE
@@ -3228,7 +3228,7 @@ setup_rand(void)
* Modifications:
*
* None.
- *
+ *
*****************************************************************************/
hbool_t
@@ -3242,7 +3242,7 @@ take_down_cache(hid_t fid)
nerrors++;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: H5Fclose() failed.\n",
+ HDfprintf(stdout, "%d:%s: H5Fclose() failed.\n",
world_mpi_rank, fcn_name);
}
@@ -3252,7 +3252,7 @@ take_down_cache(hid_t fid)
nerrors++;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: HDremove() failed.\n",
+ HDfprintf(stdout, "%d:%s: HDremove() failed.\n",
world_mpi_rank, fcn_name);
}
} else {
@@ -3315,7 +3315,7 @@ unlock_entry(H5C_t * cache_ptr,
entry_ptr->dirty = TRUE;
}
- result = H5AC_unprotect(file_ptr, -1, &(types[0]),
+ result = H5AC_unprotect(file_ptr, -1, &(types[0]),
entry_ptr->base_addr,
(void *)(&(entry_ptr->header)), flags);
@@ -3462,15 +3462,15 @@ unpin_entry(H5C_t * cache_ptr,
*
* JRM -- 5/9/06
* Added code supporting the write request ack message. This
- * message was added to eliminate one possible cause of a
+ * message was added to eliminate one possible cause of a
* bug spotted on cobalt. If this doesn't fix the problem,
* it will narrow things down a bit.
*
* JRM -- 5/10/06
- * Added call to do_sync(). This is part of an attempt to
+ * Added call to do_sync(). This is part of an attempt to
* optimize out the slowdown caused by the addition of the
* write request ack message.
- *
+ *
*****************************************************************************/
hbool_t
@@ -3518,7 +3518,7 @@ server_smoke_check(void)
nerrors++;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: send_mssg() failed on write.\n",
+ HDfprintf(stdout, "%d:%s: send_mssg() failed on write.\n",
world_mpi_rank, fcn_name);
}
}
@@ -3534,7 +3534,7 @@ server_smoke_check(void)
nerrors++;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: recv_mssg() failed.\n",
+ HDfprintf(stdout, "%d:%s: recv_mssg() failed.\n",
world_mpi_rank, fcn_name);
}
}
@@ -3582,7 +3582,7 @@ server_smoke_check(void)
nerrors++;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: send_mssg() failed on write.\n",
+ HDfprintf(stdout, "%d:%s: send_mssg() failed on write.\n",
world_mpi_rank, fcn_name);
}
}
@@ -3597,7 +3597,7 @@ server_smoke_check(void)
nerrors++;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: recv_mssg() failed.\n",
+ HDfprintf(stdout, "%d:%s: recv_mssg() failed.\n",
world_mpi_rank, fcn_name);
}
}
@@ -3641,13 +3641,13 @@ server_smoke_check(void)
nerrors++;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: send_mssg() failed on done.\n",
+ HDfprintf(stdout, "%d:%s: send_mssg() failed on done.\n",
world_mpi_rank, fcn_name);
}
}
}
}
-
+
max_nerrors = get_max_nerrors();
if ( world_mpi_rank == 0 ) {
@@ -3684,7 +3684,7 @@ server_smoke_check(void)
* Modifications:
*
* None.
- *
+ *
*****************************************************************************/
hbool_t
@@ -3749,7 +3749,7 @@ smoke_check_1(void)
{
lock_entry(cache_ptr, file_ptr, i);
unlock_entry(cache_ptr, file_ptr, i, H5AC__NO_FLAGS_SET);
- rename_entry(cache_ptr, file_ptr, i,
+ rename_entry(cache_ptr, file_ptr, i,
(i + (virt_num_data_entries / 2)));
}
@@ -3758,7 +3758,7 @@ smoke_check_1(void)
{
lock_entry(cache_ptr, file_ptr, i);
unlock_entry(cache_ptr, file_ptr, i, H5AC__NO_FLAGS_SET);
- rename_entry(cache_ptr, file_ptr, i,
+ rename_entry(cache_ptr, file_ptr, i,
(i + (virt_num_data_entries / 2)));
}
@@ -3774,7 +3774,7 @@ smoke_check_1(void)
}
}
- /* verify that all instance of datum are back where the started
+ /* verify that all instance of datum are back where the started
* and are clean.
*/
@@ -3802,7 +3802,7 @@ smoke_check_1(void)
nerrors++;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: send_mssg() failed on done.\n",
+ HDfprintf(stdout, "%d:%s: send_mssg() failed on done.\n",
world_mpi_rank, fcn_name);
}
}
@@ -3853,7 +3853,7 @@ smoke_check_1(void)
*
* JRM -- 4/28/06
* Modified test to rename pinned entries.
- *
+ *
*****************************************************************************/
hbool_t
@@ -3927,11 +3927,11 @@ smoke_check_2(void)
{
lock_entry(cache_ptr, file_ptr, i);
unlock_entry(cache_ptr, file_ptr, i, H5AC__NO_FLAGS_SET);
- lock_and_unlock_random_entries(cache_ptr, file_ptr, 0,
- (virt_num_data_entries / 20),
+ lock_and_unlock_random_entries(cache_ptr, file_ptr, 0,
+ (virt_num_data_entries / 20),
0, 100);
- local_pin_and_unpin_random_entries(cache_ptr, file_ptr, 0,
- (virt_num_data_entries / 4),
+ local_pin_and_unpin_random_entries(cache_ptr, file_ptr, 0,
+ (virt_num_data_entries / 4),
0, 3);
}
@@ -3939,8 +3939,8 @@ smoke_check_2(void)
{
lock_entry(cache_ptr, file_ptr, i);
unlock_entry(cache_ptr, file_ptr, i, H5AC__DIRTIED_FLAG);
- lock_and_unlock_random_entries(cache_ptr, file_ptr, 0,
- (virt_num_data_entries / 10),
+ lock_and_unlock_random_entries(cache_ptr, file_ptr, 0,
+ (virt_num_data_entries / 10),
0, 100);
}
@@ -3952,10 +3952,10 @@ smoke_check_2(void)
{
lock_entry(cache_ptr, file_ptr, i);
unlock_entry(cache_ptr, file_ptr, i, H5AC__NO_FLAGS_SET);
- rename_entry(cache_ptr, file_ptr, i,
+ rename_entry(cache_ptr, file_ptr, i,
(i + (virt_num_data_entries / 2)));
- lock_and_unlock_random_entries(cache_ptr, file_ptr, 0,
- ((virt_num_data_entries / 50) - 1),
+ lock_and_unlock_random_entries(cache_ptr, file_ptr, 0,
+ ((virt_num_data_entries / 50) - 1),
0, 100);
}
@@ -3964,10 +3964,10 @@ smoke_check_2(void)
{
lock_entry(cache_ptr, file_ptr, i);
unlock_entry(cache_ptr, file_ptr, i, H5AC__DIRTIED_FLAG);
- rename_entry(cache_ptr, file_ptr, i,
+ rename_entry(cache_ptr, file_ptr, i,
(i + (virt_num_data_entries / 2)));
- lock_and_unlock_random_entries(cache_ptr, file_ptr, 0,
- (virt_num_data_entries / 100),
+ lock_and_unlock_random_entries(cache_ptr, file_ptr, 0,
+ (virt_num_data_entries / 100),
0, 100);
}
@@ -3991,7 +3991,7 @@ smoke_check_2(void)
}
}
- /* verify that all instance of datum are back where the started
+ /* verify that all instance of datum are back where the started
* and are clean.
*/
@@ -4019,13 +4019,13 @@ smoke_check_2(void)
nerrors++;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: send_mssg() failed on done.\n",
+ HDfprintf(stdout, "%d:%s: send_mssg() failed on done.\n",
world_mpi_rank, fcn_name);
}
}
}
}
-
+
max_nerrors = get_max_nerrors();
if ( world_mpi_rank == 0 ) {
@@ -4054,7 +4054,7 @@ smoke_check_2(void)
*
* Purpose: Third smoke check for the parallel cache.
*
- * Use random reads to vary the loads on the diffferent
+ * Use random reads to vary the loads on the diffferent
* processors. Also force different cache size adjustments.
*
* In this test, load process 0 heavily, and the other
@@ -4073,7 +4073,7 @@ smoke_check_2(void)
* JRM - 1/31/06
*
* Added pinned entry tests. JRM - 4/14/06
- *
+ *
*****************************************************************************/
hbool_t
@@ -4136,7 +4136,7 @@ smoke_check_3(void)
if ( i > 100 ) {
lock_and_unlock_random_entries(cache_ptr, file_ptr,
- (i - 100), i,
+ (i - 100), i,
min_count, max_count);
}
}
@@ -4145,8 +4145,8 @@ smoke_check_3(void)
min_count = 100 / ((file_mpi_rank + 2) * (file_mpi_rank + 2));
max_count = min_count + 50;
- for ( i = (virt_num_data_entries / 4);
- i < (virt_num_data_entries / 2);
+ for ( i = (virt_num_data_entries / 4);
+ i < (virt_num_data_entries / 2);
i++ )
{
@@ -4176,7 +4176,7 @@ smoke_check_3(void)
}
local_pin_and_unpin_random_entries(cache_ptr, file_ptr,
- 0, virt_num_data_entries / 4,
+ 0, virt_num_data_entries / 4,
0, (file_mpi_rank + 2));
}
@@ -4188,14 +4188,14 @@ smoke_check_3(void)
if ( H5Fflush(fid, H5F_SCOPE_GLOBAL) < 0 ) {
nerrors++;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: H5Fflush() failed.\n",
+ HDfprintf(stdout, "%d:%s: H5Fflush() failed.\n",
world_mpi_rank, fcn_name);
}
}
min_idx = 0;
- max_idx = ((virt_num_data_entries / 10) /
+ max_idx = ((virt_num_data_entries / 10) /
((file_mpi_rank + 1) * (file_mpi_rank + 1))) - 1;
if ( max_idx <= min_idx ) {
@@ -4212,15 +4212,15 @@ smoke_check_3(void)
HDassert( data[i].global_pinned );
HDassert( ! data[i].local_pinned );
- unpin_entry(cache_ptr, file_ptr, i, TRUE, dirty,
+ unpin_entry(cache_ptr, file_ptr, i, TRUE, dirty,
via_unprotect);
}
if ( i % 2 == 0 ) {
lock_entry(cache_ptr, file_ptr, i);
unlock_entry(cache_ptr, file_ptr, i, H5AC__NO_FLAGS_SET);
- local_pin_and_unpin_random_entries(cache_ptr, file_ptr, 0,
- virt_num_data_entries / 2,
+ local_pin_and_unpin_random_entries(cache_ptr, file_ptr, 0,
+ virt_num_data_entries / 2,
0, 2);
lock_and_unlock_random_entries(cache_ptr, file_ptr,
min_idx, max_idx, 0, 100);
@@ -4228,7 +4228,7 @@ smoke_check_3(void)
}
min_idx = 0;
- max_idx = ((virt_num_data_entries / 10) /
+ max_idx = ((virt_num_data_entries / 10) /
((file_mpi_rank + 3) * (file_mpi_rank + 3))) - 1;
if ( max_idx <= min_idx ) {
@@ -4254,10 +4254,10 @@ smoke_check_3(void)
{
lock_entry(cache_ptr, file_ptr, i);
unlock_entry(cache_ptr, file_ptr, i, H5AC__NO_FLAGS_SET);
- rename_entry(cache_ptr, file_ptr, i,
+ rename_entry(cache_ptr, file_ptr, i,
(i + (virt_num_data_entries / 2)));
- lock_and_unlock_random_entries(cache_ptr, file_ptr, 0,
- (virt_num_data_entries / 20),
+ lock_and_unlock_random_entries(cache_ptr, file_ptr, 0,
+ (virt_num_data_entries / 20),
min_count, max_count);
}
@@ -4266,9 +4266,9 @@ smoke_check_3(void)
{
lock_entry(cache_ptr, file_ptr, i);
unlock_entry(cache_ptr, file_ptr, i, H5AC__DIRTIED_FLAG);
- rename_entry(cache_ptr, file_ptr, i,
+ rename_entry(cache_ptr, file_ptr, i,
(i + (virt_num_data_entries / 2)));
- lock_and_unlock_random_entries(cache_ptr, file_ptr, 0,
+ lock_and_unlock_random_entries(cache_ptr, file_ptr, 0,
(virt_num_data_entries / 40),
min_count, max_count);
}
@@ -4281,8 +4281,8 @@ smoke_check_3(void)
for ( i = 0; i < (virt_num_data_entries / 2); i+=2 )
{
- local_pin_and_unpin_random_entries(cache_ptr, file_ptr, 0,
- (virt_num_data_entries / 2),
+ local_pin_and_unpin_random_entries(cache_ptr, file_ptr, 0,
+ (virt_num_data_entries / 2),
0, 5);
lock_entry(cache_ptr, file_ptr, i);
@@ -4291,7 +4291,7 @@ smoke_check_3(void)
if ( i > 100 ) {
lock_and_unlock_random_entries(cache_ptr, file_ptr,
- (i - 100), i,
+ (i - 100), i,
min_count, max_count);
}
}
@@ -4311,7 +4311,7 @@ smoke_check_3(void)
}
}
- /* verify that all instances of datum are back where the started
+ /* verify that all instances of datum are back where the started
* and are clean.
*/
@@ -4340,13 +4340,13 @@ smoke_check_3(void)
nerrors++;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: send_mssg() failed on done.\n",
+ HDfprintf(stdout, "%d:%s: send_mssg() failed on done.\n",
world_mpi_rank, fcn_name);
}
}
}
}
-
+
max_nerrors = get_max_nerrors();
if ( world_mpi_rank == 0 ) {
@@ -4375,7 +4375,7 @@ smoke_check_3(void)
*
* Purpose: Fourth smoke check for the parallel cache.
*
- * Use random reads to vary the loads on the diffferent
+ * Use random reads to vary the loads on the diffferent
* processors. Also force different cache size adjustments.
*
* In this test, load process 0 lightly, and the other
@@ -4392,7 +4392,7 @@ smoke_check_3(void)
* Added code intended to insure correct operation with large
* numbers of processors.
* JRM - 1/31/06
- *
+ *
*****************************************************************************/
hbool_t
@@ -4445,7 +4445,7 @@ smoke_check_4(void)
}
}
-
+
min_count = 100 * (file_mpi_rank % 4);
max_count = min_count + 50;
@@ -4456,7 +4456,7 @@ smoke_check_4(void)
if ( i > 100 ) {
lock_and_unlock_random_entries(cache_ptr, file_ptr,
- (i - 100), i,
+ (i - 100), i,
min_count, max_count);
}
}
@@ -4464,8 +4464,8 @@ smoke_check_4(void)
min_count = 10 * (file_mpi_rank % 4);
max_count = min_count + 100;
- for ( i = (virt_num_data_entries / 4);
- i < (virt_num_data_entries / 2);
+ for ( i = (virt_num_data_entries / 4);
+ i < (virt_num_data_entries / 2);
i++ )
{
insert_entry(cache_ptr, file_ptr, i, H5AC__NO_FLAGS_SET);
@@ -4493,7 +4493,7 @@ smoke_check_4(void)
min_count, max_count);
}
- local_pin_and_unpin_random_entries(cache_ptr, file_ptr, 0,
+ local_pin_and_unpin_random_entries(cache_ptr, file_ptr, 0,
(virt_num_data_entries / 4),
0, (file_mpi_rank + 2));
}
@@ -4512,7 +4512,7 @@ smoke_check_4(void)
min_idx = 0;
- max_idx = (((virt_num_data_entries / 10) / 4) *
+ max_idx = (((virt_num_data_entries / 10) / 4) *
((file_mpi_rank % 4) + 1)) - 1;
for ( i = (virt_num_data_entries / 2) - 1; i >= 0; i-- )
@@ -4538,7 +4538,7 @@ smoke_check_4(void)
}
min_idx = 0;
- max_idx = (((virt_num_data_entries / 10) / 8) *
+ max_idx = (((virt_num_data_entries / 10) / 8) *
((file_mpi_rank % 4) + 1)) - 1;
for ( i = 0; i < (virt_num_data_entries / 2); i+=2 )
@@ -4560,10 +4560,10 @@ smoke_check_4(void)
{
lock_entry(cache_ptr, file_ptr, i);
unlock_entry(cache_ptr, file_ptr, i, H5AC__NO_FLAGS_SET);
- rename_entry(cache_ptr, file_ptr, i,
+ rename_entry(cache_ptr, file_ptr, i,
(i + (virt_num_data_entries / 2)));
- lock_and_unlock_random_entries(cache_ptr, file_ptr, 0,
- (virt_num_data_entries / 20),
+ lock_and_unlock_random_entries(cache_ptr, file_ptr, 0,
+ (virt_num_data_entries / 20),
min_count, max_count);
}
@@ -4572,9 +4572,9 @@ smoke_check_4(void)
{
lock_entry(cache_ptr, file_ptr, i);
unlock_entry(cache_ptr, file_ptr, i, H5AC__DIRTIED_FLAG);
- rename_entry(cache_ptr, file_ptr, i,
+ rename_entry(cache_ptr, file_ptr, i,
(i + (virt_num_data_entries / 2)));
- lock_and_unlock_random_entries(cache_ptr, file_ptr, 0,
+ lock_and_unlock_random_entries(cache_ptr, file_ptr, 0,
(virt_num_data_entries / 40),
min_count, max_count);
}
@@ -4593,7 +4593,7 @@ smoke_check_4(void)
if ( i > 100 ) {
lock_and_unlock_random_entries(cache_ptr, file_ptr,
- (i - 100), i,
+ (i - 100), i,
min_count, max_count);
}
}
@@ -4610,7 +4610,7 @@ smoke_check_4(void)
}
}
- /* verify that all instance of datum are back where the started
+ /* verify that all instance of datum are back where the started
* and are clean.
*/
@@ -4639,13 +4639,13 @@ smoke_check_4(void)
nerrors++;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: send_mssg() failed on done.\n",
+ HDfprintf(stdout, "%d:%s: send_mssg() failed on done.\n",
world_mpi_rank, fcn_name);
}
}
}
}
-
+
max_nerrors = get_max_nerrors();
if ( world_mpi_rank == 0 ) {
@@ -4685,7 +4685,7 @@ smoke_check_4(void)
* Modifications:
*
* None.
- *
+ *
*****************************************************************************/
hbool_t
@@ -4743,7 +4743,7 @@ smoke_check_5(void)
if ( H5Fflush(fid, H5F_SCOPE_GLOBAL) < 0 ) {
nerrors++;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: H5Fflush() failed.\n",
+ HDfprintf(stdout, "%d:%s: H5Fflush() failed.\n",
world_mpi_rank, fcn_name);
}
}
@@ -4752,7 +4752,7 @@ smoke_check_5(void)
{
lock_entry(cache_ptr, file_ptr, i);
- if ( i % 2 == 0 )
+ if ( i % 2 == 0 )
{
mark_pinned_or_protected_entry_dirty(cache_ptr, file_ptr, i);
}
@@ -4760,22 +4760,22 @@ smoke_check_5(void)
unlock_entry(cache_ptr, file_ptr, i, H5AC__NO_FLAGS_SET);
}
- for ( i = (virt_num_data_entries / 2) - 1;
- i >= (virt_num_data_entries / 4);
+ for ( i = (virt_num_data_entries / 2) - 1;
+ i >= (virt_num_data_entries / 4);
i-- )
{
pin_entry(cache_ptr, file_ptr, i, TRUE, FALSE);
- if ( i % 2 == 0 )
+ if ( i % 2 == 0 )
{
if ( i % 4 == 0 )
{
- mark_pinned_or_protected_entry_dirty(cache_ptr,
+ mark_pinned_or_protected_entry_dirty(cache_ptr,
file_ptr, i);
}
else
{
- mark_pinned_entry_dirty(cache_ptr, file_ptr, i,
+ mark_pinned_entry_dirty(cache_ptr, file_ptr, i,
FALSE, (size_t)0);
}
}
@@ -4794,7 +4794,7 @@ smoke_check_5(void)
}
}
- /* verify that all instance of datum are back where the started
+ /* verify that all instance of datum are back where the started
* and are clean.
*/
@@ -4822,7 +4822,7 @@ smoke_check_5(void)
nerrors++;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: send_mssg() failed on done.\n",
+ HDfprintf(stdout, "%d:%s: send_mssg() failed on done.\n",
world_mpi_rank, fcn_name);
}
}
@@ -4866,7 +4866,7 @@ smoke_check_5(void)
* Modifications:
*
* None.
- *
+ *
*****************************************************************************/
int
@@ -4928,7 +4928,7 @@ main(int argc, char **argv)
/* h5_fixname() will hang some processes don't participate.
*
- * Thus we set up the fapl global with the world communicator,
+ * Thus we set up the fapl global with the world communicator,
* make our calls to h5_fixname(), discard the fapl, and then
* create it again with the file communicator.
*/
@@ -4937,7 +4937,7 @@ main(int argc, char **argv)
if ( FAIL == (fapl = H5Pcreate(H5P_FILE_ACCESS)) ) {
nerrors++;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: H5Pcreate() failed 1.\n",
+ HDfprintf(stdout, "%d:%s: H5Pcreate() failed 1.\n",
world_mpi_rank, fcn_name);
}
}
@@ -4946,20 +4946,20 @@ main(int argc, char **argv)
nerrors++;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: H5Pset_fapl_mpio() failed 1.\n",
+ HDfprintf(stdout, "%d:%s: H5Pset_fapl_mpio() failed 1.\n",
world_mpi_rank, fcn_name);
}
}
/* fix the file names */
- for ( u = 0; u < sizeof(FILENAME) / sizeof(FILENAME[0]) - 1; ++u )
+ for ( u = 0; u < sizeof(FILENAME) / sizeof(FILENAME[0]) - 1; ++u )
{
- if ( h5_fixname(FILENAME[u], fapl, filenames[u],
+ if ( h5_fixname(FILENAME[u], fapl, filenames[u],
sizeof(filenames[u])) == NULL ) {
nerrors++;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: h5_fixname() failed.\n",
+ HDfprintf(stdout, "%d:%s: h5_fixname() failed.\n",
world_mpi_rank, fcn_name);
}
break;
@@ -4970,7 +4970,7 @@ main(int argc, char **argv)
if ( H5Pclose(fapl) < 0 ) {
nerrors++;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: H5Pclose() failed.\n",
+ HDfprintf(stdout, "%d:%s: H5Pclose() failed.\n",
world_mpi_rank, fcn_name);
}
}
@@ -4982,7 +4982,7 @@ main(int argc, char **argv)
if ( FAIL == (fapl = H5Pcreate(H5P_FILE_ACCESS)) ) {
nerrors++;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: H5Pcreate() failed 2.\n",
+ HDfprintf(stdout, "%d:%s: H5Pcreate() failed 2.\n",
world_mpi_rank, fcn_name);
}
}
@@ -4991,14 +4991,14 @@ main(int argc, char **argv)
nerrors++;
if ( verbose ) {
- HDfprintf(stdout, "%d:%s: H5Pset_fapl_mpio() failed 2.\n",
+ HDfprintf(stdout, "%d:%s: H5Pset_fapl_mpio() failed 2.\n",
world_mpi_rank, fcn_name);
}
}
}
setup_rand();
-
+
max_nerrors = get_max_nerrors();
if ( max_nerrors != 0 ) {
@@ -5027,10 +5027,10 @@ main(int argc, char **argv)
#endif
#if 1
smoke_check_4();
-#endif
+#endif
#if 1
smoke_check_5();
-#endif
+#endif
finish:
/* make sure all processes are finished before final report, cleanup
@@ -5040,7 +5040,7 @@ finish:
if (MAINPROCESS){ /* only process 0 reports */
printf("===================================\n");
if (failures){
- printf("***metadata cache tests detected %d failures***\n",
+ printf("***metadata cache tests detected %d failures***\n",
failures);
}
else{
diff --git a/testpar/t_chunk_alloc.c b/testpar/t_chunk_alloc.c
index 7186099..70091db 100644
--- a/testpar/t_chunk_alloc.c
+++ b/testpar/t_chunk_alloc.c
@@ -12,7 +12,7 @@
* access to either file, you may request a copy from hdfhelp@ncsa.uiuc.edu. *
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
-/*
+/*
* This verifies if the storage space allocation methods are compatible between
* serial and parallel modes.
*
@@ -23,7 +23,7 @@
#include "testphdf5.h"
static int mpi_size, mpi_rank;
-#define DATASETNAME "ExtendibleArray"
+#define DATASETNAME "ExtendibleArray"
#define CHUNKSIZE 1000 /* #elements per chunk */
#define DSETCHUNKS 20000
#define CLOSE 1
@@ -71,11 +71,11 @@ void
create_chunked_dataset(const char *filename, int nchunks, write_type write_pattern)
{
hid_t file_id, dataset; /* handles */
- hid_t dataspace,memspace;
+ hid_t dataspace,memspace;
hid_t cparms;
hsize_t dims[1];
hsize_t maxdims[1] = {H5S_UNLIMITED};
-
+
hsize_t chunk_dims[1] ={CHUNKSIZE};
hsize_t count[1];
hsize_t stride[1];
@@ -85,7 +85,7 @@ create_chunked_dataset(const char *filename, int nchunks, write_type write_patte
char buffer[CHUNKSIZE];
int i;
- herr_t hrc;
+ herr_t hrc;
MPI_Offset filesize, /* actual file size */
est_filesize; /* estimated file size */
@@ -99,12 +99,12 @@ create_chunked_dataset(const char *filename, int nchunks, write_type write_patte
dims[0]=nchunks*CHUNKSIZE;
/* Create the data space with unlimited dimensions. */
- dataspace = H5Screate_simple (1, dims, maxdims);
+ dataspace = H5Screate_simple (1, dims, maxdims);
VRFY((dataspace >= 0), "");
memspace = H5Screate_simple(1, chunk_dims, NULL);
VRFY((memspace >= 0), "");
-
+
/* Create a new file. If file exists its contents will be overwritten. */
file_id = H5Fcreate(h5_rmprefix(filename), H5F_ACC_TRUNC, H5P_DEFAULT,
H5P_DEFAULT);
@@ -183,7 +183,7 @@ create_chunked_dataset(const char *filename, int nchunks, write_type write_patte
*/
MPI_Barrier(MPI_COMM_WORLD);
-}
+}
/*
@@ -242,7 +242,7 @@ parallel_access_dataset(const char *filename, int nchunks, access_type action, h
memspace = H5Screate_simple(1, chunk_dims, NULL);
VRFY((memspace >= 0), "");
- dataspace = H5Dget_space(*dataset);
+ dataspace = H5Dget_space(*dataset);
VRFY((dataspace >= 0), "");
size[0] = nchunks*CHUNKSIZE;
@@ -256,7 +256,7 @@ parallel_access_dataset(const char *filename, int nchunks, access_type action, h
count[0] = 1;
stride[0] = 1;
block[0] = chunk_dims[0];
- for (i=0; i<(nchunks+mpi_size-1)/mpi_size; i++){
+ for (i=0; i<(nchunks+mpi_size-1)/mpi_size; i++){
if (i*mpi_size+mpi_rank < nchunks){
offset[0] = (i*mpi_size+mpi_rank)*chunk_dims[0];
@@ -373,14 +373,14 @@ void verify_data(const char *filename, int nchunks, write_type write_pattern, in
memspace = H5Screate_simple(1, chunk_dims, NULL);
VRFY((memspace >= 0), "");
- dataspace = H5Dget_space(*dataset);
+ dataspace = H5Dget_space(*dataset);
VRFY((dataspace >= 0), "");
/* all processes check all chunks. */
count[0] = 1;
stride[0] = 1;
block[0] = chunk_dims[0];
- for (i=0; i<nchunks; i++){
+ for (i=0; i<nchunks; i++){
/* reset buffer values */
memset(buffer, -1, CHUNKSIZE);
@@ -411,7 +411,7 @@ void verify_data(const char *filename, int nchunks, write_type write_pattern, in
/* verify content of the chunk */
for (index = 0; index < CHUNKSIZE; index++)
VRFY((buffer[index] == value), "data verification");
-
+
}
hrc = H5Sclose (dataspace);
@@ -469,7 +469,7 @@ test_chunk_alloc(void)
hid_t file_id, dataset;
file_id = dataset = -1;
-
+
filename = GetTestParameters();
if (VERBOSE_MED)
printf("Extend Chunked allocation test on file %s\n", filename);
@@ -480,7 +480,7 @@ test_chunk_alloc(void)
/* reopen dataset in parallel and check for file size */
parallel_access_dataset(filename, DSETCHUNKS, open_only, &file_id, &dataset);
/* reopen dataset in parallel, read and verify the data */
- verify_data(filename, DSETCHUNKS, none, CLOSE, &file_id, &dataset);
+ verify_data(filename, DSETCHUNKS, none, CLOSE, &file_id, &dataset);
/* Case 2 */
/* Create chunked dataset without writing anything */
@@ -494,10 +494,10 @@ test_chunk_alloc(void)
/* Create chunked dataset and write in the second to last chunk */
create_chunked_dataset(filename, DSETCHUNKS, sec_last);
/* Reopen dataset in parallel, read and verify the data. The file and dataset are not closed*/
- verify_data(filename, DSETCHUNKS, sec_last, NO_CLOSE, &file_id, &dataset);
+ verify_data(filename, DSETCHUNKS, sec_last, NO_CLOSE, &file_id, &dataset);
/* All processes write in all the chunks in a interleaved way */
parallel_access_dataset(filename, DSETCHUNKS, write_all, &file_id, &dataset);
/* reopen dataset in parallel, read and verify the data */
- verify_data(filename, DSETCHUNKS, all, CLOSE, &file_id, &dataset);
+ verify_data(filename, DSETCHUNKS, all, CLOSE, &file_id, &dataset);
}
diff --git a/testpar/t_coll_chunk.c b/testpar/t_coll_chunk.c
index 5fe6207..1476fc7 100644
--- a/testpar/t_coll_chunk.c
+++ b/testpar/t_coll_chunk.c
@@ -35,7 +35,7 @@ static void coll_chunktest(const char* filename,int chunk_factor,int select_fact
/*-------------------------------------------------------------------------
* Function: coll_chunk1
*
- * Purpose: Wrapper to test the collective chunk IO for regular JOINT
+ * Purpose: Wrapper to test the collective chunk IO for regular JOINT
selection with a single chunk
*
* Return: Success: 0
@@ -52,7 +52,7 @@ static void coll_chunktest(const char* filename,int chunk_factor,int select_fact
/* ------------------------------------------------------------------------
* Descriptions for the selection: One big singluar selection inside one chunk
- * Two dimensions,
+ * Two dimensions,
*
* dim1 = SPACE_DIM1(5760)*mpi_size
* dim2 = SPACE_DIM2(3)
@@ -82,7 +82,7 @@ coll_chunk1(void)
/*-------------------------------------------------------------------------
* Function: coll_chunk2
*
- * Purpose: Wrapper to test the collective chunk IO for regular DISJOINT
+ * Purpose: Wrapper to test the collective chunk IO for regular DISJOINT
selection with a single chunk
*
* Return: Success: 0
@@ -99,7 +99,7 @@ coll_chunk1(void)
/* ------------------------------------------------------------------------
* Descriptions for the selection: many disjoint selections inside one chunk
- * Two dimensions,
+ * Two dimensions,
*
* dim1 = SPACE_DIM1*mpi_size(5760)
* dim2 = SPACE_DIM2(3)
@@ -111,7 +111,7 @@ coll_chunk1(void)
* count1 = SPACE_DIM2/stride(3/3 = 1)
* start0 = mpi_rank*SPACE_DIM1
* start1 = 0
- *
+ *
* ------------------------------------------------------------------------
*/
void
@@ -129,7 +129,7 @@ coll_chunk2(void)
/*-------------------------------------------------------------------------
* Function: coll_chunk3
*
- * Purpose: Wrapper to test the collective chunk IO for regular JOINT
+ * Purpose: Wrapper to test the collective chunk IO for regular JOINT
selection with at least number of 2*mpi_size chunks
*
* Return: Success: 0
@@ -158,7 +158,7 @@ coll_chunk2(void)
* count1 = SPACE_DIM2(3)
* start0 = mpi_rank*SPACE_DIM1
* start1 = 0
- *
+ *
* ------------------------------------------------------------------------
*/
@@ -180,7 +180,7 @@ coll_chunk3(void)
/*-------------------------------------------------------------------------
* Function: coll_chunk4
*
- * Purpose: Wrapper to test the collective chunk IO for regular JOINT
+ * Purpose: Wrapper to test the collective chunk IO for regular JOINT
selection with at least number of 2*mpi_size chunks
*
* Return: Success: 0
@@ -209,7 +209,7 @@ coll_chunk3(void)
* count1 = SPACE_DIM2(3)
* start0 = mpi_rank*SPACE_DIM1
* start1 = 0
- *
+ *
* ------------------------------------------------------------------------
*/
@@ -230,7 +230,7 @@ coll_chunk4(void)
/*-------------------------------------------------------------------------
* Function: coll_chunk4
*
- * Purpose: Wrapper to test the collective chunk IO for regular JOINT
+ * Purpose: Wrapper to test the collective chunk IO for regular JOINT
selection with at least number of 2*mpi_size chunks
*
* Return: Success: 0
@@ -259,7 +259,7 @@ coll_chunk4(void)
* count1 = SPACE_DIM2(3)
* start0 = mpi_rank*SPACE_DIM1
* start1 = 0
- *
+ *
* ------------------------------------------------------------------------
*/
@@ -280,7 +280,7 @@ coll_chunk5(void)
/*-------------------------------------------------------------------------
* Function: coll_chunk6
*
- * Purpose: Wrapper to test the collective chunk IO for regular JOINT
+ * Purpose: Wrapper to test the collective chunk IO for regular JOINT
selection with at least number of 2*mpi_size chunks
*
* Return: Success: 0
@@ -309,7 +309,7 @@ coll_chunk5(void)
* count1 = SPACE_DIM2(3)
* start0 = mpi_rank*SPACE_DIM1
* start1 = 0
- *
+ *
* ------------------------------------------------------------------------
*/
@@ -330,7 +330,7 @@ coll_chunk6(void)
/*-------------------------------------------------------------------------
* Function: coll_chunk7
*
- * Purpose: Wrapper to test the collective chunk IO for regular JOINT
+ * Purpose: Wrapper to test the collective chunk IO for regular JOINT
selection with at least number of 2*mpi_size chunks
*
* Return: Success: 0
@@ -359,7 +359,7 @@ coll_chunk6(void)
* count1 = SPACE_DIM2(3)
* start0 = mpi_rank*SPACE_DIM1
* start1 = 0
- *
+ *
* ------------------------------------------------------------------------
*/
@@ -380,7 +380,7 @@ coll_chunk7(void)
/*-------------------------------------------------------------------------
* Function: coll_chunk8
*
- * Purpose: Wrapper to test the collective chunk IO for regular JOINT
+ * Purpose: Wrapper to test the collective chunk IO for regular JOINT
selection with at least number of 2*mpi_size chunks
*
* Return: Success: 0
@@ -409,7 +409,7 @@ coll_chunk7(void)
* count1 = SPACE_DIM2(3)
* start0 = mpi_rank*SPACE_DIM1
* start1 = 0
- *
+ *
* ------------------------------------------------------------------------
*/
@@ -430,7 +430,7 @@ coll_chunk8(void)
/*-------------------------------------------------------------------------
* Function: coll_chunk9
*
- * Purpose: Wrapper to test the collective chunk IO for regular JOINT
+ * Purpose: Wrapper to test the collective chunk IO for regular JOINT
selection with at least number of 2*mpi_size chunks
*
* Return: Success: 0
@@ -459,7 +459,7 @@ coll_chunk8(void)
* count1 = SPACE_DIM2(3)
* start0 = mpi_rank*SPACE_DIM1
* start1 = 0
- *
+ *
* ------------------------------------------------------------------------
*/
@@ -480,7 +480,7 @@ coll_chunk9(void)
/*-------------------------------------------------------------------------
* Function: coll_chunk10
*
- * Purpose: Wrapper to test the collective chunk IO for regular JOINT
+ * Purpose: Wrapper to test the collective chunk IO for regular JOINT
selection with at least number of 2*mpi_size chunks
*
* Return: Success: 0
@@ -509,7 +509,7 @@ coll_chunk9(void)
* count1 = SPACE_DIM2(3)
* start0 = mpi_rank*SPACE_DIM1
* start1 = 0
- *
+ *
* ------------------------------------------------------------------------
*/
@@ -534,7 +534,7 @@ coll_chunk10(void)
* Purpose: The real testing routine for regular selection of collective
chunking storage
testing both write and read,
- If anything fails, it may be read or write. There is no
+ If anything fails, it may be read or write. There is no
separation test between read and write.
*
* Return: Success: 0
@@ -613,7 +613,7 @@ coll_chunktest(const char* filename,
chunk_dims[0] = dims[0]/chunk_factor;
/* to decrease the testing time, maintain bigger chunk size */
-
+
(chunk_factor == 1) ? (chunk_dims[1] = SPACE_DIM2) : (chunk_dims[1] = SPACE_DIM2/2);
status = H5Pset_chunk(crp_plist, 2, chunk_dims);
VRFY((status >= 0),"chunk creation property list succeeded");
@@ -671,8 +671,8 @@ coll_chunktest(const char* filename,
break;
default:
;
- }
-
+ }
+
#ifdef H5_HAVE_INSTRUMENTED_LIBRARY
if(facc_type == FACC_MPIO) {
switch(api_option){
@@ -683,44 +683,44 @@ coll_chunktest(const char* filename,
VRFY((status >= 0),"testing property list inserted succeeded");
break;
case API_MULTI_HARD:
- prop_value = H5D_XFER_COLL_CHUNK_DEF;
+ prop_value = H5D_XFER_COLL_CHUNK_DEF;
status = H5Pinsert(xfer_plist,H5D_XFER_COLL_CHUNK_MULTI_HARD_NAME,H5D_XFER_COLL_CHUNK_SIZE,&prop_value,
NULL,NULL,NULL,NULL,NULL,NULL);
VRFY((status >= 0),"testing property list inserted succeeded");
break;
case API_LINK_TRUE:
- prop_value = H5D_XFER_COLL_CHUNK_DEF;
+ prop_value = H5D_XFER_COLL_CHUNK_DEF;
status = H5Pinsert(xfer_plist,H5D_XFER_COLL_CHUNK_LINK_NUM_TRUE_NAME,H5D_XFER_COLL_CHUNK_SIZE,&prop_value,
NULL,NULL,NULL,NULL,NULL,NULL);
VRFY((status >= 0),"testing property list inserted succeeded");
break;
case API_LINK_FALSE:
- prop_value = H5D_XFER_COLL_CHUNK_DEF;
+ prop_value = H5D_XFER_COLL_CHUNK_DEF;
status = H5Pinsert(xfer_plist,H5D_XFER_COLL_CHUNK_LINK_NUM_FALSE_NAME,H5D_XFER_COLL_CHUNK_SIZE,&prop_value,
NULL,NULL,NULL,NULL,NULL,NULL);
VRFY((status >= 0),"testing property list inserted succeeded");
-
+
break;
case API_MULTI_COLL:
- prop_value = H5D_XFER_COLL_CHUNK_DEF;
+ prop_value = H5D_XFER_COLL_CHUNK_DEF;
status = H5Pinsert(xfer_plist,H5D_XFER_COLL_CHUNK_MULTI_RATIO_COLL_NAME,H5D_XFER_COLL_CHUNK_SIZE,&prop_value,
NULL,NULL,NULL,NULL,NULL,NULL);
VRFY((status >= 0),"testing property list inserted succeeded");
-
+
break;
case API_MULTI_IND:
- prop_value = H5D_XFER_COLL_CHUNK_DEF;
+ prop_value = H5D_XFER_COLL_CHUNK_DEF;
status = H5Pinsert(xfer_plist,H5D_XFER_COLL_CHUNK_MULTI_RATIO_IND_NAME,H5D_XFER_COLL_CHUNK_SIZE,&prop_value,
NULL,NULL,NULL,NULL,NULL,NULL);
VRFY((status >= 0),"testing property list inserted succeeded");
-
+
break;
default:
;
- }
+ }
}
#endif
-
+
/* write data collectively */
status = H5Dwrite(dataset, H5T_NATIVE_INT, H5S_ALL, file_dataspace,
xfer_plist, data_array1);
@@ -761,7 +761,7 @@ coll_chunktest(const char* filename,
break;
default:
;
- }
+ }
}
#endif
@@ -779,7 +779,7 @@ coll_chunktest(const char* filename,
if (data_array1) HDfree(data_array1);
-
+
/* Use collective read to verify the correctness of collective write. */
/* allocate memory for data buffer */
@@ -851,12 +851,12 @@ coll_chunktest(const char* filename,
/* Set up the selection */
static void
-ccslab_set(int mpi_rank,
- int mpi_size,
- hsize_t start[],
+ccslab_set(int mpi_rank,
+ int mpi_size,
+ hsize_t start[],
hsize_t count[],
- hsize_t stride[],
- hsize_t block[],
+ hsize_t stride[],
+ hsize_t block[],
int mode)
{
@@ -905,7 +905,7 @@ ccslab_set(int mpi_rank,
case BYROW_SELECTUNBALANCE:
/* The first one-third of the number of processes only
select top half of the domain, The rest will select the bottom
- half of the domain. */
+ half of the domain. */
block[0] = 1;
count[0] = 2;
@@ -915,9 +915,9 @@ ccslab_set(int mpi_rank,
start[1] = 0;
stride[1] = 1;
if((mpi_rank *3)<(mpi_size*2)) start[0] = mpi_rank;
- else start[0] = 1 + SPACE_DIM1*mpi_size/2 + (mpi_rank-2*mpi_size/3);
+ else start[0] = 1 + SPACE_DIM1*mpi_size/2 + (mpi_rank-2*mpi_size/3);
break;
-
+
case BYROW_SELECTINCHUNK:
/* Each process will only select one chunk */
@@ -959,10 +959,10 @@ ccslab_set(int mpi_rank,
* Assume dimension rank is 2.
*/
static void
-ccdataset_fill(hsize_t start[],
+ccdataset_fill(hsize_t start[],
hsize_t stride[],
- hsize_t count[],
- hsize_t block[],
+ hsize_t count[],
+ hsize_t block[],
DATATYPE * dataset)
{
DATATYPE *dataptr = dataset;
@@ -994,8 +994,8 @@ ccdataset_fill(hsize_t start[],
* Print the first block of the content of the dataset.
*/
static void
-ccdataset_print(hsize_t start[],
- hsize_t block[],
+ccdataset_print(hsize_t start[],
+ hsize_t block[],
DATATYPE * dataset)
{
@@ -1025,11 +1025,11 @@ ccdataset_print(hsize_t start[],
* Print the content of the dataset.
*/
static int
-ccdataset_vrfy(hsize_t start[],
- hsize_t count[],
- hsize_t stride[],
- hsize_t block[],
- DATATYPE *dataset,
+ccdataset_vrfy(hsize_t start[],
+ hsize_t count[],
+ hsize_t stride[],
+ hsize_t block[],
+ DATATYPE *dataset,
DATATYPE *original)
{
hsize_t i, j,k1,k2;
diff --git a/testpar/t_mpi.c b/testpar/t_mpi.c
index 1ec47f5..a150213 100644
--- a/testpar/t_mpi.c
+++ b/testpar/t_mpi.c
@@ -833,7 +833,7 @@ static int test_mpio_derived_dtype(char *filename) {
Function: test_mpio_special_collective
-Test Whether collective IO is still working when more than one process
+Test Whether collective IO is still working when more than one process
has no contribution to IO. To properly test this case, at least FOUR
processes are needed.
@@ -867,7 +867,7 @@ static int test_mpio_special_collective(char *filename) {
char writedata[2];
char *buf;
char expect_val;
- int i, irank;
+ int i, irank;
int count,bufcount;
int blocklens[2];
MPI_Aint offsets[2];
@@ -883,7 +883,7 @@ static int test_mpio_special_collective(char *filename) {
/* create MPI data type */
etype = MPI_BYTE;
if(mpi_rank == 0 || mpi_rank == 1) {
- count = DIMSIZE;
+ count = DIMSIZE;
bufcount = 1;
}
else {
@@ -895,8 +895,8 @@ static int test_mpio_special_collective(char *filename) {
offsets[0] = mpi_rank*count;
blocklens[1] = count;
offsets[1] = (mpi_size+mpi_rank)*count;
-
- if(count !=0) {
+
+ if(count !=0) {
if((mpi_err= MPI_Type_hindexed(2,blocklens,offsets,etype,&filetype))
!= MPI_SUCCESS){
MPI_Error_string(mpi_err, mpi_err_str, &mpi_err_strlen);
@@ -969,7 +969,7 @@ static int test_mpio_special_collective(char *filename) {
printf("MPI_File_close failed. \n");
return 1;
};
-
+
mpi_err = MPI_Barrier(MPI_COMM_WORLD);
#ifdef H5_MPI_SPECIAL_COLLECTIVE_IO_WORKS
if(retcode != 0) {
@@ -1208,14 +1208,14 @@ main(int argc, char **argv)
*/
if(mpi_size !=4){
MPI_BANNER("MPIO special collective io test SKIPPED.");
- if(mpi_rank == 0){
+ if(mpi_rank == 0){
printf("Use FOUR processes to run this test\n");
printf("If you still see the <test SKIPPED>, use <-vh> option to verify the test\n");
}
ret_code = 0;
goto sc_finish;
}
-
+
#ifdef H5_MPI_SPECIAL_COLLECTIVE_IO_WORKS
MPI_BANNER("MPIO special collective io test...");
ret_code = test_mpio_special_collective(filenames[0]);
@@ -1230,7 +1230,7 @@ main(int argc, char **argv)
}
#endif
-sc_finish:
+sc_finish:
ret_code = errors_sum(ret_code);
if (mpi_rank==0 && ret_code > 0){
printf("***FAILED with %d total errors\n", ret_code);
diff --git a/testpar/t_posix_compliant.c b/testpar/t_posix_compliant.c
index 6a54cfd..0008b05 100644
--- a/testpar/t_posix_compliant.c
+++ b/testpar/t_posix_compliant.c
@@ -11,23 +11,23 @@
* http://hdf.ncsa.uiuc.edu/HDF5/doc/Copyright.html. If you do not have *
* access to either file, you may request a copy from hdfhelp@ncsa.uiuc.edu. *
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
-
+
/* A series of tests for posix compliance
*
- * These tests do increasingly complicated sets of writes followed by reads.
+ * These tests do increasingly complicated sets of writes followed by reads.
* POSIX standards say that any read that can be proven to occur after a write
* must include the data in that write. These tests attempt to verify whether the
* underlying filesystem and i/o layer provide such guarantees.
*
* There are two sets of tests, one which uses POSIX i/o (fread, fwrite) and one which
* uses MPI I/O (MPI_File_read, MPI_File_write). Each set has multiple sub-tests, which
- * test varying patters of writes and reads.
- *
+ * test varying patters of writes and reads.
+ *
*
* TODO:
* Add corresponding posix i/o tests for each MPI i/o test. Currently, not all of the
* MPI IO tests are implemented using fwrite/fread.
- *
+ *
* Leon Arber
* larber@ncsa.uiuc.edu
*/
@@ -38,7 +38,7 @@
* then run it as an MPI application. E.g.,
* mpirun -np 3 ./t_posix_compliant
*/
-
+
#include <unistd.h>
#include <stdio.h>
#include <string.h>
@@ -90,7 +90,7 @@ static void vrfy_elements(int* a, int* b, int size, int rank);
static int find_writesize(int rank, int numprocs, int write_size);
-/* All writes are to non-overlapping locations in the file
+/* All writes are to non-overlapping locations in the file
* Then, each task reads another tasks' data
* */
@@ -122,7 +122,7 @@ static int allwrite_allread_blocks(int numprocs, int rank, int write_size)
mpio_result = MPI_File_read_at(fh, offset, readbuf, write_size, MPI_INT, &Status);
CHECK_SUCCESS(mpio_result);
-
+
vrfy_elements(writebuf, readbuf, write_size, rank);
mpio_result = MPI_File_close(&fh);
@@ -172,9 +172,9 @@ static int posix_allwrite_allread_blocks(int numprocs, int rank, int write_size)
perror("fwrite");
MPI_Abort(MPI_COMM_WORLD, 1);
}
-
+
MPI_Barrier(MPI_COMM_WORLD);
-
+
offset = ( (rank+(numprocs-1)) % numprocs)*write_size*sizeof(int);
ret = fseek(file, offset, SEEK_SET);
@@ -192,7 +192,7 @@ static int posix_allwrite_allread_blocks(int numprocs, int rank, int write_size)
perror("Error encountered in fread");
MPI_Abort(MPI_COMM_WORLD, 1);
}
-
+
vrfy_elements(writebuf, readbuf, write_size, rank);
fclose(file);
@@ -251,9 +251,9 @@ static int posix_onewrite_allread_blocks(int numprocs, int rank, int write_size)
}
}
- }
+ }
MPI_Barrier(MPI_COMM_WORLD);
-
+
offset = rank*write_size*sizeof(int);
ret = fseek(file, offset, SEEK_SET);
@@ -271,7 +271,7 @@ static int posix_onewrite_allread_blocks(int numprocs, int rank, int write_size)
perror("Error encountered in fread");
MPI_Abort(MPI_COMM_WORLD, 1);
}
-
+
vrfy_elements(writebuf, readbuf, write_size, rank);
fclose(file);
@@ -331,9 +331,9 @@ static int posix_onewrite_allread_interlaced(int numprocs, int rank, int write_s
}
}
- }
+ }
MPI_Barrier(MPI_COMM_WORLD);
-
+
index = 0;
for(offset = rank*sizeof(int); offset<numprocs*write_size*sizeof(int); offset+=(numprocs*sizeof(int)))
{
@@ -356,7 +356,7 @@ static int posix_onewrite_allread_interlaced(int numprocs, int rank, int write_s
index++;
}
-
+
for(i=0; i<write_size; i++)
writebuf[i] = i;
@@ -393,7 +393,7 @@ static int allwrite_allread_interlaced(int numprocs, int rank, int write_size)
writebuf[i] = i;
- amode = MPI_MODE_CREATE | MPI_MODE_RDWR | MPI_MODE_DELETE_ON_CLOSE;
+ amode = MPI_MODE_CREATE | MPI_MODE_RDWR | MPI_MODE_DELETE_ON_CLOSE;
mpio_result = MPI_File_open(MPI_COMM_WORLD, testfile, amode, MPI_INFO_NULL, &fh);
CHECK_SUCCESS(mpio_result);
@@ -402,15 +402,15 @@ static int allwrite_allread_interlaced(int numprocs, int rank, int write_size)
mpio_result = MPI_Type_commit(&filetype);
CHECK_SUCCESS(mpio_result);
-
+
mpio_result = MPI_File_set_view(fh, rank*sizeof(int), MPI_INT, filetype, "native", MPI_INFO_NULL);
CHECK_SUCCESS(mpio_result);
-
+
mpio_result = MPI_File_write(fh, writebuf, write_size, MPI_INT, &Status);
CHECK_SUCCESS(mpio_result);
MPI_Barrier(MPI_COMM_WORLD);
-
+
mpio_result = MPI_File_set_view(fh, 0, MPI_BYTE, MPI_BYTE, "native", MPI_INFO_NULL);
CHECK_SUCCESS(mpio_result);
@@ -446,7 +446,7 @@ static int allwrite_allread_interlaced(int numprocs, int rank, int write_size)
/* Overlapping pattern works as follows (this test requires at least 2 procs:
* Writes:
- * Task 0: 0 2 4 6 etc...
+ * Task 0: 0 2 4 6 etc...
* Task 1: 1 3 5 7 etc...
* Task 2: 0 3 6 etc..
* Task 3: 0 4 8 etc...
@@ -477,7 +477,7 @@ static int allwrite_allread_interlaced(int numprocs, int rank, int write_size)
static int allwrite_allread_overlap(int numprocs, int rank, int write_size)
{
-
+
MPI_File fh = MPI_FILE_NULL;
int mpio_result;
int amode, i, counter = 0;
@@ -491,7 +491,7 @@ static int allwrite_allread_overlap(int numprocs, int rank, int write_size)
fprintf(stderr, "The allwrite_allread_overlap test requires at least 2 procs\n");
return -1;
}
-
+
if(rank == 0)
{
for(i=0; i<write_size*(numprocs-1); i++)
@@ -511,7 +511,7 @@ static int allwrite_allread_overlap(int numprocs, int rank, int write_size)
amode = MPI_MODE_CREATE | MPI_MODE_RDWR | MPI_MODE_DELETE_ON_CLOSE;
mpio_result = MPI_File_open(MPI_COMM_WORLD, testfile, amode, MPI_INFO_NULL, &fh);
CHECK_SUCCESS(mpio_result);
-
+
if( (rank == 0) || (rank == 1) )
mpio_result = MPI_Type_vector(write_size*(numprocs-1), 1, 2, MPI_INT, &filetype);
else
@@ -520,13 +520,13 @@ static int allwrite_allread_overlap(int numprocs, int rank, int write_size)
mpio_result = MPI_Type_commit(&filetype);
CHECK_SUCCESS(mpio_result);
-
+
if( rank == 1)
mpio_result = MPI_File_set_view(fh, sizeof(int), MPI_INT, filetype, "native", MPI_INFO_NULL);
- else
+ else
mpio_result = MPI_File_set_view(fh, 0, MPI_INT, filetype, "native", MPI_INFO_NULL);
CHECK_SUCCESS(mpio_result);
-
+
if( rank == (numprocs - 1))
mpio_result = MPI_File_write(fh, writebuf, write_size, MPI_INT, &Status);
else
@@ -544,7 +544,7 @@ static int allwrite_allread_overlap(int numprocs, int rank, int write_size)
for(i=0; i<write_size*(numprocs-1); i++)
{
if(i != readbuf[i])
- {
+ {
if( (rank == 0) && (counter == 0))
printf("\n");
if(counter++ < max_err_print)
@@ -603,7 +603,7 @@ static int onewrite_allread_blocks(int numprocs, int rank, int write_size)
CHECK_SUCCESS(mpio_result);
vrfy_elements(writebuf, readbuf, write_size, rank);
-
+
mpio_result = MPI_File_close(&fh);
CHECK_SUCCESS(mpio_result);
HDfree(writebuf);
@@ -634,17 +634,17 @@ static int onewrite_allread_interlaced(int numprocs, int rank, int write_size)
amode = MPI_MODE_CREATE | MPI_MODE_RDWR | MPI_MODE_DELETE_ON_CLOSE;
mpio_result = MPI_File_open(MPI_COMM_WORLD, testfile, amode, MPI_INFO_NULL, &fh);
CHECK_SUCCESS(mpio_result);
-
+
mpio_result = MPI_Type_vector(write_size, 1, numprocs, MPI_INT, &filetype);
CHECK_SUCCESS(mpio_result);
mpio_result = MPI_Type_commit(&filetype);
CHECK_SUCCESS(mpio_result);
-
+
if(rank == (rand() % numprocs))
{
for(i=0; i<write_size; i++)
- {
+ {
int j;
for(j=0; j<numprocs; j++)
writebuf[j] = i;
@@ -655,7 +655,7 @@ static int onewrite_allread_interlaced(int numprocs, int rank, int write_size)
}
MPI_Barrier(MPI_COMM_WORLD);
-
+
mpio_result = MPI_File_set_view(fh, rank*sizeof(int), MPI_INT, filetype, "native", MPI_INFO_NULL);
CHECK_SUCCESS(mpio_result);
@@ -664,7 +664,7 @@ static int onewrite_allread_interlaced(int numprocs, int rank, int write_size)
for(i=0; i<write_size; i++)
writebuf[i] = i;
-
+
vrfy_elements(writebuf, readbuf, write_size, rank);
mpio_result = MPI_File_close(&fh);
@@ -684,9 +684,9 @@ int main(int argc, char* argv[])
int write_size = 0;
char optstring[] = "h x m p: s: v:";
char *prefix;
-
+
err_flag = 0;
-
+
MPI_Init(&argc, &argv);
MPI_Comm_size(MPI_COMM_WORLD, &numprocs);
MPI_Comm_rank(MPI_COMM_WORLD, &rank);
@@ -728,7 +728,7 @@ int main(int argc, char* argv[])
break;
}
}
-
+
if( (optind < argc) && (rank == 0))
fprintf(stderr, "Unkown command-line argument passed. Continuing anyway...\n");
@@ -749,7 +749,7 @@ int main(int argc, char* argv[])
}
}
printf("Proc %d: testfile=%s\n", rank, testfile);
-
+
if(write_size == 0)
{
lb = 1024;
@@ -765,7 +765,7 @@ int main(int argc, char* argv[])
ub = write_size+1;
inc = 2;
}
-
+
#ifndef STANDALONE
/* set alarm. */
ALARM_ON;
@@ -775,7 +775,7 @@ int main(int argc, char* argv[])
{
if(rank == 0)
printf("\nTesting size %d\n", write_size);
-
+
if(mpi_tests)
{
if(rank == 0)
@@ -801,7 +801,7 @@ int main(int argc, char* argv[])
onewrite_allread_blocks(numprocs, rank, write_size/(numprocs*sizeof(int)));
PRINT_RESULT();
MPI_Barrier(MPI_COMM_WORLD);
-
+
if(rank == 0)
printf("Testing onewrite_allread_interlaced with MPI IO\t\t"); fflush(stdout);
onewrite_allread_interlaced(numprocs, rank, write_size/(numprocs*sizeof(int)));
@@ -828,7 +828,7 @@ int main(int argc, char* argv[])
posix_onewrite_allread_interlaced(numprocs, rank, write_size/(numprocs*sizeof(int)));
PRINT_RESULT();
MPI_Barrier(MPI_COMM_WORLD);
-
+
/* if(rank == 0)
printf("Testing allwrite_allread_overlap with POSIX IO\t\t"); fflush(stdout);
posix_allwrite_allread_overlap(numprocs, rank, write_size);
@@ -860,7 +860,7 @@ static int find_writesize(int rank, int numprocs, int size)
int tmp = (size-1)*numprocs;
int x = 0;
int write_size = 0;
-
+
/* Find largest multiple not greater than tmp */
while(x <= tmp)
{
@@ -871,7 +871,7 @@ static int find_writesize(int rank, int numprocs, int size)
write_size++;
}
-
+
return write_size;
}
diff --git a/testpar/t_span_tree.c b/testpar/t_span_tree.c
index 3ead9d8..8c60da3 100644
--- a/testpar/t_span_tree.c
+++ b/testpar/t_span_tree.c
@@ -45,7 +45,7 @@ static void coll_read_test(int chunk_factor);
/*-------------------------------------------------------------------------
* Function: coll_irregular_cont_write
*
- * Purpose: Wrapper to test the collectively irregular hyperslab write in
+ * Purpose: Wrapper to test the collectively irregular hyperslab write in
contiguous storage
*
* Return: Success: 0
@@ -72,7 +72,7 @@ coll_irregular_cont_write(void)
/*-------------------------------------------------------------------------
* Function: coll_irregular_cont_read
*
- * Purpose: Wrapper to test the collectively irregular hyperslab read in
+ * Purpose: Wrapper to test the collectively irregular hyperslab read in
contiguous storage
*
* Return: Success: 0
@@ -98,7 +98,7 @@ coll_irregular_cont_read(void)
/*-------------------------------------------------------------------------
* Function: coll_irregular_simple_chunk_write
*
- * Purpose: Wrapper to test the collectively irregular hyperslab write in
+ * Purpose: Wrapper to test the collectively irregular hyperslab write in
chunk storage(1 chunk)
*
* Return: Success: 0
@@ -206,7 +206,7 @@ coll_irregular_complex_chunk_read(void)
* Purpose: To test the collectively irregular hyperslab write in chunk
storage
* Input: number of chunks on each dimension
- if number is equal to 0, contiguous storage
+ if number is equal to 0, contiguous storage
* Return: Success: 0
*
* Failure: -1
@@ -282,7 +282,7 @@ void coll_write_test(int chunk_factor)
mdim[1] = MSPACE_DIM2*mpi_size;
fsdim[0] = FSPACE_DIM1;
fsdim[1] = FSPACE_DIM2*mpi_size;
-
+
vector = (int*)HDmalloc(sizeof(int)*mdim1[0]*mpi_size);
matrix_out = (int*)HDmalloc(sizeof(int)*mdim[0]*mdim[1]*mpi_size);
matrix_out1 = (int*)HDmalloc(sizeof(int)*mdim[0]*mdim[1]*mpi_size);
@@ -341,7 +341,7 @@ void coll_write_test(int chunk_factor)
/* The First selection for FILE
*
* block (3,2)
- * stride(4,3)
+ * stride(4,3)
* count (1,768/mpi_size)
* start (0,1+768*3*mpi_rank/mpi_size)
*
@@ -360,10 +360,10 @@ void coll_write_test(int chunk_factor)
VRFY((ret >= 0),"hyperslab selection succeeded");
/* The Second selection for FILE
- *
+ *
* block (3,768)
* stride (1,1)
- * count (1,1)
+ * count (1,1)
* start (4,768*mpi_rank/mpi_size)
*
*/
@@ -454,11 +454,11 @@ void coll_write_test(int chunk_factor)
* Open the file.
*/
- /***
-
- For testing collective hyperslab selection write
+ /***
+
+ For testing collective hyperslab selection write
In this test, we are using independent read to check
- the correctedness of collective write compared with
+ the correctedness of collective write compared with
independent write,
In order to throughly test this feature, we choose
@@ -496,7 +496,7 @@ void coll_write_test(int chunk_factor)
/* The First selection for FILE to read
*
* block (1,1)
- * stride(1.1)
+ * stride(1.1)
* count (3,768/mpi_size)
* start (1,2+768*mpi_rank/mpi_size)
*
@@ -522,7 +522,7 @@ void coll_write_test(int chunk_factor)
/* The Second selection for FILE to read
*
* block (1,1)
- * stride(1.1)
+ * stride(1.1)
* count (3,1536/mpi_size)
* start (2,4+1536*mpi_rank/mpi_size)
*
@@ -560,7 +560,7 @@ void coll_write_test(int chunk_factor)
* Only the starting point is different.
* The first selection
* block (1,1)
- * stride(1.1)
+ * stride(1.1)
* count (3,768/mpi_size)
* start (0,768*mpi_rank/mpi_size)
*
@@ -585,7 +585,7 @@ void coll_write_test(int chunk_factor)
* Only the starting point is different.
* The second selection
* block (1,1)
- * stride(1,1)
+ * stride(1,1)
* count (3,1536/mpi_size)
* start (1,2+1536*mpi_rank/mpi_size)
*
@@ -616,7 +616,7 @@ void coll_write_test(int chunk_factor)
H5P_DEFAULT, matrix_out);
VRFY((ret >= 0),"H5D independent read succeed");
-
+
ret = H5Dread(dataseti, H5T_NATIVE_INT, mspaceid, fspaceid,
H5P_DEFAULT, matrix_out1);
VRFY((ret >= 0),"H5D independent read succeed");
@@ -627,7 +627,7 @@ void coll_write_test(int chunk_factor)
if(matrix_out[i]!=matrix_out1[i]) ret = -1;
if(ret < 0) break;
}
-
+
VRFY((ret >= 0),"H5D irregular collective write succeed");
/*
@@ -670,7 +670,7 @@ void coll_write_test(int chunk_factor)
* Purpose: To test the collectively irregular hyperslab read in chunk
storage
* Input: number of chunks on each dimension
- if number is equal to 0, contiguous storage
+ if number is equal to 0, contiguous storage
* Return: Success: 0
*
* Failure: -1
@@ -679,8 +679,8 @@ void coll_write_test(int chunk_factor)
* Dec 2nd, 2004
*
* Modifications: Oct 18th, 2005
- * Note: This test must be used with the correpsonding
- coll_write_test.
+ * Note: This test must be used with the correpsonding
+ coll_write_test.
*-------------------------------------------------------------------------
*/
void coll_read_test(int chunk_factor)
@@ -700,7 +700,7 @@ void coll_read_test(int chunk_factor)
dataset on the disk */
#endif
- hsize_t mdim[2];
+ hsize_t mdim[2];
hsize_t start[2]; /* Start of hyperslab */
hsize_t stride[2]; /* Stride of hyperslab */
hsize_t count[2]; /* Block count */
@@ -733,7 +733,7 @@ void coll_read_test(int chunk_factor)
/* Initialize the buffer */
-
+
mdim[0] = MSPACE_DIM1;
mdim[1] = MSPACE_DIM2*mpi_size;
matrix_out =(int*)HDmalloc(sizeof(int)*MSPACE_DIM1*MSPACE_DIM2*mpi_size);
@@ -766,7 +766,7 @@ void coll_read_test(int chunk_factor)
/* The First selection for FILE to read
*
* block (1,1)
- * stride(1.1)
+ * stride(1.1)
* count (3,768/mpi_size)
* start (1,2+768*mpi_rank/mpi_size)
*
@@ -786,7 +786,7 @@ void coll_read_test(int chunk_factor)
/* The Second selection for FILE to read
*
* block (1,1)
- * stride(1.1)
+ * stride(1.1)
* count (3,1536/mpi_size)
* start (2,4+1536*mpi_rank/mpi_size)
*
@@ -815,7 +815,7 @@ void coll_read_test(int chunk_factor)
* Only the starting point is different.
* The first selection
* block (1,1)
- * stride(1.1)
+ * stride(1.1)
* count (3,768/mpi_size)
* start (0,768*mpi_rank/mpi_size)
*
@@ -838,7 +838,7 @@ void coll_read_test(int chunk_factor)
* Only the starting point is different.
* The second selection
* block (1,1)
- * stride(1,1)
+ * stride(1,1)
* count (3,1536/mpi_size)
* start (1,2+1536*mpi_rank/mpi_size)
*
diff --git a/testpar/testphdf5.c b/testpar/testphdf5.c
index 9b56b24..8aa3d0d 100644
--- a/testpar/testphdf5.c
+++ b/testpar/testphdf5.c
@@ -412,10 +412,10 @@ int main(int argc, char **argv)
"independent group and dataset read", &collngroups_params);
/* By default, do not run big dataset on WIN32. */
#ifdef WIN32
- AddTest("-bigdset", big_dataset, NULL,
+ AddTest("-bigdset", big_dataset, NULL,
"big dataset test", PARATESTFILE);
#else
- AddTest("bigdset", big_dataset, NULL,
+ AddTest("bigdset", big_dataset, NULL,
"big dataset test", PARATESTFILE);
#endif
AddTest("fill", dataset_fillvalue, NULL,
@@ -453,8 +453,8 @@ int main(int argc, char **argv)
AddTest((mpi_size < 3)? "-cchunk10" : "cchunk10",
coll_chunk10,NULL,
"multiple chunk collective IO transferring to independent IO",PARATESTFILE);
-
-
+
+
/* irregular collective IO tests*/
AddTest("ccontw",
diff --git a/tools/h5diff/Makefile.am b/tools/h5diff/Makefile.am
index da2e851..382444c 100644
--- a/tools/h5diff/Makefile.am
+++ b/tools/h5diff/Makefile.am
@@ -47,7 +47,7 @@ ph5diff_SOURCES=ph5diff_main.c h5diff_common.c
h5diffgentest_SOURCES=h5diffgentest.c
# Programs depend on the main HDF5 library and tools library
-LDADD=$(LIBH5TOOLS) $(LIBHDF5)
+LDADD=$(LIBH5TOOLS) $(LIBHDF5)
# Temporary files. *.h5 are generated by h5diff. They should
# be copied to the testfiles/ directory if update is required
diff --git a/tools/h5diff/h5diff_common.c b/tools/h5diff/h5diff_common.c
index 6a24ab6..9ac4d56 100644
--- a/tools/h5diff/h5diff_common.c
+++ b/tools/h5diff/h5diff_common.c
@@ -25,29 +25,29 @@
*-------------------------------------------------------------------------
*/
-void parse_input(int argc, const char* argv[], const char** fname1, const char** fname2,
+void parse_input(int argc, const char* argv[], const char** fname1, const char** fname2,
const char** objname1, const char** objname2, diff_opt_t* options)
{
int i;
const char *s = NULL;
-
+
/* process the command-line */
memset(options, 0, sizeof (diff_opt_t));
-
+
/*-------------------------------------------------------------------------
* initial check of command line options
*-------------------------------------------------------------------------
*/
-
+
if ( argc==2 && (strcmp("-h",argv[1])==0) )
usage();
-
+
if ( argc<3 )
{
printf("Number of arguments is only %d\n", argc );
usage();
}
-
+
/*-------------------------------------------------------------------------
* file names are first
*-------------------------------------------------------------------------
@@ -144,9 +144,9 @@ void parse_input(int argc, const char* argv[], const char** fname1, const char**
} /*switch*/
} /*for*/
} /*if*/
-
+
else /* not single-letter switches */
-
+
{
/* check if it is not a -d, -p parameter */
if ( '-'==argv[i-1][0] && ('d'==argv[i-1][1] ||'p'==argv[i-1][1] ))
@@ -169,7 +169,7 @@ void parse_input(int argc, const char* argv[], const char** fname1, const char**
} /*objname2*/
} /*else*/
} /*else*/
-
+
}/*for*/
}
@@ -185,14 +185,14 @@ void print_results(diff_opt_t* options)
{
if (options->m_quiet || options->err_stat)
return;
-
+
if (options->cmn_objs==0)
{
printf("No common objects found. Files are not comparable.\n");
if (!options->m_verbose)
printf("Use -v for a list of objects.\n");
}
-
+
if (options->not_cmp==1)
{
printf("--------------------------------\n");
@@ -201,7 +201,7 @@ void print_results(diff_opt_t* options)
if (!options->m_verbose)
printf("Use -v for a list of objects.\n");
}
-
+
}
/*-------------------------------------------------------------------------
@@ -225,7 +225,7 @@ int check_n_input( const char *str )
{
unsigned i;
char c;
-
+
for ( i = 0; i < strlen(str); i++)
{
c = str[i];
@@ -259,18 +259,18 @@ int check_n_input( const char *str )
int check_f_input( const char *str )
{
double x;
-
+
/*
the atof return value on a hexadecimal input is different
on some systems; we do a character check for this
*/
if (strlen(str)>2 && str[0]=='0' && str[1]=='x')
return -1;
-
+
x=atof(str);
if (x==0)
return -1;
-
+
return 1;
}
diff --git a/tools/h5diff/h5diff_main.c b/tools/h5diff/h5diff_main.c
index 836a335..454a033 100644
--- a/tools/h5diff/h5diff_main.c
+++ b/tools/h5diff/h5diff_main.c
@@ -58,19 +58,19 @@ int main(int argc, const char *argv[])
const char *objname2 = NULL;
hsize_t nfound=0;
diff_opt_t options;
-
+
parse_input(argc, argv, &fname1, &fname2, &objname1, &objname2, &options);
-
+
nfound = h5diff(fname1,fname2,objname1,objname2,&options);
-
+
print_results(&options);
-
+
/*-------------------------------------------------------------------------
* exit code
* >0 if differences, 0 if no differences, <0 if error
*-------------------------------------------------------------------------
*/
-
+
ret= (nfound==0 ? 0 : 1 );
if (options.err_stat)
ret=-1;
diff --git a/tools/h5diff/h5diffgentest.c b/tools/h5diff/h5diffgentest.c
index 029e694..11459a4 100644
--- a/tools/h5diff/h5diffgentest.c
+++ b/tools/h5diff/h5diffgentest.c
@@ -339,7 +339,7 @@ int write_dset( hid_t loc_id,
*-------------------------------------------------------------------------
*/
-static
+static
void gen_datareg(hid_t fid,
int make_diffs /* flag to modify data buffers */)
{
@@ -367,14 +367,14 @@ void gen_datareg(hid_t fid,
for (i=0; i<10*10; i++)
{
- buf[i]=i;
+ buf[i]=i;
}
/* create the data dataset */
sid1 = H5Screate_simple(2,dims1,NULL);
did1 = H5Dcreate(fid,"dsetref",H5T_NATIVE_INT,sid1,H5P_DEFAULT);
status = H5Dwrite(did1,H5T_NATIVE_INT,H5S_ALL,H5S_ALL,H5P_DEFAULT,buf);
-
+
/* create the reference dataset */
sid2 = H5Screate_simple(1,dims2,NULL);
did2 = H5Dcreate(fid,"refreg",H5T_STD_REF_DSETREG,sid2,H5P_DEFAULT);
@@ -410,13 +410,13 @@ void gen_datareg(hid_t fid,
}
H5Sselect_elements(sid1,H5S_SELECT_SET,5,(const hsize_t **)coord);
H5Sget_select_npoints(sid1);
-
+
/* store second dataset region */
H5Rcreate(&rbuf[1],fid,"dsetref",H5R_DATASET_REGION,sid1);
/* write */
status = H5Dwrite(did2,H5T_STD_REF_DSETREG,H5S_ALL,H5S_ALL,H5P_DEFAULT,rbuf);
-
+
/* close, free memory buffers */
status = H5Dclose(did1);
status = H5Sclose(sid1);
@@ -434,7 +434,7 @@ void gen_datareg(hid_t fid,
*
*-------------------------------------------------------------------------
*/
-static
+static
void write_dset_in(hid_t loc_id,
const char* dset_name, /* for saving reference to dataset*/
hid_t fid,
@@ -1025,7 +1025,7 @@ void write_dset_in(hid_t loc_id,
*
*-------------------------------------------------------------------------
*/
-static
+static
void write_attr_in(hid_t loc_id,
const char* dset_name, /* for saving reference to dataset*/
hid_t fid,
@@ -2092,7 +2092,7 @@ int test_dsetall(const char *file,
*-------------------------------------------------------------------------
*/
static
-int test_basic(const char *file1,
+int test_basic(const char *file1,
const char *file2)
{
@@ -2152,13 +2152,13 @@ int test_basic(const char *file1,
/*-------------------------------------------------------------------------
* Function: test_basic
*
- * Purpose: Compare different HDF5 types (H5G_obj_t):
+ * Purpose: Compare different HDF5 types (H5G_obj_t):
* H5G_DATASET, H5G_TYPE, H5G_GROUP, H5G_LINK
*
*-------------------------------------------------------------------------
*/
static
-int test_types(const char *file1,
+int test_types(const char *file1,
const char UNUSED *file2)
{
@@ -2241,7 +2241,7 @@ int test_types(const char *file1,
*-------------------------------------------------------------------------
*/
static
-int test_native(const char *file1,
+int test_native(const char *file1,
const char UNUSED *file2)
{
diff --git a/tools/h5dump/h5dump.c b/tools/h5dump/h5dump.c
index c2bc761..7bf0ba3 100644
--- a/tools/h5dump/h5dump.c
+++ b/tools/h5dump/h5dump.c
@@ -756,9 +756,9 @@ print_datatype(hid_t type,unsigned in_group)
} else if (H5Tequal(type, H5T_NATIVE_ULLONG)==TRUE) {
printf("H5T_NATIVE_ULLONG");
} else {
-
+
/* byte order */
- if (H5Tget_size(type)>1)
+ if (H5Tget_size(type)>1)
{
order = H5Tget_order(type);
if (H5T_ORDER_LE==order) {
@@ -773,9 +773,9 @@ print_datatype(hid_t type,unsigned in_group)
} else {
order_s = "";
}
-
+
/* sign */
- if ((sign=H5Tget_sign(type))>=0)
+ if ((sign=H5Tget_sign(type))>=0)
{
if (H5T_SGN_NONE==sign) {
sign_s = " unsigned";
@@ -787,7 +787,7 @@ print_datatype(hid_t type,unsigned in_group)
} else {
sign_s = " unknown-sign";
}
-
+
/* print size, order, and sign */
printf("%lu-bit%s%s integer",
(unsigned long)(8*H5Tget_size(type)), order_s, sign_s);
@@ -816,9 +816,9 @@ print_datatype(hid_t type,unsigned in_group)
printf("H5T_NATIVE_LDOUBLE");
#endif
} else {
-
+
/* byte order */
- if (H5Tget_size(type)>1)
+ if (H5Tget_size(type)>1)
{
order = H5Tget_order(type);
if (H5T_ORDER_LE==order) {
@@ -833,7 +833,7 @@ print_datatype(hid_t type,unsigned in_group)
} else {
order_s = "";
}
-
+
/* print size and byte order */
printf("%lu-bit%s floating-point",
(unsigned long)(8*H5Tget_size(type)), order_s);
@@ -1678,7 +1678,7 @@ dump_named_datatype(hid_t type, const char *name)
indentation(indent);
printf("%s \"%s\" %s", dump_header_format->datatypebegin, name,
dump_header_format->datatypeblockbegin);
-
+
if (H5Tget_class(type) == H5T_COMPOUND) {
print_datatype(type,1);
} else {
@@ -1686,7 +1686,7 @@ dump_named_datatype(hid_t type, const char *name)
print_datatype(type,1);
printf(";\n");
}
-
+
/* print attributes */
indent += COL;
H5Aiterate(type, NULL, dump_attr, NULL);
diff --git a/tools/h5dump/h5dumpgentest.c b/tools/h5dump/h5dumpgentest.c
index e7bf7a7..89652f2 100644
--- a/tools/h5dump/h5dumpgentest.c
+++ b/tools/h5dump/h5dumpgentest.c
@@ -5427,20 +5427,20 @@ static void gent_longlinks(void)
*/
static int gent_ldouble(void)
{
- hid_t fid;
+ hid_t fid;
hid_t did;
hid_t tid;
hid_t sid;
size_t size;
- hsize_t dims[1] = {3};
+ hsize_t dims[1] = {3};
long double buf[3] = {1,2,3};
-
+
if ((fid = H5Fcreate(FILE52, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT))<0)
goto error;
-
+
if ((sid = H5Screate_simple(1, dims, NULL))<0)
goto error;
-
+
if ((tid = H5Tcopy(H5T_NATIVE_LDOUBLE))<0)
goto error;
@@ -5452,7 +5452,7 @@ static int gent_ldouble(void)
if (H5Dwrite(did,tid,H5S_ALL,H5S_ALL,H5P_DEFAULT,buf)<0)
goto error;
-
+
if (H5Sclose(sid)<0)
goto error;
if (H5Tclose(tid)<0)
@@ -5461,7 +5461,7 @@ static int gent_ldouble(void)
goto error;
if (H5Fclose(fid)<0)
goto error;
-
+
return 0;
error:
diff --git a/tools/h5ls/h5ls.c b/tools/h5ls/h5ls.c
index a6a7e95..d279ea3 100644
--- a/tools/h5ls/h5ls.c
+++ b/tools/h5ls/h5ls.c
@@ -2264,10 +2264,10 @@ main (int argc, const char *argv[])
/* list root attributes */
if (verbose_g>0)
{
- if ((root=H5Gopen(file, "/"))<0)
- leave(1);
+ if ((root=H5Gopen(file, "/"))<0)
+ leave(1);
H5Aiterate(root, NULL, list_attr, NULL);
- if (H5Gclose(root)<0)
+ if (H5Gclose(root)<0)
leave(1);
}
/* list */
diff --git a/tools/h5repack/h5repack.c b/tools/h5repack/h5repack.c
index f8f7f53..4b0bb7e 100644
--- a/tools/h5repack/h5repack.c
+++ b/tools/h5repack/h5repack.c
@@ -65,7 +65,7 @@ static void aux_initglb_filter(pack_opt_t *options)
int h5repack(const char* infile,
const char* outfile,
pack_opt_t *options,
- int argc,
+ int argc,
const char *argv[])
{
/* check input */
diff --git a/tools/h5repack/h5repack.h b/tools/h5repack/h5repack.h
index e835b66..e859347 100644
--- a/tools/h5repack/h5repack.h
+++ b/tools/h5repack/h5repack.h
@@ -47,8 +47,8 @@ typedef struct {
H5Z_FILTER_SHUFFLE 2 , shuffle the data
H5Z_FILTER_FLETCHER32 3 , letcher32 checksum of EDC
H5Z_FILTER_SZIP 4 , szip compression
- H5Z_FILTER_NBIT 5 , nbit compression
- H5Z_FILTER_SCALEOFFSET 6 , scaleoffset compression
+ H5Z_FILTER_NBIT 5 , nbit compression
+ H5Z_FILTER_SCALEOFFSET 6 , scaleoffset compression
*/
#define CDVALUES 2
@@ -139,13 +139,13 @@ int h5repack_cmpdcpl (const char *fname1,
int check_objects(const char* fname,
pack_opt_t *options,
- int argc,
+ int argc,
const char *argv[]);
int copy_objects(const char* fnamein,
const char* fnameout,
pack_opt_t *options,
- int argc,
+ int argc,
const char *argv[]);
void print_objlist(const char *filename,
diff --git a/tools/h5repack/h5repack_copy.c b/tools/h5repack/h5repack_copy.c
index 7b11b93..dee6c3f 100644
--- a/tools/h5repack/h5repack_copy.c
+++ b/tools/h5repack/h5repack_copy.c
@@ -36,7 +36,7 @@
*
*-------------------------------------------------------------------------
*/
-static void print_dataset_info(hid_t dcpl_id,
+static void print_dataset_info(hid_t dcpl_id,
char *objname,
float per)
{
@@ -143,7 +143,7 @@ static void print_dataset_info(hid_t dcpl_id,
strcat(str,temp);
printf(FORMAT_OBJ,str,objname);
}
-
+
}
@@ -166,7 +166,7 @@ static void print_dataset_info(hid_t dcpl_id,
int copy_objects(const char* fnamein,
const char* fnameout,
pack_opt_t *options,
- int argc,
+ int argc,
const char *argv[])
{
hid_t fidin;
@@ -374,7 +374,7 @@ int do_copy_objects(hid_t fidin,
if ((next=H5Pget_external_count (dcpl_id))<0)
goto error;
- if (next)
+ if (next)
fprintf(stderr," <warning: %s has external files, ignoring read...>\n",
travt->objs[i].name );
@@ -402,7 +402,7 @@ int do_copy_objects(hid_t fidin,
dsize_in=H5Dget_storage_size(dset_in);
/*-------------------------------------------------------------------------
- * read
+ * read
*-------------------------------------------------------------------------
*/
if (nelmts)
@@ -416,13 +416,13 @@ int do_copy_objects(hid_t fidin,
goto error;
/*-------------------------------------------------------------------------
- * check for datasets too small
+ * check for datasets too small
*-------------------------------------------------------------------------
*/
-
+
if (nelmts*msize < options->threshold )
apply_s=0;
-
+
/*-------------------------------------------------------------------------
* apply the filter
*-------------------------------------------------------------------------
@@ -445,7 +445,7 @@ int do_copy_objects(hid_t fidin,
dset_out=H5Dcreate(fidout,travt->objs[i].name,mtype_id,space_id,dcpl_out);
} H5E_END_TRY;
-
+
if (dset_out==FAIL)
{
if ((dset_out=H5Dcreate(fidout,travt->objs[i].name,mtype_id,space_id,dcpl_id))<0)
@@ -479,14 +479,14 @@ int do_copy_objects(hid_t fidin,
else
print_dataset_info(dcpl_id,travt->objs[i].name,0);
}
-
+
if (apply_s==0 && options->verbose)
printf(" <warning: filter not applied to %s. dataset smaller than %d bytes>\n",
travt->objs[i].name,
(int)options->threshold);
if (apply_f==0 && options->verbose)
- printf(" <warning: could not apply the filter to %s>\n",
+ printf(" <warning: could not apply the filter to %s>\n",
travt->objs[i].name);
/*-------------------------------------------------------------------------
diff --git a/tools/h5repack/h5repack_filters.c b/tools/h5repack/h5repack_filters.c
index 9f3b192..75ca771 100644
--- a/tools/h5repack/h5repack_filters.c
+++ b/tools/h5repack/h5repack_filters.c
@@ -201,7 +201,7 @@ int apply_filters(const char* name, /* object name from traverse list */
if (rank==0) /* scalar dataset, do not apply */
return 0;
-
+
/*-------------------------------------------------------------------------
* initialize the assigment object
@@ -219,7 +219,7 @@ int apply_filters(const char* name, /* object name from traverse list */
/* get information about input filters */
if ((nfilters = H5Pget_nfilters(dcpl_id))<0)
return -1;
-
+
/*-------------------------------------------------------------------------
* check if we have filters in the pipeline
* we want to replace them with the input filters
@@ -294,7 +294,7 @@ int apply_filters(const char* name, /* object name from traverse list */
case H5Z_FILTER_DEFLATE:
{
unsigned aggression; /* the deflate level */
-
+
aggression = obj.filter[i].cd_values[0];
/* set up for deflated data */
if(H5Pset_chunk(dcpl_id, obj.chunk.rank, obj.chunk.chunk_lengths)<0)
@@ -313,9 +313,9 @@ int apply_filters(const char* name, /* object name from traverse list */
unsigned options_mask;
unsigned pixels_per_block;
- options_mask = obj.filter[i].cd_values[0];
+ options_mask = obj.filter[i].cd_values[0];
pixels_per_block = obj.filter[i].cd_values[1];
-
+
/* set up for szip data */
if(H5Pset_chunk(dcpl_id,obj.chunk.rank,obj.chunk.chunk_lengths)<0)
return -1;
@@ -363,12 +363,12 @@ int apply_filters(const char* name, /* object name from traverse list */
case H5Z_FILTER_SCALEOFFSET:
{
- H5Z_SO_scale_type_t scale_type;
- int scale_factor;
-
+ H5Z_SO_scale_type_t scale_type;
+ int scale_factor;
+
scale_type = obj.filter[i].cd_values[0];
scale_factor = obj.filter[i].cd_values[1];
-
+
if(H5Pset_chunk(dcpl_id, obj.chunk.rank, obj.chunk.chunk_lengths)<0)
return -1;
if (H5Pset_scaleoffset(dcpl_id,scale_type,scale_factor)<0)
diff --git a/tools/h5repack/h5repack_list.c b/tools/h5repack/h5repack_list.c
index f2eb2c9..05156d4 100644
--- a/tools/h5repack/h5repack_list.c
+++ b/tools/h5repack/h5repack_list.c
@@ -36,7 +36,7 @@
*/
int check_objects(const char* fname,
pack_opt_t *options,
- int argc,
+ int argc,
const char *argv[])
{
hid_t fid;
diff --git a/tools/h5repack/h5repack_parse.c b/tools/h5repack/h5repack_parse.c
index 9760fa2..9243b72 100644
--- a/tools/h5repack/h5repack_parse.c
+++ b/tools/h5repack/h5repack_parse.c
@@ -189,12 +189,12 @@ obj_list_t* parse_filter(const char *str,
/*-------------------------------------------------------------------------
* H5Z_FILTER_SCALEOFFSET
* scaleoffset has the format SOFF=<scale_factor,scale_type>
- * scale_type can be
+ * scale_type can be
* integer datatype, H5Z_SO_INT (IN)
* float datatype using D-scaling method, H5Z_SO_FLOAT_DSCALE (DS)
* float datatype using E-scaling method, H5Z_SO_FLOAT_ESCALE (ES) , not yet implemented
* for integer datatypes, scale_factor denotes Minimum Bits
- * for float datatypes, scale_factor denotes decimal scale factor
+ * for float datatypes, scale_factor denotes decimal scale factor
* examples
* SOFF=31,IN
* SOFF=3,DF
diff --git a/tools/lib/h5diff.c b/tools/lib/h5diff.c
index b4c9022..e8c546e 100644
--- a/tools/lib/h5diff.c
+++ b/tools/lib/h5diff.c
@@ -91,19 +91,19 @@ void print_manager_output(void)
if( (outBuffOffset>0) && g_Parallel)
{
printf("%s", outBuff);
-
+
if(overflow_file)
{
int tmp;
-
+
rewind(overflow_file);
while((tmp = getc(overflow_file)) >= 0)
putchar(tmp);
-
+
fclose(overflow_file);
overflow_file = NULL;
}
-
+
fflush(stdout);
memset(outBuff, 0, OUTBUFF_SIZE);
outBuffOffset = 0;
@@ -134,7 +134,7 @@ static void print_incoming_data(void)
char data[PRINT_DATA_MAX_SIZE+1];
int incomingMessage;
MPI_Status Status;
-
+
do
{
MPI_Iprobe(MPI_ANY_SOURCE, MPI_TAG_PRINT_DATA, MPI_COMM_WORLD, &incomingMessage, &Status);
@@ -142,7 +142,7 @@ static void print_incoming_data(void)
{
memset(data, 0, PRINT_DATA_MAX_SIZE+1);
MPI_Recv(data, PRINT_DATA_MAX_SIZE, MPI_CHAR, Status.MPI_SOURCE, MPI_TAG_PRINT_DATA, MPI_COMM_WORLD, &Status);
-
+
printf("%s", data);
}
} while(incomingMessage);
@@ -176,9 +176,9 @@ hsize_t h5diff(const char *fname1,
hid_t file1_id=(-1), file2_id=(-1);
char filenames[2][1024];
hsize_t nfound = 0;
-
+
memset(filenames, 0, 1024*2);
-
+
if (options->m_quiet &&
(options->m_verbose || options->m_report))
{
@@ -186,12 +186,12 @@ hsize_t h5diff(const char *fname1,
options->err_stat=1;
return 0;
}
-
+
/*-------------------------------------------------------------------------
* open the files first; if they are not valid, no point in continuing
*-------------------------------------------------------------------------
*/
-
+
/* disable error reporting */
H5E_BEGIN_TRY
{
@@ -200,7 +200,7 @@ hsize_t h5diff(const char *fname1,
{
printf ("h5diff: <%s>: unable to open file\n", fname1);
options->err_stat = 1;
-
+
#ifdef H5_HAVE_PARALLEL
if(g_Parallel)
{
@@ -208,14 +208,14 @@ hsize_t h5diff(const char *fname1,
phdiff_dismiss_workers();
}
#endif
-
+
goto out;
}
if ((file2_id = H5Fopen (fname2, H5F_ACC_RDONLY, H5P_DEFAULT)) < 0)
{
printf ("h5diff: <%s>: unable to open file\n", fname2);
options->err_stat = 1;
-
+
#ifdef H5_HAVE_PARALLEL
if(g_Parallel)
{
@@ -223,20 +223,20 @@ hsize_t h5diff(const char *fname1,
phdiff_dismiss_workers();
}
#endif
-
+
goto out;
}
/* enable error reporting */
}
H5E_END_TRY;
-
+
/*-------------------------------------------------------------------------
* get the number of objects in the files
*-------------------------------------------------------------------------
*/
nobjects1 = h5trav_getinfo (file1_id, NULL, 0);
nobjects2 = h5trav_getinfo (file2_id, NULL, 0);
-
+
if (nobjects1 < 0 || nobjects2 < 0)
{
printf ("Error: Could not get get file contents\n");
@@ -250,12 +250,12 @@ hsize_t h5diff(const char *fname1,
#endif
goto out;
}
-
+
/*-------------------------------------------------------------------------
* get the list of objects in the files
*-------------------------------------------------------------------------
*/
-
+
info1 = (trav_info_t *) malloc (nobjects1 * sizeof (trav_info_t));
info2 = (trav_info_t *) malloc (nobjects2 * sizeof (trav_info_t));
if (info1 == NULL || info2 == NULL)
@@ -273,18 +273,18 @@ hsize_t h5diff(const char *fname1,
#endif
goto out;
}
-
+
h5trav_getinfo (file1_id, info1, 0);
h5trav_getinfo (file2_id, info2, 0);
-
+
/*-------------------------------------------------------------------------
* object name was supplied
*-------------------------------------------------------------------------
*/
-
+
if (objname1)
{
-
+
#ifdef H5_HAVE_PARALLEL
if(g_Parallel)
{
@@ -298,31 +298,31 @@ hsize_t h5diff(const char *fname1,
file2_id, fname2, objname2, nobjects2, info2,
options);
}
-
+
/*-------------------------------------------------------------------------
* compare all
*-------------------------------------------------------------------------
*/
-
+
else
{
-
+
#ifdef H5_HAVE_PARALLEL
if(g_Parallel)
{
int i;
-
+
if( (strlen(fname1) > 1024) || (strlen(fname2) > 1024))
{
fprintf(stderr, "The parallel diff only supports path names up to 1024 characters\n");
MPI_Abort(MPI_COMM_WORLD, 0);
}
-
+
strcpy(filenames[0], fname1);
strcpy(filenames[1], fname2);
-
+
/* Alert the worker tasks that there's going to be work. */
-
+
for(i=1; i<g_nTasks; i++)
MPI_Send(filenames, 1024*2, MPI_CHAR, i, MPI_TAG_PARALLEL, MPI_COMM_WORLD);
}
@@ -330,10 +330,10 @@ hsize_t h5diff(const char *fname1,
nfound = diff_match (file1_id, nobjects1, info1,
file2_id, nobjects2, info2, options);
}
-
+
h5trav_freeinfo (info1, nobjects1);
h5trav_freeinfo (info2, nobjects2);
-
+
out:
/* close */
H5E_BEGIN_TRY
@@ -342,7 +342,7 @@ out:
H5Fclose (file2_id);
}
H5E_END_TRY;
-
+
return nfound;
}
@@ -366,12 +366,12 @@ out:
*
*-------------------------------------------------------------------------
*/
-hsize_t diff_match (hid_t file1_id,
+hsize_t diff_match (hid_t file1_id,
int nobjects1,
trav_info_t * info1,
hid_t file2_id,
- int nobjects2,
- trav_info_t * info2,
+ int nobjects2,
+ trav_info_t * info2,
diff_opt_t * options)
{
int more_names_exist = (nobjects1 > 0 && nobjects2 > 0) ? 1 : 0;
@@ -383,13 +383,13 @@ hsize_t diff_match (hid_t file1_id,
char c1, c2;
hsize_t nfound = 0;
int i;
-
+
/*-------------------------------------------------------------------------
* build the list
*-------------------------------------------------------------------------
*/
trav_table_init (&table);
-
+
while (more_names_exist)
{
/* criteria is string compare */
@@ -400,7 +400,7 @@ hsize_t diff_match (hid_t file1_id,
infile[1] = 1;
trav_table_addflags (infile, info1[curr1].name, info1[curr1].type,
table);
-
+
curr1++;
curr2++;
}
@@ -420,12 +420,12 @@ hsize_t diff_match (hid_t file1_id,
table);
curr2++;
}
-
+
more_names_exist = (curr1 < nobjects1 && curr2 < nobjects2) ? 1 : 0;
-
-
+
+
} /* end while */
-
+
/* list1 did not end */
if (curr1 < nobjects1)
{
@@ -438,7 +438,7 @@ hsize_t diff_match (hid_t file1_id,
curr1++;
}
}
-
+
/* list2 did not end */
if (curr2 < nobjects2)
{
@@ -451,12 +451,12 @@ hsize_t diff_match (hid_t file1_id,
curr2++;
}
}
-
+
/*-------------------------------------------------------------------------
* print the list
*-------------------------------------------------------------------------
*/
-
+
if (options->m_verbose)
{
printf ("\n");
@@ -470,8 +470,8 @@ hsize_t diff_match (hid_t file1_id,
}
printf ("\n");
}
-
-
+
+
/*-------------------------------------------------------------------------
* do the diff for common objects
*-------------------------------------------------------------------------
@@ -485,11 +485,11 @@ hsize_t diff_match (hid_t file1_id,
struct diff_args args;
int havePrintToken = 1;
MPI_Status Status;
-
+
/*set all tasks as free */
memset(workerTasks, 1, g_nTasks-1);
#endif
-
+
for (i = 0; i < table->nobjs; i++)
{
if (table->objs[i].flags[0] && table->objs[i].flags[1])
@@ -516,18 +516,18 @@ hsize_t diff_match (hid_t file1_id,
* an array of bytes in order to be portable. But this
* may not work in non-homogeneous MPI environments.
*/
-
+
/*Set up args to pass to worker task. */
if(strlen(table->objs[i].name) > 255)
{
printf("The parallel diff only supports object names up to 255 characters\n");
MPI_Abort(MPI_COMM_WORLD, 0);
}
-
+
strcpy(args.name, table->objs[i].name);
args.options = *options;
args.type= table->objs[i].type;
-
+
h5diffdebug2("busyTasks=%d\n", busyTasks);
/* if there are any outstanding print requests, let's handle one. */
if(busyTasks > 0)
@@ -535,7 +535,7 @@ hsize_t diff_match (hid_t file1_id,
int incomingMessage;
/* check if any tasks freed up, and didn't need to print. */
MPI_Iprobe(MPI_ANY_SOURCE, MPI_TAG_DONE, MPI_COMM_WORLD, &incomingMessage, &Status);
-
+
/* first block*/
if(incomingMessage)
{
@@ -545,16 +545,16 @@ hsize_t diff_match (hid_t file1_id,
options->not_cmp = options->not_cmp | nFoundbyWorker.not_cmp;
busyTasks--;
}
-
+
/* check to see if the print token was returned. */
if(!havePrintToken)
{
/* If we don't have the token, someone is probably sending us output */
print_incoming_data();
-
+
/* check incoming queue for token */
MPI_Iprobe(MPI_ANY_SOURCE, MPI_TAG_TOK_RETURN, MPI_COMM_WORLD, &incomingMessage, &Status);
-
+
/* incoming token implies free task. */
if(incomingMessage)
{
@@ -566,7 +566,7 @@ hsize_t diff_match (hid_t file1_id,
havePrintToken = 1;
}
}
-
+
/* check to see if anyone needs the print token. */
if(havePrintToken)
{
@@ -580,35 +580,35 @@ hsize_t diff_match (hid_t file1_id,
}
}
}
-
+
/* check array of tasks to see which ones are free.
* Manager task never does work, so freeTasks[0] is really
* worker task 0. */
-
+
for(n=1; (n<g_nTasks) && !workerFound; n++)
{
if(workerTasks[n-1])
{
/* send file id's and names to first free worker */
MPI_Send(&args, sizeof(struct diff_args), MPI_BYTE, n, MPI_TAG_ARGS, MPI_COMM_WORLD);
-
+
/* increment counter for total number of prints. */
busyTasks++;
-
+
/* mark worker as busy */
workerTasks[n-1] = 0;
workerFound = 1;
}
-
+
}
-
-
+
+
h5diffdebug2("workerfound is %d \n", workerFound);
if(!workerFound)
{
/* if they were all busy, we've got to wait for one free up before we can move on.
* if we don't have the token, some task is currently printing so we'll wait for that task to return it. */
-
+
if(!havePrintToken)
{
while(!havePrintToken) {
@@ -630,7 +630,7 @@ hsize_t diff_match (hid_t file1_id,
else
{
/* But first print all the data in our incoming queue */
- print_incoming_data();
+ print_incoming_data();
MPI_Probe(MPI_ANY_SOURCE, MPI_ANY_TAG, MPI_COMM_WORLD, &Status);
if(Status.MPI_TAG == MPI_TAG_DONE)
{
@@ -644,16 +644,16 @@ hsize_t diff_match (hid_t file1_id,
int incomingMessage;
MPI_Recv(NULL, 0, MPI_BYTE, Status.MPI_SOURCE, MPI_TAG_TOK_REQUEST, MPI_COMM_WORLD, &Status);
MPI_Send(NULL, 0, MPI_BYTE, Status.MPI_SOURCE, MPI_TAG_PRINT_TOK, MPI_COMM_WORLD);
-
+
do
{
MPI_Iprobe(MPI_ANY_SOURCE, MPI_TAG_TOK_RETURN, MPI_COMM_WORLD, &incomingMessage, &Status);
-
+
print_incoming_data();
}
while(!incomingMessage);
-
-
+
+
MPI_Recv(&nFoundbyWorker, sizeof(nFoundbyWorker), MPI_BYTE, Status.MPI_SOURCE, MPI_TAG_TOK_RETURN, MPI_COMM_WORLD, &Status);
nfound += nFoundbyWorker.nfound;
options->not_cmp = options->not_cmp | nFoundbyWorker.not_cmp;
@@ -672,7 +672,7 @@ hsize_t diff_match (hid_t file1_id,
}
}
h5diffdebug("done with for loop\n");
-
+
#ifdef H5_HAVE_PARALLEL
if(g_Parallel)
{
@@ -704,7 +704,7 @@ hsize_t diff_match (hid_t file1_id,
do
{
MPI_Iprobe(MPI_ANY_SOURCE, MPI_TAG_TOK_RETURN, MPI_COMM_WORLD, &incomingMessage, &Status);
-
+
print_incoming_data();
}
while(!incomingMessage);
@@ -720,12 +720,12 @@ hsize_t diff_match (hid_t file1_id,
do
{
MPI_Iprobe(MPI_ANY_SOURCE, MPI_TAG_TOK_RETURN, MPI_COMM_WORLD, &incomingMessage, &Status);
-
+
print_incoming_data();
}
while(!incomingMessage);
-
-
+
+
MPI_Recv(&nFoundbyWorker, sizeof(nFoundbyWorker), MPI_BYTE, MPI_ANY_SOURCE, MPI_TAG_TOK_RETURN, MPI_COMM_WORLD, &Status);
nfound += nFoundbyWorker.nfound;
options->not_cmp = options->not_cmp | nFoundbyWorker.not_cmp;
@@ -745,9 +745,9 @@ hsize_t diff_match (hid_t file1_id,
{
char data[PRINT_DATA_MAX_SIZE+1];
memset(data, 0, PRINT_DATA_MAX_SIZE+1);
-
+
MPI_Recv(data, PRINT_DATA_MAX_SIZE, MPI_CHAR, Status.MPI_SOURCE, MPI_TAG_PRINT_DATA, MPI_COMM_WORLD, &Status);
-
+
printf("%s", data);
}
else
@@ -756,34 +756,34 @@ hsize_t diff_match (hid_t file1_id,
MPI_Abort(MPI_COMM_WORLD, 0);
}
}
-
+
for(i=1; i<g_nTasks; i++)
MPI_Send(NULL, 0, MPI_BYTE, i, MPI_TAG_END, MPI_COMM_WORLD);
-
+
/* Print any final data waiting in our queue */
print_incoming_data();
-
+
}
h5diffdebug("done with if block\n");
-
+
free(workerTasks);
#endif /* H5_HAVE_PARALLEL */
}
-
+
/* free table */
trav_table_free (table);
-
-
+
+
/*-------------------------------------------------------------------------
* do the diff for the root.
* this is a special case, we get an ID for the root group and call diff()
* with this ID; it compares only the root group attributes
*-------------------------------------------------------------------------
*/
-
+
/* the manager can do this. */
nfound += diff (file1_id, "/", file2_id, "/", options, H5G_GROUP);
-
+
return nfound;
}
@@ -810,16 +810,16 @@ hsize_t diff_compare (hid_t file1_id,
hid_t file2_id,
const char *file2_name,
const char *obj2_name,
- int nobjects2,
- trav_info_t * info2,
+ int nobjects2,
+ trav_info_t * info2,
diff_opt_t * options)
{
int f1 = 0, f2 = 0;
hsize_t nfound = 0;
-
+
int i = h5trav_getindex (obj1_name, nobjects1, info1);
int j = h5trav_getindex (obj2_name, nobjects2, info2);
-
+
if (i == -1)
{
parallel_print ("Object <%s> could not be found in <%s>\n", obj1_name,
@@ -837,11 +837,11 @@ hsize_t diff_compare (hid_t file1_id,
options->err_stat = 1;
return 0;
}
-
+
/* use the name with "/" first, as obtained by iterator function */
obj1_name = info1[i].name;
obj2_name = info2[j].name;
-
+
/* objects are not the same type */
if (info1[i].type != info2[j].type)
{
@@ -853,10 +853,10 @@ hsize_t diff_compare (hid_t file1_id,
options->not_cmp=1;
return 0;
}
-
+
nfound =
diff (file1_id, obj1_name, file2_id, obj2_name, options, info1[i].type);
-
+
return nfound;
}
@@ -882,9 +882,9 @@ hsize_t diff_compare (hid_t file1_id,
hsize_t diff (hid_t file1_id,
const char *path1,
- hid_t file2_id,
- const char *path2,
- diff_opt_t * options,
+ hid_t file2_id,
+ const char *path2,
+ diff_opt_t * options,
H5G_obj_t type)
{
hid_t type1_id=(-1);
@@ -895,7 +895,7 @@ hsize_t diff (hid_t file1_id,
H5G_stat_t sb1;
H5G_stat_t sb2;
hsize_t nfound = 0;
-
+
switch (type)
{
/*-------------------------------------------------------------------------
@@ -903,7 +903,7 @@ hsize_t diff (hid_t file1_id,
*-------------------------------------------------------------------------
*/
case H5G_DATASET:
-
+
/*-------------------------------------------------------------------------
* verbose, always print name
*-------------------------------------------------------------------------
@@ -939,7 +939,7 @@ hsize_t diff (hid_t file1_id,
print_found(nfound);
} /*if nfound */
} /*if quiet */
-
+
/*-------------------------------------------------------------------------
* quiet mode, just count differences
*-------------------------------------------------------------------------
@@ -949,9 +949,9 @@ hsize_t diff (hid_t file1_id,
nfound = diff_dataset (file1_id, file2_id, path1, path2, options);
}
} /*else verbose */
-
+
break;
-
+
/*-------------------------------------------------------------------------
* H5G_TYPE
*-------------------------------------------------------------------------
@@ -961,20 +961,20 @@ hsize_t diff (hid_t file1_id,
goto out;
if ((type2_id = H5Topen (file2_id, path2)) < 0)
goto out;
-
+
if ((ret = H5Tequal (type1_id, type2_id)) < 0)
goto out;
-
+
/* if H5Tequal is > 0 then the datatypes refer to the same datatype */
nfound = (ret > 0) ? 0 : 1;
-
+
if (print_objname (options, nfound))
parallel_print("Datatype: <%s> and <%s>\n", path1, path2);
-
+
/* always print the number of differences found in verbose mode */
if (options->m_verbose)
print_found(nfound);
-
+
/*-------------------------------------------------------------------------
* compare attributes
* the if condition refers to cases when the dataset is a referenced object
@@ -982,14 +982,14 @@ hsize_t diff (hid_t file1_id,
*/
if (path1)
diff_attr (type1_id, type2_id, path1, path2, options);
-
+
if (H5Tclose (type1_id) < 0)
goto out;
if (H5Tclose (type2_id) < 0)
goto out;
-
+
break;
-
+
/*-------------------------------------------------------------------------
* H5G_GROUP
*-------------------------------------------------------------------------
@@ -999,19 +999,19 @@ hsize_t diff (hid_t file1_id,
goto out;
if ((grp2_id = H5Gopen (file2_id, path2)) < 0)
goto out;
-
+
ret = HDstrcmp (path1, path2);
-
+
/* if "path1" != "path2" then the groups are "different" */
nfound = (ret != 0) ? 1 : 0;
-
+
if (print_objname (options, nfound))
parallel_print("Group: <%s> and <%s>\n", path1, path2);
-
+
/* always print the number of differences found in verbose mode */
if (options->m_verbose)
print_found(nfound);
-
+
/*-------------------------------------------------------------------------
* compare attributes
* the if condition refers to cases when the dataset is a referenced object
@@ -1019,15 +1019,15 @@ hsize_t diff (hid_t file1_id,
*/
if (path1)
diff_attr (grp1_id, grp2_id, path1, path2, options);
-
+
if (H5Gclose (grp1_id) < 0)
goto out;
if (H5Gclose (grp2_id) < 0)
goto out;
-
+
break;
-
-
+
+
/*-------------------------------------------------------------------------
* H5G_LINK
*-------------------------------------------------------------------------
@@ -1036,37 +1036,37 @@ hsize_t diff (hid_t file1_id,
{
char *buf1 = NULL;
char *buf2 = NULL;
-
+
if (H5Gget_objinfo (file1_id, path1, FALSE, &sb1) < 0)
goto out;
if (H5Gget_objinfo (file1_id, path1, FALSE, &sb2) < 0)
goto out;
-
+
buf1 = HDmalloc (sb1.linklen);
buf2 = HDmalloc (sb2.linklen);
-
+
if (H5Gget_linkval (file1_id, path1, sb1.linklen, buf1) < 0)
goto out;
if (H5Gget_linkval (file2_id, path2, sb1.linklen, buf2) < 0)
goto out;
-
+
ret = HDstrcmp (buf1, buf2);
-
+
/* if "buf1" != "buf2" then the links are "different" */
nfound = (ret != 0) ? 1 : 0;
-
+
if (print_objname (options, nfound))
parallel_print("Soft Link: <%s> and <%s>\n", path1, path2);
-
+
/* always print the number of differences found in verbose mode */
if (options->m_verbose)
print_found(nfound);
-
+
HDfree (buf1);
HDfree (buf2);
}
break;
-
+
default:
nfound = 0;
if (options->m_verbose)
@@ -1075,13 +1075,13 @@ hsize_t diff (hid_t file1_id,
path1, path2, get_type (type));
options->not_cmp=1;
}
-
+
break;
} /* switch */
-
-
+
+
out:
-
+
/* close */
/* disable error reporting */
H5E_BEGIN_TRY
diff --git a/tools/lib/h5diff_array.c b/tools/lib/h5diff_array.c
index 18858d6..62975d9 100644
--- a/tools/lib/h5diff_array.c
+++ b/tools/lib/h5diff_array.c
@@ -52,7 +52,7 @@
/* local functions */
static void close_obj(H5G_obj_t obj_type, hid_t obj_id);
-static hsize_t diff_region(hid_t obj1_id, hid_t obj2_id,
+static hsize_t diff_region(hid_t obj1_id, hid_t obj2_id,
hid_t region1_id, hid_t region2_id, diff_opt_t *options);
static hbool_t is_zero(const void *_mem, size_t size);
static int ull2float(unsigned long_long ull_value, float *f_value);
@@ -65,7 +65,7 @@ static int ull2float(unsigned long_long ull_value, float *f_value);
* and do not print in quiet mode
*-------------------------------------------------------------------------
*/
-static
+static
int print_data(diff_opt_t *options)
{
return ( (options->m_report || options->m_verbose) && !options->m_quiet)?1:0;
@@ -74,11 +74,11 @@ int print_data(diff_opt_t *options)
/*-------------------------------------------------------------------------
* Function: print_pos
*
- * Purpose: print in matrix notation, converting from an array index position
+ * Purpose: print in matrix notation, converting from an array index position
*
*-------------------------------------------------------------------------
*/
-static
+static
void print_pos( int *ph, /* print header */
int per, /* print percentage */
hsize_t curr_pos,
@@ -168,10 +168,10 @@ hsize_t diff_array( void *_mem1,
int ph=1; /* print header */
hsize_t i;
int j;
-
+
/* get the size. */
size = H5Tget_size( m_type );
-
+
acc[rank-1]=1;
for(j=(rank-2); j>=0; j--)
{
@@ -179,7 +179,7 @@ hsize_t diff_array( void *_mem1,
}
for ( j = 0; j < rank; j++)
pos[j]=0;
-
+
if(H5Tis_variable_str(m_type))
{
tmp1 = ((unsigned char**)mem1)[0];
@@ -199,7 +199,7 @@ hsize_t diff_array( void *_mem1,
container2_id,
&ph);
}
-
+
else
{
switch (H5Tget_class(m_type))
@@ -207,7 +207,7 @@ hsize_t diff_array( void *_mem1,
default:
assert(0);
break;
-
+
case H5T_FLOAT:
if (H5Tequal(m_type, H5T_NATIVE_FLOAT))
@@ -215,9 +215,9 @@ hsize_t diff_array( void *_mem1,
else if (H5Tequal(m_type, H5T_NATIVE_DOUBLE))
nfound=diff_double(mem1,mem2,nelmts,rank,acc,pos,options,name1,name2,&ph);
break;
-
+
case H5T_INTEGER:
-
+
if (H5Tequal(m_type, H5T_NATIVE_SCHAR))
nfound=diff_schar(mem1,mem2,nelmts,rank,acc,pos,options,name1,name2,&ph);
else if (H5Tequal(m_type, H5T_NATIVE_UCHAR))
@@ -238,9 +238,9 @@ hsize_t diff_array( void *_mem1,
nfound=diff_llong(mem1,mem2,nelmts,rank,acc,pos,options,name1,name2,&ph);
else if (H5Tequal(m_type, H5T_NATIVE_ULLONG))
nfound=diff_ullong(mem1,mem2,nelmts,rank,acc,pos,options,name1,name2,&ph);
-
+
break;
-
+
case H5T_COMPOUND:
case H5T_STRING:
case H5T_BITFIELD:
@@ -249,7 +249,7 @@ hsize_t diff_array( void *_mem1,
case H5T_ARRAY:
case H5T_VLEN:
case H5T_REFERENCE:
-
+
for ( i = 0; i < nelmts; i++)
{
nfound+=diff_datum(
@@ -271,7 +271,7 @@ hsize_t diff_array( void *_mem1,
} /* i */
} /* switch */
} /* else */
-
+
return nfound;
}
@@ -348,9 +348,9 @@ hsize_t diff_datum(void *_mem1,
hsize_t nfound=0; /* differences found */
int ret=0; /* check return error */
float f1, f2, per;
-
+
type_size = H5Tget_size( m_type );
-
+
switch (H5Tget_class(m_type))
{
default:
@@ -359,7 +359,7 @@ hsize_t diff_datum(void *_mem1,
case H5T_TIME:
assert(0);
break;
-
+
/*-------------------------------------------------------------------------
* H5T_COMPOUND
*-------------------------------------------------------------------------
@@ -387,17 +387,17 @@ hsize_t diff_datum(void *_mem1,
H5Tclose(memb_type);
}
break;
-
+
/*-------------------------------------------------------------------------
* H5T_STRING
*-------------------------------------------------------------------------
*/
case H5T_STRING:
{
-
+
H5T_str_t pad;
char *s;
-
+
if(H5Tis_variable_str(m_type))
{
/* mem1 is the pointer into the struct where a `char*' is stored. So we have
@@ -411,9 +411,9 @@ hsize_t diff_datum(void *_mem1,
s = (char *)mem1;
size = H5Tget_size(m_type);
}
-
+
pad = H5Tget_strpad(m_type);
-
+
/* check for NULL pointer for string */
if(s!=NULL)
for (u=0; u<size && (s[u] || pad!=H5T_STR_NULLTERM); u++)
@@ -428,10 +428,10 @@ hsize_t diff_datum(void *_mem1,
obj1,
obj2,
ph);
-
+
}
break;
-
+
/*-------------------------------------------------------------------------
* H5T_BITFIELD
*-------------------------------------------------------------------------
@@ -451,16 +451,16 @@ hsize_t diff_datum(void *_mem1,
obj1,
obj2,
ph);
-
+
}
break;
-
+
/*-------------------------------------------------------------------------
* H5T_OPAQUE
*-------------------------------------------------------------------------
*/
case H5T_OPAQUE:
-
+
/* byte-by-byte comparison */
for (u=0; u<type_size; u++)
nfound+=diff_native_uchar(
@@ -474,29 +474,29 @@ hsize_t diff_datum(void *_mem1,
obj1,
obj2,
ph);
-
+
break;
-
-
+
+
/*-------------------------------------------------------------------------
* H5T_ENUM
*-------------------------------------------------------------------------
*/
case H5T_ENUM:
-
+
/* For enumeration types we compare the names instead of the
integer values. For each pair of elements being
compared, we convert both bit patterns to their corresponding
- enumeration constant and do a string comparison
+ enumeration constant and do a string comparison
*/
-
+
{
char enum_name1[1024];
char enum_name2[1024];
-
+
/* disable error reporting */
H5E_BEGIN_TRY {
-
+
if ((H5Tenum_nameof(m_type, mem1, enum_name1, sizeof enum_name1) >= 0) &&
(H5Tenum_nameof(m_type, mem2, enum_name2, sizeof enum_name2) >= 0))
{
@@ -529,10 +529,10 @@ hsize_t diff_datum(void *_mem1,
/* enable error reporting */
} H5E_END_TRY;
}
-
-
+
+
break;
-
+
/*-------------------------------------------------------------------------
* H5T_ARRAY
*-------------------------------------------------------------------------
@@ -544,7 +544,7 @@ hsize_t diff_datum(void *_mem1,
ndims = H5Tget_array_ndims(m_type);
H5Tget_array_dims(m_type, dims, NULL);
assert(ndims >= 1 && ndims <= H5S_MAX_RANK);
-
+
/* calculate the number of array elements */
for (u = 0, nelmts = 1; u <ndims; u++)
nelmts *= dims[u];
@@ -565,21 +565,21 @@ hsize_t diff_datum(void *_mem1,
ph);
H5Tclose(memb_type);
break;
-
+
/*-------------------------------------------------------------------------
* H5T_VLEN
*-------------------------------------------------------------------------
*/
case H5T_VLEN:
-
+
/* get the VL sequences's base datatype for each element */
memb_type = H5Tget_super(m_type);
size = H5Tget_size(memb_type);
-
+
/* get the number of sequence elements */
nelmts = ((hvl_t *)mem1)->len;
-
+
for (j = 0; j < (int)nelmts; j++)
nfound+=diff_datum(
((char *)(((hvl_t *)mem1)->p)) + j * size,
@@ -595,14 +595,14 @@ hsize_t diff_datum(void *_mem1,
container1_id,
container2_id,
ph);
-
+
H5Tclose(memb_type);
-
+
break;
-
-
+
+
case H5T_REFERENCE:
-
+
iszero1=is_zero(_mem1, H5Tget_size(m_type));
iszero2=is_zero(_mem2, H5Tget_size(m_type));
if (iszero1==1 || iszero2==1)
@@ -611,18 +611,18 @@ hsize_t diff_datum(void *_mem1,
}
else
{
-
+
/*-------------------------------------------------------------------------
* H5T_STD_REF_DSETREG
* Dataset region reference
*-------------------------------------------------------------------------
*/
-
+
if (H5Tequal(m_type, H5T_STD_REF_DSETREG))
{
hid_t region1_id;
hid_t region2_id;
-
+
if ((obj1_id = H5Rdereference(container1_id, H5R_DATASET_REGION, _mem1))<0)
ret= -1;
if ((obj2_id = H5Rdereference(container2_id, H5R_DATASET_REGION, _mem2))<0)
@@ -631,22 +631,22 @@ hsize_t diff_datum(void *_mem1,
ret= -1;
if ((region2_id = H5Rget_region(container2_id, H5R_DATASET_REGION, _mem2))<0)
ret= -1;
-
+
if (ret==-1) {
options->err_stat=1;
return 0;
}
-
+
nfound = diff_region(obj1_id,obj2_id,region1_id,region2_id,options);
-
+
close_obj(H5G_DATASET,obj1_id);
close_obj(H5G_DATASET,obj2_id);
H5Sclose(region1_id);
H5Sclose(region2_id);
-
+
}/*dataset reference*/
-
-
+
+
/*-------------------------------------------------------------------------
* H5T_STD_REF_OBJ
* Object references. get the type and OID of the referenced object
@@ -654,7 +654,7 @@ hsize_t diff_datum(void *_mem1,
*/
else if (H5Tequal(m_type, H5T_STD_REF_OBJ))
{
-
+
if ((obj1_type = H5Rget_obj_type(container1_id, H5R_OBJECT, _mem1))<0)
ret= -1;
if ((obj2_type = H5Rget_obj_type(container2_id, H5R_OBJECT, _mem2))<0)
@@ -663,7 +663,7 @@ hsize_t diff_datum(void *_mem1,
options->err_stat=1;
return 0;
}
-
+
/* check object type */
if (obj1_type!=obj2_type)
{
@@ -671,7 +671,7 @@ hsize_t diff_datum(void *_mem1,
options->not_cmp=1;
return 0;
}
-
+
if ((obj1_id = H5Rdereference(container1_id, H5R_OBJECT, _mem1))<0)
ret= -1;
if ((obj2_id = H5Rdereference(container2_id, H5R_OBJECT, _mem2))<0)
@@ -680,7 +680,7 @@ hsize_t diff_datum(void *_mem1,
options->err_stat=1;
return 0;
}
-
+
/* compare */
switch (obj1_type) {
case H5G_DATASET:
@@ -696,21 +696,21 @@ hsize_t diff_datum(void *_mem1,
options->not_cmp=1;
break;
}
-
+
close_obj(obj1_type,obj1_id);
close_obj(obj2_type,obj2_id);
-
+
}/*object reference*/
-
+
}/*is zero*/
-
-
+
+
break;
-
-
+
+
case H5T_INTEGER:
-
-
+
+
/*-------------------------------------------------------------------------
* H5T_NATIVE_SCHAR
*-------------------------------------------------------------------------
@@ -780,9 +780,9 @@ hsize_t diff_datum(void *_mem1,
}
nfound++;
}
-
+
} /*H5T_NATIVE_SCHAR*/
-
+
/*-------------------------------------------------------------------------
* H5T_NATIVE_UCHAR
*-------------------------------------------------------------------------
@@ -792,7 +792,7 @@ hsize_t diff_datum(void *_mem1,
unsigned char temp1_uchar;
unsigned char temp2_uchar;
assert(type_size==sizeof(unsigned char));
-
+
memcpy(&temp1_uchar, mem1, sizeof(unsigned char));
memcpy(&temp2_uchar, mem2, sizeof(unsigned char));
/* -d and !-p */
@@ -820,7 +820,7 @@ hsize_t diff_datum(void *_mem1,
print_pos(ph,1,i,acc,pos,rank,obj1,obj2);
parallel_print(SPACES);
parallel_print(I_FORMAT_P,temp1_uchar,temp2_uchar,
- abs(temp1_uchar-temp2_uchar),
+ abs(temp1_uchar-temp2_uchar),
per);
}
nfound++;
@@ -837,7 +837,7 @@ hsize_t diff_datum(void *_mem1,
print_pos(ph,1,i,acc,pos,rank,obj1,obj2);
parallel_print(SPACES);
parallel_print(I_FORMAT_P,temp1_uchar,temp2_uchar,
- abs(temp1_uchar-temp2_uchar),
+ abs(temp1_uchar-temp2_uchar),
per);
}
nfound++;
@@ -853,21 +853,21 @@ hsize_t diff_datum(void *_mem1,
}
nfound++;
}
-
+
} /*H5T_NATIVE_UCHAR*/
-
-
+
+
/*-------------------------------------------------------------------------
* H5T_NATIVE_SHORT
*-------------------------------------------------------------------------
*/
-
+
else if (H5Tequal(m_type, H5T_NATIVE_SHORT))
{
short temp1_short;
short temp2_short;
assert(type_size==sizeof(short));
-
+
memcpy(&temp1_short, mem1, sizeof(short));
memcpy(&temp2_short, mem2, sizeof(short));
/* -d and !-p */
@@ -928,21 +928,21 @@ hsize_t diff_datum(void *_mem1,
}
nfound++;
}
-
-
+
+
} /*H5T_NATIVE_SHORT*/
-
+
/*-------------------------------------------------------------------------
* H5T_NATIVE_USHORT
*-------------------------------------------------------------------------
*/
-
+
else if (H5Tequal(m_type, H5T_NATIVE_USHORT))
{
unsigned short temp1_ushort;
unsigned short temp2_ushort;
assert(type_size==sizeof(short));
-
+
memcpy(&temp1_ushort, mem1, sizeof(unsigned short));
memcpy(&temp2_ushort, mem2, sizeof(unsigned short));
/* -d and !-p */
@@ -950,7 +950,7 @@ hsize_t diff_datum(void *_mem1,
{
if (abs(temp1_ushort-temp2_ushort) > options->delta)
{
-
+
if ( print_data(options) )
{
print_pos(ph,0,i,acc,pos,rank,obj1,obj2);
@@ -1005,19 +1005,19 @@ hsize_t diff_datum(void *_mem1,
nfound++;
}
} /*H5T_NATIVE_USHORT*/
-
-
+
+
/*-------------------------------------------------------------------------
* H5T_NATIVE_INT
*-------------------------------------------------------------------------
*/
-
+
else if (H5Tequal(m_type, H5T_NATIVE_INT))
{
int temp1_int;
int temp2_int;
assert(type_size==sizeof(int));
-
+
memcpy(&temp1_int, mem1, sizeof(int));
memcpy(&temp2_int, mem2, sizeof(int));
/* -d and !-p */
@@ -1043,7 +1043,7 @@ hsize_t diff_datum(void *_mem1,
if ( print_data(options) )
{
print_pos(ph,1,i,acc,pos,rank,obj1,obj2);
-
+
parallel_print(SPACES);
parallel_print(I_FORMAT_P,temp1_int,temp2_int,
abs(temp1_int-temp2_int),
@@ -1080,19 +1080,19 @@ hsize_t diff_datum(void *_mem1,
nfound++;
}
} /*H5T_NATIVE_INT*/
-
-
+
+
/*-------------------------------------------------------------------------
* H5T_NATIVE_UINT
*-------------------------------------------------------------------------
*/
-
+
else if (H5Tequal(m_type, H5T_NATIVE_UINT))
{
unsigned int temp1_uint;
unsigned int temp2_uint;
assert(type_size==sizeof(int));
-
+
memcpy(&temp1_uint, mem1, sizeof(unsigned int));
memcpy(&temp2_uint, mem2, sizeof(unsigned int));
/* -d and !-p */
@@ -1154,19 +1154,19 @@ hsize_t diff_datum(void *_mem1,
nfound++;
}
} /*H5T_NATIVE_UINT*/
-
-
+
+
/*-------------------------------------------------------------------------
* H5T_NATIVE_LONG
*-------------------------------------------------------------------------
*/
-
+
else if (H5Tequal(m_type, H5T_NATIVE_LONG))
{
long temp1_long;
long temp2_long;
assert(type_size==sizeof(long));
-
+
memcpy(&temp1_long, mem1, sizeof(long));
memcpy(&temp2_long, mem2, sizeof(long));
/* -d and !-p */
@@ -1228,18 +1228,18 @@ hsize_t diff_datum(void *_mem1,
nfound++;
}
} /*H5T_NATIVE_LONG*/
-
+
/*-------------------------------------------------------------------------
* H5T_NATIVE_ULONG
*-------------------------------------------------------------------------
*/
-
+
else if (H5Tequal(m_type, H5T_NATIVE_ULONG))
{
unsigned long temp1_ulong;
unsigned long temp2_ulong;
assert(type_size==sizeof(unsigned long));
-
+
memcpy(&temp1_ulong, mem1, sizeof(unsigned long));
memcpy(&temp2_ulong, mem2, sizeof(unsigned long));
/* -d and !-p */
@@ -1300,21 +1300,21 @@ hsize_t diff_datum(void *_mem1,
}
nfound++;
}
-
-
+
+
} /*H5T_NATIVE_ULONG*/
-
+
/*-------------------------------------------------------------------------
* H5T_NATIVE_LLONG
*-------------------------------------------------------------------------
*/
-
+
else if (H5Tequal(m_type, H5T_NATIVE_LLONG))
{
long_long temp1_llong;
long_long temp2_llong;
assert(type_size==sizeof(long_long));
-
+
memcpy(&temp1_llong, mem1, sizeof(long_long));
memcpy(&temp2_llong, mem2, sizeof(long_long));
/* -d and !-p */
@@ -1343,7 +1343,7 @@ hsize_t diff_datum(void *_mem1,
print_pos(ph,1,i,acc,pos,rank,obj1,obj2);
parallel_print(SPACES);
parallel_print(LLI_FORMAT_P,temp1_llong,temp2_llong,
- (long_long)labs((long)(temp1_llong-temp2_llong)),
+ (long_long)labs((long)(temp1_llong-temp2_llong)),
per);
}
nfound++;
@@ -1360,7 +1360,7 @@ hsize_t diff_datum(void *_mem1,
print_pos(ph,1,i,acc,pos,rank,obj1,obj2);
parallel_print(SPACES);
parallel_print(LLI_FORMAT_P,temp1_llong,temp2_llong,
- (long_long)labs((long)(temp1_llong-temp2_llong)),
+ (long_long)labs((long)(temp1_llong-temp2_llong)),
per);
}
nfound++;
@@ -1377,20 +1377,20 @@ hsize_t diff_datum(void *_mem1,
}
nfound++;
}
-
+
} /*H5T_NATIVE_LLONG*/
-
+
/*-------------------------------------------------------------------------
* H5T_NATIVE_ULLONG
*-------------------------------------------------------------------------
*/
-
+
else if (H5Tequal(m_type, H5T_NATIVE_ULLONG))
{
unsigned long_long temp1_ullong;
unsigned long_long temp2_ullong;
assert(type_size==sizeof(unsigned long_long));
-
+
memcpy(&temp1_ullong, mem1, sizeof(unsigned long_long));
memcpy(&temp2_ullong, mem2, sizeof(unsigned long_long));
/* -d and !-p */
@@ -1402,7 +1402,7 @@ hsize_t diff_datum(void *_mem1,
{
print_pos(ph,0,i,acc,pos,rank,obj1,obj2);
parallel_print(SPACES);
- parallel_print(ULLI_FORMAT,temp1_ullong,temp2_ullong,
+ parallel_print(ULLI_FORMAT,temp1_ullong,temp2_ullong,
(unsigned long_long)labs((long)(temp1_ullong-temp2_ullong)));
}
nfound++;
@@ -1414,15 +1414,15 @@ hsize_t diff_datum(void *_mem1,
ull2float(temp1_ullong,&f1);
ull2float(temp2_ullong,&f2);
PER(f1,f2);
- if ( per > options->percent )
+ if ( per > options->percent )
{
-
+
if ( print_data(options) )
{
print_pos(ph,1,i,acc,pos,rank,obj1,obj2);
parallel_print(SPACES);
- parallel_print(ULLI_FORMAT_P,temp1_ullong,temp2_ullong,
- (unsigned long_long)labs((long)(temp1_ullong-temp2_ullong)),
+ parallel_print(ULLI_FORMAT_P,temp1_ullong,temp2_ullong,
+ (unsigned long_long)labs((long)(temp1_ullong-temp2_ullong)),
per);
}
nfound++;
@@ -1436,14 +1436,14 @@ hsize_t diff_datum(void *_mem1,
PER(f1,f2);
if ( per > options->percent && labs((long)(temp1_ullong-temp2_ullong)) > (long)options->delta )
{
-
+
if ( print_data(options) )
{
print_pos(ph,1,i,acc,pos,rank,obj1,obj2);
-
+
parallel_print(SPACES);
- parallel_print(ULLI_FORMAT_P,temp1_ullong,temp2_ullong,
- (unsigned long_long)labs((long)(temp1_ullong-temp2_ullong)),
+ parallel_print(ULLI_FORMAT_P,temp1_ullong,temp2_ullong,
+ (unsigned long_long)labs((long)(temp1_ullong-temp2_ullong)),
per);
}
nfound++;
@@ -1455,23 +1455,23 @@ hsize_t diff_datum(void *_mem1,
{
print_pos(ph,0,i,acc,pos,rank,obj1,obj2);
parallel_print(SPACES);
- parallel_print(ULLI_FORMAT,temp1_ullong,temp2_ullong,
+ parallel_print(ULLI_FORMAT,temp1_ullong,temp2_ullong,
(unsigned long_long)labs((long)(temp1_ullong-temp2_ullong)));
}
nfound++;
}
-
+
} /*H5T_NATIVE_ULLONG*/
-
-
+
+
break; /* H5T_INTEGER class */
case H5T_FLOAT:
-
+
/*-------------------------------------------------------------------------
* H5T_NATIVE_FLOAT
*-------------------------------------------------------------------------
*/
-
+
if (H5Tequal(m_type, H5T_NATIVE_FLOAT))
{
float temp1_float;
@@ -1479,7 +1479,7 @@ hsize_t diff_datum(void *_mem1,
assert(type_size==sizeof(float));
memcpy(&temp1_float, mem1, sizeof(float));
memcpy(&temp2_float, mem2, sizeof(float));
-
+
/* -d and !-p */
if (options->d && !options->p)
{
@@ -1499,7 +1499,7 @@ hsize_t diff_datum(void *_mem1,
{
if ( temp1_float!=0 && fabs(1-temp2_float/temp1_float) > options->percent )
{
-
+
if ( print_data(options) )
{
print_pos(ph,1,i,acc,pos,rank,obj1,obj2);
@@ -1509,7 +1509,7 @@ hsize_t diff_datum(void *_mem1,
nfound++;
}
}
-
+
/* -d and -p */
else if ( options->d && options->p)
{
@@ -1519,7 +1519,7 @@ hsize_t diff_datum(void *_mem1,
if ( print_data(options) )
{
print_pos(ph,1,i,acc,pos,rank,obj1,obj2);
-
+
parallel_print(SPACES);
parallel_print(F_FORMAT_P,temp1_float,temp2_float,fabs(temp1_float-temp2_float), fabs(1-temp2_float/temp1_float));
}
@@ -1528,30 +1528,30 @@ hsize_t diff_datum(void *_mem1,
}
else if (temp1_float != temp2_float)
{
-
+
if ( print_data(options) )
{
print_pos(ph,0,i,acc,pos,rank,obj1,obj2);
-
+
parallel_print(SPACES);
parallel_print(F_FORMAT,temp1_float,temp2_float,fabs(temp1_float-temp2_float));
}
nfound++;
}
-
+
} /*H5T_NATIVE_FLOAT*/
-
+
/*-------------------------------------------------------------------------
* H5T_NATIVE_DOUBLE
*-------------------------------------------------------------------------
*/
-
+
else if (H5Tequal(m_type, H5T_NATIVE_DOUBLE))
{
double temp1_double;
double temp2_double;
assert(type_size==sizeof(double));
-
+
memcpy(&temp1_double, mem1, sizeof(double));
memcpy(&temp2_double, mem2, sizeof(double));
/* -d and !-p */
@@ -1588,7 +1588,7 @@ hsize_t diff_datum(void *_mem1,
if ( temp1_double!=0 && fabs(1-temp2_double/temp1_double) > options->percent &&
fabs(temp1_double-temp2_double) > options->delta )
{
-
+
if ( print_data(options) )
{
print_pos(ph,1,i,acc,pos,rank,obj1,obj2);
@@ -1609,16 +1609,16 @@ hsize_t diff_datum(void *_mem1,
nfound++;
}
} /*H5T_NATIVE_DOUBLE*/
-
-
+
+
break; /* H5T_FLOAT class */
-
+
} /* switch */
-
+
return nfound;
}
-
-
+
+
/*-------------------------------------------------------------------------
* Function: diff_char
*
@@ -1628,7 +1628,7 @@ hsize_t diff_datum(void *_mem1,
*
*-------------------------------------------------------------------------
*/
-
+
hsize_t diff_char(unsigned char *mem1,
unsigned char *mem2,
hsize_t i,
@@ -1643,10 +1643,10 @@ hsize_t diff_char(unsigned char *mem1,
hsize_t nfound=0; /* differences found */
unsigned char temp1_uchar;
unsigned char temp2_uchar;
-
+
memcpy(&temp1_uchar, mem1, sizeof(unsigned char));
memcpy(&temp2_uchar, mem2, sizeof(unsigned char));
-
+
if (temp1_uchar != temp2_uchar)
{
if ( print_data(options) )
@@ -1657,12 +1657,12 @@ hsize_t diff_char(unsigned char *mem1,
}
nfound++;
}
-
+
return nfound;
}
-
-
-
+
+
+
/*-------------------------------------------------------------------------
* Function: is_zero
*
@@ -1676,11 +1676,11 @@ hsize_t diff_char(unsigned char *mem1,
static hbool_t is_zero(const void *_mem, size_t size)
{
const unsigned char *mem = (const unsigned char *)_mem;
-
+
while (size-- > 0)
if (mem[size])
return FALSE;
-
+
return TRUE;
}
@@ -1713,7 +1713,7 @@ static void close_obj(H5G_obj_t obj_type, hid_t obj_id)
/*-------------------------------------------------------------------------
* Function: print_region_block
*
- * Purpose: print start coordinates and opposite corner of a region block
+ * Purpose: print start coordinates and opposite corner of a region block
*
* Return: void
*
@@ -1740,7 +1740,7 @@ void print_region_block(int i, hsize_t *ptdata, int ndims)
/*-------------------------------------------------------------------------
* Function: print_points
*
- * Purpose: print points of a region reference
+ * Purpose: print points of a region reference
*
* Return: void
*
@@ -1757,9 +1757,9 @@ void print_points(int i, hsize_t *ptdata, int ndims)
parallel_print("%s%lu", j ? "," : "(",
(unsigned long)(ptdata[i * ndims + j]));
parallel_print(")");
-
+
}
-
+
/*-------------------------------------------------------------------------
* Function: diff_region
*
@@ -1769,14 +1769,14 @@ void print_points(int i, hsize_t *ptdata, int ndims)
*
*-------------------------------------------------------------------------
*/
-
-static
-hsize_t diff_region(hid_t obj1_id,
- hid_t obj2_id,
- hid_t region1_id,
+
+static
+hsize_t diff_region(hid_t obj1_id,
+ hid_t obj2_id,
+ hid_t region1_id,
hid_t region2_id,
diff_opt_t *options)
-
+
{
hssize_t nblocks1, npoints1;
hssize_t nblocks2, npoints2;
@@ -1809,7 +1809,7 @@ hsize_t diff_region(hid_t obj1_id,
H5E_BEGIN_TRY {
nblocks1 = H5Sget_select_hyper_nblocks(region1_id);
nblocks2 = H5Sget_select_hyper_nblocks(region2_id);
-
+
npoints1 = H5Sget_select_elem_npoints(region1_id);
npoints2 = H5Sget_select_elem_npoints(region2_id);
} H5E_END_TRY;
@@ -1826,18 +1826,18 @@ hsize_t diff_region(hid_t obj1_id,
*/
if (nblocks1 > 0)
{
-
+
alloc_size = nblocks1 * ndims1 * 2 * sizeof(ptdata1[0]);
assert(alloc_size == (hsize_t)((size_t)alloc_size)); /*check for overflow*/
-
+
ptdata1 = malloc((size_t)alloc_size);
H5_CHECK_OVERFLOW(nblocks1, hssize_t, hsize_t);
H5Sget_select_hyper_blocklist(region1_id, (hsize_t)0, (hsize_t)nblocks1, ptdata1);
-
+
ptdata2 = malloc((size_t)alloc_size);
H5_CHECK_OVERFLOW(nblocks2, hssize_t, hsize_t);
H5Sget_select_hyper_blocklist(region2_id, (hsize_t)0, (hsize_t)nblocks2, ptdata2);
-
+
for (i = 0; i < nblocks1; i++)
{
/* start coordinates and opposite corner */
@@ -1854,9 +1854,9 @@ hsize_t diff_region(hid_t obj1_id,
}
}
}
-
- /* print differences if found */
+
+ /* print differences if found */
if (nfound_b && options->m_verbose)
{
parallel_print("Referenced dataset %lu %lu\n",
@@ -1872,8 +1872,8 @@ hsize_t diff_region(hid_t obj1_id,
parallel_print("\n");
}
- }
-
+ }
+
HDfree(ptdata1);
HDfree(ptdata2);
}
@@ -1887,19 +1887,19 @@ hsize_t diff_region(hid_t obj1_id,
{
alloc_size = npoints1 * ndims1 * sizeof(ptdata1[0]);
assert(alloc_size == (hsize_t)((size_t)alloc_size)); /*check for overflow*/
-
+
ptdata1 = malloc((size_t)alloc_size);
H5_CHECK_OVERFLOW(npoints1,hssize_t,hsize_t);
H5Sget_select_elem_pointlist(region1_id, (hsize_t)0, (hsize_t)npoints1, ptdata1);
-
+
ptdata2 = malloc((size_t)alloc_size);
H5_CHECK_OVERFLOW(npoints1,hssize_t,hsize_t);
H5Sget_select_elem_pointlist(region2_id, (hsize_t)0, (hsize_t)npoints2, ptdata2);
-
+
for (i = 0; i < npoints1; i++)
{
hsize_t pt1, pt2;
-
+
for (j = 0; j < ndims1; j++)
{
pt1 = ptdata1[i * ndims1 + j];
@@ -1931,36 +1931,36 @@ hsize_t diff_region(hid_t obj1_id,
parallel_print("\n");
}
}
- }
+ }
#if defined (H5DIFF_DEBUG)
for (i = 0; i < npoints1; i++)
{
int j;
-
+
parallel_print("%sPt%lu: " ,
i ? "," : "",
(unsigned long)i);
-
+
for (j = 0; j < ndims1; j++)
parallel_print("%s%lu", j ? "," : "(",
(unsigned long)(ptdata1[i * ndims1 + j]));
-
+
parallel_print(")");
}
#endif
-
+
HDfree(ptdata1);
HDfree(ptdata2);
}
-
+
nfound_b = nfound_b/ndims1;
nfound_p = nfound_p/ndims1;
return (nfound_p + nfound_b);
}
-
+
/*-------------------------------------------------------------------------
* Function: diff_native_uchar
*
@@ -1982,17 +1982,17 @@ hsize_t diff_native_uchar(unsigned char *mem1,
const char *obj2,
int *ph)
{
-
+
hsize_t nfound=0; /* differences found */
unsigned char temp1_uchar;
unsigned char temp2_uchar;
float per;
-
+
memcpy(&temp1_uchar, mem1, sizeof(unsigned char));
memcpy(&temp2_uchar, mem2, sizeof(unsigned char));
-
+
/* -d and !-p */
-
+
if (options->d && !options->p)
{
if (abs(temp1_uchar-temp2_uchar) > options->delta)
@@ -2050,11 +2050,11 @@ hsize_t diff_native_uchar(unsigned char *mem1,
}
nfound++;
}
-
+
return nfound;
-
+
}
-
+
/*-------------------------------------------------------------------------
* Function: diff_float
@@ -2075,15 +2075,15 @@ hsize_t diff_float(unsigned char *mem1,
const char *obj1,
const char *obj2,
int *ph)
-
+
{
hsize_t nfound=0; /* number of differences found */
float temp1_float;
float temp2_float;
hsize_t i;
float per;
-
-
+
+
/* -d and !-p */
if (options->d && !options->p)
{
@@ -2091,7 +2091,7 @@ hsize_t diff_float(unsigned char *mem1,
{
memcpy(&temp1_float, mem1, sizeof(float));
memcpy(&temp2_float, mem2, sizeof(float));
-
+
if (fabs(temp1_float-temp2_float) > options->delta)
{
if ( print_data(options) )
@@ -2108,7 +2108,7 @@ hsize_t diff_float(unsigned char *mem1,
return nfound;
}
}
-
+
/* !-d and -p */
else if (!options->d && options->p)
{
@@ -2116,7 +2116,7 @@ hsize_t diff_float(unsigned char *mem1,
{
memcpy(&temp1_float, mem1, sizeof(float));
memcpy(&temp2_float, mem2, sizeof(float));
-
+
PER(temp1_float,temp2_float);
if ( per > options->percent )
{
@@ -2136,16 +2136,16 @@ hsize_t diff_float(unsigned char *mem1,
return nfound;
}
}
-
+
/* -d and -p */
else if ( options->d && options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_float, mem1, sizeof(float));
memcpy(&temp2_float, mem2, sizeof(float));
-
+
PER(temp1_float,temp2_float);
if ( per > options->percent && fabs(temp1_float-temp2_float) > options->delta )
{
@@ -2167,12 +2167,12 @@ hsize_t diff_float(unsigned char *mem1,
}
else
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_float, mem1, sizeof(float));
memcpy(&temp2_float, mem2, sizeof(float));
-
+
if (temp1_float != temp2_float)
{
if ( print_data(options) )
@@ -2183,15 +2183,15 @@ hsize_t diff_float(unsigned char *mem1,
}
nfound++;
}
-
+
mem1+=sizeof(float);
mem2+=sizeof(float);
if (options->n && nfound>=options->count)
return nfound;
} /* nelmts */
-
+
}
-
+
return nfound;
}
@@ -2216,24 +2216,24 @@ hsize_t diff_double(unsigned char *mem1,
const char *obj1,
const char *obj2,
int *ph)
-
+
{
hsize_t nfound=0; /* number of differences found */
double temp1_double;
double temp2_double;
hsize_t i;
float per;
-
-
+
+
/* -d and !-p */
if (options->d && !options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_double, mem1, sizeof(double));
memcpy(&temp2_double, mem2, sizeof(double));
-
+
if (fabs(temp1_double-temp2_double) > options->delta)
{
if ( print_data(options) )
@@ -2250,16 +2250,16 @@ hsize_t diff_double(unsigned char *mem1,
return nfound;
}
}
-
+
/* !-d and -p */
else if (!options->d && options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_double, mem1, sizeof(double));
memcpy(&temp2_double, mem2, sizeof(double));
-
+
PER(temp1_double,temp2_double);
if ( per > options->percent )
{
@@ -2279,16 +2279,16 @@ hsize_t diff_double(unsigned char *mem1,
return nfound;
}
}
-
+
/* -d and -p */
else if ( options->d && options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_double, mem1, sizeof(double));
memcpy(&temp2_double, mem2, sizeof(double));
-
+
PER(temp1_double,temp2_double);
if ( per > options->percent && fabs(temp1_double-temp2_double) > options->delta )
{
@@ -2310,12 +2310,12 @@ hsize_t diff_double(unsigned char *mem1,
}
else
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_double, mem1, sizeof(double));
memcpy(&temp2_double, mem2, sizeof(double));
-
+
if (temp1_double != temp2_double)
{
if ( print_data(options) )
@@ -2326,15 +2326,15 @@ hsize_t diff_double(unsigned char *mem1,
}
nfound++;
}
-
+
mem1+=sizeof(double);
mem2+=sizeof(double);
if (options->n && nfound>=options->count)
return nfound;
} /* nelmts */
-
+
}
-
+
return nfound;
}
@@ -2357,24 +2357,24 @@ hsize_t diff_schar(unsigned char *mem1,
const char *obj1,
const char *obj2,
int *ph)
-
+
{
hsize_t nfound=0; /* number of differences found */
char temp1_char;
char temp2_char;
hsize_t i;
float per;
-
-
+
+
/* -d and !-p */
if (options->d && !options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_char, mem1, sizeof(char));
memcpy(&temp2_char, mem2, sizeof(char));
-
+
if (abs(temp1_char-temp2_char) > options->delta)
{
if ( print_data(options) )
@@ -2391,16 +2391,16 @@ hsize_t diff_schar(unsigned char *mem1,
return nfound;
}
}
-
+
/* !-d and -p */
else if (!options->d && options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_char, mem1, sizeof(char));
memcpy(&temp2_char, mem2, sizeof(char));
-
+
PER(temp1_char,temp2_char);
if ( per > options->percent )
{
@@ -2420,16 +2420,16 @@ hsize_t diff_schar(unsigned char *mem1,
return nfound;
}
}
-
+
/* -d and -p */
else if ( options->d && options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_char, mem1, sizeof(char));
memcpy(&temp2_char, mem2, sizeof(char));
-
+
PER(temp1_char,temp2_char);
if ( per > options->percent && abs(temp1_char-temp2_char) > options->delta )
{
@@ -2448,16 +2448,16 @@ hsize_t diff_schar(unsigned char *mem1,
if (options->n && nfound>=options->count)
return nfound;
}
-
+
}
else
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_char, mem1, sizeof(char));
memcpy(&temp2_char, mem2, sizeof(char));
-
+
if (temp1_char != temp2_char)
{
if ( print_data(options) )
@@ -2468,15 +2468,15 @@ hsize_t diff_schar(unsigned char *mem1,
}
nfound++;
}
-
+
mem1+=sizeof(char);
mem2+=sizeof(char);
if (options->n && nfound>=options->count)
return nfound;
} /* nelmts */
-
+
}
-
+
return nfound;
}
@@ -2501,24 +2501,24 @@ hsize_t diff_uchar(unsigned char *mem1,
const char *obj1,
const char *obj2,
int *ph)
-
+
{
hsize_t nfound=0; /* number of differences found */
unsigned char temp1_uchar;
unsigned char temp2_uchar;
hsize_t i;
float per;
-
-
+
+
/* -d and !-p */
if (options->d && !options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_uchar, mem1, sizeof(unsigned char));
memcpy(&temp2_uchar, mem2, sizeof(unsigned char));
-
+
if (abs(temp1_uchar-temp2_uchar) > options->delta)
{
if ( print_data(options) )
@@ -2534,18 +2534,18 @@ hsize_t diff_uchar(unsigned char *mem1,
if (options->n && nfound>=options->count)
return nfound;
}
-
+
}
-
+
/* !-d and -p */
else if (!options->d && options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_uchar, mem1, sizeof(unsigned char));
memcpy(&temp2_uchar, mem2, sizeof(unsigned char));
-
+
PER(temp1_uchar,temp2_uchar);
if ( per > options->percent )
{
@@ -2565,16 +2565,16 @@ hsize_t diff_uchar(unsigned char *mem1,
return nfound;
}
}
-
+
/* -d and -p */
else if ( options->d && options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_uchar, mem1, sizeof(unsigned char));
memcpy(&temp2_uchar, mem2, sizeof(unsigned char));
-
+
PER(temp1_uchar,temp2_uchar);
if ( per > options->percent && abs(temp1_uchar-temp2_uchar) > options->delta )
{
@@ -2593,16 +2593,16 @@ hsize_t diff_uchar(unsigned char *mem1,
if (options->n && nfound>=options->count)
return nfound;
}
-
+
}
else
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_uchar, mem1, sizeof(unsigned char));
memcpy(&temp2_uchar, mem2, sizeof(unsigned char));
-
+
if (temp1_uchar != temp2_uchar)
{
if ( print_data(options) )
@@ -2613,15 +2613,15 @@ hsize_t diff_uchar(unsigned char *mem1,
}
nfound++;
}
-
+
mem1+=sizeof(unsigned char);
mem2+=sizeof(unsigned char);
if (options->n && nfound>=options->count)
return nfound;
} /* nelmts */
-
+
}
-
+
return nfound;
}
@@ -2644,24 +2644,24 @@ hsize_t diff_short(unsigned char *mem1,
const char *obj1,
const char *obj2,
int *ph)
-
+
{
hsize_t nfound=0; /* number of differences found */
short temp1_short;
short temp2_short;
hsize_t i;
float per;
-
-
+
+
/* -d and !-p */
if (options->d && !options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_short, mem1, sizeof(short));
memcpy(&temp2_short, mem2, sizeof(short));
-
+
if (abs(temp1_short-temp2_short) > options->delta)
{
if ( print_data(options) )
@@ -2677,18 +2677,18 @@ hsize_t diff_short(unsigned char *mem1,
if (options->n && nfound>=options->count)
return nfound;
}
-
+
}
-
+
/* !-d and -p */
else if (!options->d && options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_short, mem1, sizeof(short));
memcpy(&temp2_short, mem2, sizeof(short));
-
+
PER(temp1_short,temp2_short);
if ( per > options->percent )
{
@@ -2707,19 +2707,19 @@ hsize_t diff_short(unsigned char *mem1,
if (options->n && nfound>=options->count)
return nfound;
}
-
-
+
+
}
-
+
/* -d and -p */
else if ( options->d && options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_short, mem1, sizeof(short));
memcpy(&temp2_short, mem2, sizeof(short));
-
+
PER(temp1_short,temp2_short);
if ( per > options->percent && abs(temp1_short-temp2_short) > options->delta )
{
@@ -2738,16 +2738,16 @@ hsize_t diff_short(unsigned char *mem1,
if (options->n && nfound>=options->count)
return nfound;
}
-
+
}
else
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_short, mem1, sizeof(short));
memcpy(&temp2_short, mem2, sizeof(short));
-
+
if (temp1_short != temp2_short)
{
if ( print_data(options) )
@@ -2758,15 +2758,15 @@ hsize_t diff_short(unsigned char *mem1,
}
nfound++;
}
-
+
mem1+=sizeof(short);
mem2+=sizeof(short);
if (options->n && nfound>=options->count)
return nfound;
} /* nelmts */
-
+
}
-
+
return nfound;
}
@@ -2790,23 +2790,23 @@ hsize_t diff_ushort(unsigned char *mem1,
const char *obj1,
const char *obj2,
int *ph)
-
+
{
hsize_t nfound=0; /* number of differences found */
unsigned short temp1_ushort;
unsigned short temp2_ushort;
hsize_t i;
float per;
-
+
/* -d and !-p */
if (options->d && !options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_ushort, mem1, sizeof(unsigned short));
memcpy(&temp2_ushort, mem2, sizeof(unsigned short));
-
+
if (abs(temp1_ushort-temp2_ushort) > options->delta)
{
if ( print_data(options) )
@@ -2822,18 +2822,18 @@ hsize_t diff_ushort(unsigned char *mem1,
if (options->n && nfound>=options->count)
return nfound;
}
-
+
}
-
+
/* !-d and -p */
else if (!options->d && options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_ushort, mem1, sizeof(unsigned short));
memcpy(&temp2_ushort, mem2, sizeof(unsigned short));
-
+
PER(temp1_ushort,temp2_ushort);
if ( per > options->percent )
{
@@ -2852,19 +2852,19 @@ hsize_t diff_ushort(unsigned char *mem1,
if (options->n && nfound>=options->count)
return nfound;
}
-
-
+
+
}
-
+
/* -d and -p */
else if ( options->d && options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_ushort, mem1, sizeof(unsigned short));
memcpy(&temp2_ushort, mem2, sizeof(unsigned short));
-
+
PER(temp1_ushort,temp2_ushort);
if ( per > options->percent && abs(temp1_ushort-temp2_ushort) > options->delta )
{
@@ -2883,16 +2883,16 @@ hsize_t diff_ushort(unsigned char *mem1,
if (options->n && nfound>=options->count)
return nfound;
}
-
+
}
else
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_ushort, mem1, sizeof(unsigned short));
memcpy(&temp2_ushort, mem2, sizeof(unsigned short));
-
+
if (temp1_ushort != temp2_ushort)
{
if ( print_data(options) )
@@ -2903,15 +2903,15 @@ hsize_t diff_ushort(unsigned char *mem1,
}
nfound++;
}
-
+
mem1+=sizeof(unsigned short);
mem2+=sizeof(unsigned short);
if (options->n && nfound>=options->count)
return nfound;
} /* nelmts */
-
+
}
-
+
return nfound;
}
@@ -2936,23 +2936,23 @@ hsize_t diff_int(unsigned char *mem1,
const char *obj1,
const char *obj2,
int *ph)
-
+
{
hsize_t nfound=0; /* number of differences found */
int temp1_int;
int temp2_int;
hsize_t i;
float per;
-
+
/* -d and !-p */
if (options->d && !options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_int, mem1, sizeof(int));
memcpy(&temp2_int, mem2, sizeof(int));
-
+
if (abs(temp1_int-temp2_int) > options->delta)
{
if ( print_data(options) )
@@ -2968,13 +2968,13 @@ hsize_t diff_int(unsigned char *mem1,
if (options->n && nfound>=options->count)
return nfound;
}
-
+
}
-
+
/* !-d and -p */
else if (!options->d && options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_int, mem1, sizeof(int));
@@ -2998,14 +2998,14 @@ hsize_t diff_int(unsigned char *mem1,
if (options->n && nfound>=options->count)
return nfound;
}
-
-
+
+
}
-
+
/* -d and -p */
else if ( options->d && options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_int, mem1, sizeof(int));
@@ -3029,16 +3029,16 @@ hsize_t diff_int(unsigned char *mem1,
if (options->n && nfound>=options->count)
return nfound;
}
-
+
}
else
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_int, mem1, sizeof(int));
memcpy(&temp2_int, mem2, sizeof(int));
-
+
if (temp1_int != temp2_int)
{
if ( print_data(options) )
@@ -3049,15 +3049,15 @@ hsize_t diff_int(unsigned char *mem1,
}
nfound++;
}
-
+
mem1+=sizeof(int);
mem2+=sizeof(int);
if (options->n && nfound>=options->count)
return nfound;
} /* nelmts */
-
+
}
-
+
return nfound;
}
@@ -3082,23 +3082,23 @@ hsize_t diff_uint(unsigned char *mem1,
const char *obj1,
const char *obj2,
int *ph)
-
+
{
hsize_t nfound=0; /* number of differences found */
unsigned int temp1_uint;
unsigned int temp2_uint;
hsize_t i;
float per;
-
+
/* -d and !-p */
if (options->d && !options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_uint, mem1, sizeof(unsigned int));
memcpy(&temp2_uint, mem2, sizeof(unsigned int));
-
+
if (abs(temp1_uint-temp2_uint) > options->delta)
{
if ( print_data(options) )
@@ -3114,18 +3114,18 @@ hsize_t diff_uint(unsigned char *mem1,
if (options->n && nfound>=options->count)
return nfound;
}
-
+
}
-
+
/* !-d and -p */
else if (!options->d && options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_uint, mem1, sizeof(unsigned int));
memcpy(&temp2_uint, mem2, sizeof(unsigned int));
-
+
PER(temp1_uint,temp2_uint);
if ( per > options->percent )
{
@@ -3144,19 +3144,19 @@ hsize_t diff_uint(unsigned char *mem1,
if (options->n && nfound>=options->count)
return nfound;
}
-
-
+
+
}
-
+
/* -d and -p */
else if ( options->d && options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_uint, mem1, sizeof(unsigned int));
memcpy(&temp2_uint, mem2, sizeof(unsigned int));
-
+
PER(temp1_uint,temp2_uint);
if ( per > options->percent && abs(temp1_uint-temp2_uint) > options->delta )
{
@@ -3175,16 +3175,16 @@ hsize_t diff_uint(unsigned char *mem1,
if (options->n && nfound>=options->count)
return nfound;
}
-
+
}
else
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_uint, mem1, sizeof(unsigned int));
memcpy(&temp2_uint, mem2, sizeof(unsigned int));
-
+
if (temp1_uint != temp2_uint)
{
if ( print_data(options) )
@@ -3195,15 +3195,15 @@ hsize_t diff_uint(unsigned char *mem1,
}
nfound++;
}
-
+
mem1+=sizeof(unsigned int);
mem2+=sizeof(unsigned int);
if (options->n && nfound>=options->count)
return nfound;
} /* nelmts */
-
+
}
-
+
return nfound;
}
@@ -3228,7 +3228,7 @@ hsize_t diff_long(unsigned char *mem1,
const char *obj1,
const char *obj2,
int *ph)
-
+
{
hsize_t nfound=0; /* number of differences found */
long temp1_long;
@@ -3239,15 +3239,15 @@ hsize_t diff_long(unsigned char *mem1,
/* -d and !-p */
if (options->d && !options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_long, mem1, sizeof(long));
memcpy(&temp2_long, mem2, sizeof(long));
-
+
if (labs((long)(temp1_long-temp2_long)) > (long)options->delta)
{
if ( print_data(options) )
@@ -3265,11 +3265,11 @@ hsize_t diff_long(unsigned char *mem1,
}
}
}
-
+
/* !-d and -p */
else if (!options->d && options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_long, mem1, sizeof(long));
@@ -3293,19 +3293,19 @@ hsize_t diff_long(unsigned char *mem1,
if (options->n && nfound>=options->count)
return nfound;
}
-
-
+
+
}
-
+
/* -d and -p */
else if ( options->d && options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_long, mem1, sizeof(long));
memcpy(&temp2_long, mem2, sizeof(long));
-
+
PER(temp1_long,temp2_long);
if ( per > options->percent && labs(temp1_long-temp2_long) > options->delta )
{
@@ -3324,16 +3324,16 @@ hsize_t diff_long(unsigned char *mem1,
if (options->n && nfound>=options->count)
return nfound;
}
-
+
}
else
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_long, mem1, sizeof(long));
memcpy(&temp2_long, mem2, sizeof(long));
-
+
if (temp1_long != temp2_long)
{
if ( print_data(options) )
@@ -3344,15 +3344,15 @@ hsize_t diff_long(unsigned char *mem1,
}
nfound++;
}
-
+
mem1+=sizeof(long);
mem2+=sizeof(long);
if (options->n && nfound>=options->count)
return nfound;
} /* nelmts */
-
+
}
-
+
return nfound;
}
@@ -3378,27 +3378,27 @@ hsize_t diff_ulong(unsigned char *mem1,
const char *obj1,
const char *obj2,
int *ph)
-
+
{
hsize_t nfound=0; /* number of differences found */
unsigned long temp1_ulong;
unsigned long temp2_ulong;
hsize_t i;
float per;
-
-
+
+
/* -d and !-p */
if (options->d && !options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_ulong, mem1, sizeof(unsigned long));
memcpy(&temp2_ulong, mem2, sizeof(unsigned long));
-
+
if (labs((long)(temp1_ulong-temp2_ulong)) > (long)options->delta)
{
if ( print_data(options) )
@@ -3414,20 +3414,20 @@ hsize_t diff_ulong(unsigned char *mem1,
if (options->n && nfound>=options->count)
return nfound;
}
-
+
}
-
+
}
-
+
/* !-d and -p */
else if (!options->d && options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_ulong, mem1, sizeof(unsigned long));
memcpy(&temp2_ulong, mem2, sizeof(unsigned long));
-
+
PER(temp1_ulong,temp2_ulong);
if ( per > options->percent )
{
@@ -3446,19 +3446,19 @@ hsize_t diff_ulong(unsigned char *mem1,
if (options->n && nfound>=options->count)
return nfound;
}
-
-
+
+
}
-
+
/* -d and -p */
else if ( options->d && options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_ulong, mem1, sizeof(unsigned long));
memcpy(&temp2_ulong, mem2, sizeof(unsigned long));
-
+
PER(temp1_ulong,temp2_ulong);
if ( per > options->percent && labs(temp1_ulong-temp2_ulong) > options->delta )
{
@@ -3477,16 +3477,16 @@ hsize_t diff_ulong(unsigned char *mem1,
if (options->n && nfound>=options->count)
return nfound;
}
-
+
}
else
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_ulong, mem1, sizeof(unsigned long));
memcpy(&temp2_ulong, mem2, sizeof(unsigned long));
-
+
if (temp1_ulong != temp2_ulong)
{
if ( print_data(options) )
@@ -3497,15 +3497,15 @@ hsize_t diff_ulong(unsigned char *mem1,
}
nfound++;
}
-
+
mem1+=sizeof(unsigned long);
mem2+=sizeof(unsigned long);
if (options->n && nfound>=options->count)
return nfound;
} /* nelmts */
-
+
}
-
+
return nfound;
}
@@ -3530,23 +3530,23 @@ hsize_t diff_llong(unsigned char *mem1,
const char *obj1,
const char *obj2,
int *ph)
-
+
{
hsize_t nfound=0; /* number of differences found */
long_long temp1_llong;
long_long temp2_llong;
hsize_t i;
float per;
-
+
/* -d and !-p */
if (options->d && !options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_llong, mem1, sizeof(long_long));
memcpy(&temp2_llong, mem2, sizeof(long_long));
-
+
if (labs( (long) (temp1_llong-temp2_llong)) > options->delta)
{
if ( print_data(options) )
@@ -3563,18 +3563,18 @@ hsize_t diff_llong(unsigned char *mem1,
if (options->n && nfound>=options->count)
return nfound;
}
-
+
}
-
+
/* !-d and -p */
else if (!options->d && options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_llong, mem1, sizeof(long_long));
memcpy(&temp2_llong, mem2, sizeof(long_long));
-
+
PER(temp1_llong,temp2_llong);
if ( per > options->percent )
{
@@ -3593,19 +3593,19 @@ hsize_t diff_llong(unsigned char *mem1,
if (options->n && nfound>=options->count)
return nfound;
}
-
-
+
+
}
-
+
/* -d and -p */
else if ( options->d && options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_llong, mem1, sizeof(long_long));
memcpy(&temp2_llong, mem2, sizeof(long_long));
-
+
PER(temp1_llong,temp2_llong);
if ( per > options->percent && labs((long)(temp1_llong-temp2_llong)) > options->delta )
{
@@ -3624,16 +3624,16 @@ hsize_t diff_llong(unsigned char *mem1,
if (options->n && nfound>=options->count)
return nfound;
}
-
+
}
else
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_llong, mem1, sizeof(long_long));
memcpy(&temp2_llong, mem2, sizeof(long_long));
-
+
if (temp1_llong != temp2_llong)
{
if ( print_data(options) )
@@ -3645,15 +3645,15 @@ hsize_t diff_llong(unsigned char *mem1,
}
nfound++;
}
-
+
mem1+=sizeof(long_long);
mem2+=sizeof(long_long);
if (options->n && nfound>=options->count)
return nfound;
} /* nelmts */
-
+
}
-
+
return nfound;
}
@@ -3679,23 +3679,23 @@ hsize_t diff_ullong(unsigned char *mem1,
const char *obj1,
const char *obj2,
int *ph)
-
+
{
hsize_t nfound=0; /* number of differences found */
unsigned long_long temp1_ullong;
unsigned long_long temp2_ullong;
hsize_t i;
float f1, f2, per;
-
+
/* -d and !-p */
if (options->d && !options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_ullong, mem1, sizeof(unsigned long_long));
memcpy(&temp2_ullong, mem2, sizeof(unsigned long_long));
-
+
if (labs((long)(temp1_ullong-temp2_ullong)) > options->delta)
{
if ( print_data(options) )
@@ -3712,13 +3712,13 @@ hsize_t diff_ullong(unsigned char *mem1,
if (options->n && nfound>=options->count)
return nfound;
}
-
+
}
-
+
/* !-d and -p */
else if (!options->d && options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_ullong, mem1, sizeof(unsigned long_long));
@@ -3744,19 +3744,19 @@ hsize_t diff_ullong(unsigned char *mem1,
if (options->n && nfound>=options->count)
return nfound;
}
-
-
+
+
}
-
+
/* -d and -p */
else if ( options->d && options->p)
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_ullong, mem1, sizeof(unsigned long_long));
memcpy(&temp2_ullong, mem2, sizeof(unsigned long_long));
-
+
ull2float(temp1_ullong,&f1);
ull2float(temp2_ullong,&f2);
PER(f1,f2);
@@ -3777,16 +3777,16 @@ hsize_t diff_ullong(unsigned char *mem1,
if (options->n && nfound>=options->count)
return nfound;
}
-
+
}
else
{
-
+
for ( i = 0; i < nelmts; i++)
{
memcpy(&temp1_ullong, mem1, sizeof(unsigned long_long));
memcpy(&temp2_ullong, mem2, sizeof(unsigned long_long));
-
+
if (temp1_ullong != temp2_ullong)
{
if ( print_data(options) )
@@ -3798,15 +3798,15 @@ hsize_t diff_ullong(unsigned char *mem1,
}
nfound++;
}
-
+
mem1+=sizeof(unsigned long_long);
mem2+=sizeof(unsigned long_long);
if (options->n && nfound>=options->count)
return nfound;
} /* nelmts */
-
+
}
-
+
return nfound;
}
@@ -3824,40 +3824,40 @@ hsize_t diff_ullong(unsigned char *mem1,
*
*-------------------------------------------------------------------------
*/
-static
+static
int ull2float(unsigned long_long ull_value, float *f_value)
{
hid_t dxpl_id;
unsigned char *buf;
size_t src_size;
size_t dst_size;
-
- if((dxpl_id = H5Pcreate(H5P_DATASET_XFER))<0)
+
+ if((dxpl_id = H5Pcreate(H5P_DATASET_XFER))<0)
goto error;
-
+
src_size = H5Tget_size(H5T_NATIVE_ULLONG);
dst_size = H5Tget_size(H5T_NATIVE_FLOAT);
buf = (unsigned char*)calloc(1, MAX(src_size, dst_size));
-
+
memcpy(buf, &ull_value, src_size);
-
+
/* do conversion */
- if(H5Tconvert(H5T_NATIVE_ULLONG, H5T_NATIVE_FLOAT, 1, buf, NULL, dxpl_id)<0)
+ if(H5Tconvert(H5T_NATIVE_ULLONG, H5T_NATIVE_FLOAT, 1, buf, NULL, dxpl_id)<0)
goto error;
-
+
memcpy(f_value, buf, dst_size);
-
+
if(buf)
free(buf);
return 0;
-
+
error:
H5E_BEGIN_TRY {
H5Pclose(dxpl_id);
} H5E_END_TRY;
if(buf)
free(buf);
-
+
return -1;
}
diff --git a/tools/lib/h5diff_attr.c b/tools/lib/h5diff_attr.c
index 13acc28..785b345 100644
--- a/tools/lib/h5diff_attr.c
+++ b/tools/lib/h5diff_attr.c
@@ -67,21 +67,21 @@ int diff_attr(hid_t loc1_id,
int ret=0;
hsize_t nfound;
int cmp=1;
-
+
if ((n1 = H5Aget_num_attrs(loc1_id))<0)
goto error;
if ((n2 = H5Aget_num_attrs(loc2_id))<0)
goto error;
-
+
if (n1!=n2)
return 1;
-
+
for ( i = 0; i < n1; i++)
{
/* reset buffers for every attribute, we might goto out and call free */
buf1=NULL;
buf2=NULL;
-
+
/*-------------------------------------------------------------------------
* open
*-------------------------------------------------------------------------
@@ -91,13 +91,13 @@ int diff_attr(hid_t loc1_id,
goto error;
if ((attr2_id = H5Aopen_idx(loc2_id, (unsigned)i))<0)
goto error;
-
+
/* get name */
if (H5Aget_name( attr1_id, 255, name1 )<0)
goto error;
if (H5Aget_name( attr2_id, 255, name2 )<0)
goto error;
-
+
if (HDstrcmp(name1,name2)!=0)
{
if (options->m_verbose)
@@ -109,30 +109,30 @@ int diff_attr(hid_t loc1_id,
ret=1;
continue;
}
-
+
/* get the file datatype */
if ((ftype1_id = H5Aget_type( attr1_id )) < 0 )
goto error;
if ((ftype2_id = H5Aget_type( attr2_id )) < 0 )
goto error;
-
+
/* get the dataspace handle */
if ((space1_id = H5Aget_space( attr1_id )) < 0 )
goto error;
if ((space2_id = H5Aget_space( attr2_id )) < 0 )
goto error;
-
+
/* get dimensions */
if ( (rank1 = H5Sget_simple_extent_dims(space1_id, dims1, NULL)) < 0 )
goto error;
if ( (rank2 = H5Sget_simple_extent_dims(space2_id, dims2, NULL)) < 0 )
goto error;
-
+
/*-------------------------------------------------------------------------
* check for comparable TYPE and SPACE
*-------------------------------------------------------------------------
*/
-
+
if (diff_can_type(ftype1_id,
ftype2_id,
rank1,
@@ -154,7 +154,7 @@ int diff_attr(hid_t loc1_id,
*/
if (cmp)
{
-
+
/*-------------------------------------------------------------------------
* read to memory
*-------------------------------------------------------------------------
@@ -162,20 +162,20 @@ int diff_attr(hid_t loc1_id,
nelmts1=1;
for (j=0; j<rank1; j++)
nelmts1*=dims1[j];
-
+
if ((mtype1_id=h5tools_get_native_type(ftype1_id))<0)
goto error;
-
+
if ((mtype2_id=h5tools_get_native_type(ftype2_id))<0)
goto error;
-
+
if ((msize1=H5Tget_size(mtype1_id))==0)
goto error;
if ((msize2=H5Tget_size(mtype2_id))==0)
goto error;
-
+
assert(msize1==msize2);
-
+
buf1=(void *) HDmalloc((unsigned)(nelmts1*msize1));
buf2=(void *) HDmalloc((unsigned)(nelmts1*msize2));
if ( buf1==NULL || buf2==NULL){
@@ -186,16 +186,16 @@ int diff_attr(hid_t loc1_id,
goto error;
if (H5Aread(attr2_id,mtype2_id,buf2)<0)
goto error;
-
+
/* format output string */
sprintf(np1,"%s of <%s>",name1,path1);
sprintf(np2,"%s of <%s>",name2,path2);
-
+
/*-------------------------------------------------------------------------
* array compare
*-------------------------------------------------------------------------
*/
-
+
/* always print name */
if (options->m_verbose)
{
@@ -212,7 +212,7 @@ int diff_attr(hid_t loc1_id,
attr1_id,
attr2_id);
print_found(nfound);
-
+
}
/* check first if we have differences */
else
@@ -268,13 +268,13 @@ int diff_attr(hid_t loc1_id,
} /*else quiet */
} /*else verbose */
}/*cmp*/
-
+
/*-------------------------------------------------------------------------
* close
*-------------------------------------------------------------------------
*/
-
+
if (H5Tclose(ftype1_id)<0) goto error;
if (H5Tclose(ftype2_id)<0) goto error;
if (H5Tclose(mtype1_id)<0) goto error;
@@ -288,9 +288,9 @@ int diff_attr(hid_t loc1_id,
if (buf2)
HDfree(buf2);
} /* i */
-
+
return ret;
-
+
error:
H5E_BEGIN_TRY {
H5Tclose(ftype1_id);
@@ -306,7 +306,7 @@ error:
if (buf2)
HDfree(buf2);
} H5E_END_TRY;
-
+
options->err_stat=1;
return 0;
}
diff --git a/tools/lib/h5diff_dset.c b/tools/lib/h5diff_dset.c
index ad49b1a..012552f 100644
--- a/tools/lib/h5diff_dset.c
+++ b/tools/lib/h5diff_dset.c
@@ -26,11 +26,11 @@
*-------------------------------------------------------------------------
*/
#if defined (H5DIFF_DEBUG)
-void print_sizes( const char *obj1,
+void print_sizes( const char *obj1,
const char *obj2,
- hid_t f_tid1,
+ hid_t f_tid1,
hid_t f_tid2,
- hid_t m_tid1,
+ hid_t m_tid1,
hid_t m_tid2 )
{
size_t f_size1, f_size2; /* size of type in file */
@@ -300,7 +300,7 @@ hsize_t diff_datasetid( hid_t did1,
*/
if ((m_tid1=h5tools_get_native_type(f_tid1))<0)
goto error;
-
+
if ((m_tid2=h5tools_get_native_type(f_tid2))<0)
goto error;
@@ -316,7 +316,7 @@ hsize_t diff_datasetid( hid_t did1,
* check for different signed/unsigned types
*-------------------------------------------------------------------------
*/
-
+
sign1=H5Tget_sign(m_tid1);
sign2=H5Tget_sign(m_tid2);
if ( sign1 != sign2 )
@@ -325,7 +325,7 @@ hsize_t diff_datasetid( hid_t did1,
parallel_print("Comparison not supported: <%s> has sign %s ", obj1_name, get_sign(sign1));
parallel_print("and <%s> has sign %s\n", obj2_name, get_sign(sign2));
}
-
+
cmp=0;
options->not_cmp=1;
}
@@ -366,19 +366,19 @@ hsize_t diff_datasetid( hid_t did1,
if ( m_size1 < m_size2 )
{
H5Tclose(m_tid1);
-
+
if ((m_tid1=h5tools_get_native_type(f_tid2))<0)
goto error;
-
+
m_size1 = H5Tget_size( m_tid1 );
}
else
{
H5Tclose(m_tid2);
-
+
if ((m_tid2=h5tools_get_native_type(f_tid1))<0)
goto error;
-
+
m_size2 = H5Tget_size( m_tid2 );
}
#if defined (H5DIFF_DEBUG)
diff --git a/tools/lib/h5diff_util.c b/tools/lib/h5diff_util.c
index 76a3774..c2c0659 100644
--- a/tools/lib/h5diff_util.c
+++ b/tools/lib/h5diff_util.c
@@ -38,14 +38,14 @@ void parallel_print(const char* format, ...)
{
int bytes_written;
va_list ap;
-
+
va_start(ap, format);
-
+
if(!g_Parallel)
vprintf(format, ap);
else
{
-
+
if(overflow_file == NULL) /*no overflow has occurred yet */
{
#if 0
@@ -57,11 +57,11 @@ void parallel_print(const char* format, ...)
#endif
va_end(ap);
va_start(ap, format);
-
+
#if 0
printf("Result: bytes_written=%ld, OUTBUFF_SIZE-outBuffOffset=%ld\n", (long)bytes_written, (long)OUTBUFF_SIZE-outBuffOffset);
#endif
-
+
if ((bytes_written < 0) ||
#ifdef H5_VSNPRINTF_WORKS
(bytes_written >= (OUTBUFF_SIZE-outBuffOffset))
@@ -72,7 +72,7 @@ void parallel_print(const char* format, ...)
{
/* Terminate the outbuff at the end of the previous output */
outBuff[outBuffOffset] = '\0';
-
+
overflow_file = HDtmpfile();
if(overflow_file == NULL)
fprintf(stderr, "warning: could not create overflow file. Output may be truncated.\n");
@@ -84,7 +84,7 @@ void parallel_print(const char* format, ...)
}
else
bytes_written = HDvfprintf(overflow_file, format, ap);
-
+
}
va_end(ap);
}
diff --git a/tools/lib/h5tools.c b/tools/lib/h5tools.c
index a38a435..7fcfd3c 100644
--- a/tools/lib/h5tools.c
+++ b/tools/lib/h5tools.c
@@ -536,9 +536,9 @@ h5tools_simple_prefix(FILE *stream, const h5tool_format_t *info,
*
* Pedro Vicente Nunes, THG, 2005-10-19
* pass to the prefix in h5tools_simple_prefix the total position
- * instead of the current stripmine position i; this is necessary
- * to print the array indices
- * new field sm_pos in h5tools_context_t, the current stripmine element position
+ * instead of the current stripmine position i; this is necessary
+ * to print the array indices
+ * new field sm_pos in h5tools_context_t, the current stripmine element position
*-------------------------------------------------------------------------
*/
void
@@ -682,7 +682,7 @@ h5tools_dump_simple_data(FILE *stream, const h5tool_format_t *info, hid_t contai
multiline++;
/* pass to the prefix in h5tools_simple_prefix the total position
- instead of the current stripmine position i; this is necessary
+ instead of the current stripmine position i; this is necessary
to print the array indices */
curr_pos = ctx->sm_pos + i;
diff --git a/tools/misc/h5stat.c b/tools/misc/h5stat.c
index a396472..4855e68 100644
--- a/tools/misc/h5stat.c
+++ b/tools/misc/h5stat.c
@@ -100,7 +100,7 @@ static int display_dset_metadata = FALSE;
static int display_dset = FALSE;
static int display_dtype_metadata = FALSE;
static int display_dtype = FALSE;
-
+
static const char *s_opts ="FfhGgDdTV";
static struct long_options l_opts[] = {
{"help", no_arg, 'h'},
@@ -158,12 +158,12 @@ static struct long_options l_opts[] = {
{ NULL, 0, '\0' }
};
-static void
+static void
leave(int ret)
{
h5tools_close();
- exit(ret);
-}
+ exit(ret);
+}
static void usage(const char *prog)
@@ -176,9 +176,9 @@ static void
fprintf(stdout, "\n");
fprintf(stdout, "Please send your comments and questions to help@hdfgroup.org\n");
fprintf(stdout, "\n");
- fprintf(stdout, "Usage: %s [OPTIONS] file\n", prog);
+ fprintf(stdout, "Usage: %s [OPTIONS] file\n", prog);
fprintf(stdout, "\n");
- fprintf(stdout, " OPTIONS\n");
+ fprintf(stdout, " OPTIONS\n");
fprintf(stdout, " -h, --help Print a usage message and exit\n");
fprintf(stdout, " -V, --version Print version number and exit\n");
fprintf(stdout, " -f, --file Print file information\n");
@@ -190,7 +190,7 @@ static void
fprintf(stdout, " -T, --dtypemetadata Print datatype metadata\n");
fprintf(stdout, "\n");
}
-
+
/*-------------------------------------------------------------------------
* Function: ceil_log10
@@ -216,7 +216,7 @@ ceil_log10(unsigned long x)
pow10 *= 10;
ret++;
} /* end while */
-
+
return(ret);
}
@@ -573,7 +573,7 @@ printf("walk: fullname = %s\n", fullname);
/* Track the layout type for dataset */
(iter->dset_layouts[lout])++;
-
+
num_ext = H5Pget_external_count(dcpl);
assert (num_ext >= 0);
@@ -581,19 +581,19 @@ printf("walk: fullname = %s\n", fullname);
/* Track different filters */
- if ((nfltr=H5Pget_nfilters(dcpl)) >= 0) {
+ if ((nfltr=H5Pget_nfilters(dcpl)) >= 0) {
if (nfltr == 0) iter->dset_comptype[0]++;
for (u=0; u < nfltr; u++) {
fltr = H5Pget_filter(dcpl, u, 0, 0, 0, 0, 0, NULL);
- if (fltr < (H5_NFILTERS_IMPL-1))
+ if (fltr < (H5_NFILTERS_IMPL-1))
iter->dset_comptype[fltr]++;
else
iter->dset_comptype[H5_NFILTERS_IMPL-1]++; /*other filters*/
}
} /*endif nfltr */
-
+
ret = H5Pclose(dcpl);
assert(ret >= 0);
@@ -670,7 +670,7 @@ parse_start:
print_version(progname);
leave(EXIT_SUCCESS);
break;
-
+
default:
usage(progname);
leave(EXIT_FAILURE);
@@ -889,10 +889,10 @@ main(int argc, const char *argv[])
total += iter.dset_type_info[u].count;
} /* end for */
printf("\tTotal dataset datatype count: %lu\n", total);
- }
+ }
} /* end if */
} /* display dset */
-
+
H5Eset_auto_stack(H5E_DEFAULT, func, edata);
leave(d_status);