diff options
author | Vailin Choi <vchoi@hdfgroup.org> | 2014-11-19 00:29:26 (GMT) |
---|---|---|
committer | Vailin Choi <vchoi@hdfgroup.org> | 2014-11-19 00:29:26 (GMT) |
commit | a00ad64f468e8ea4d19c17675258694a06febe32 (patch) | |
tree | e9213dd225503dc1806dc4b326b565567f9671ef /tools | |
parent | 5a3e6cf0800219816b018baf50b7133baa73bc68 (diff) | |
download | hdf5-a00ad64f468e8ea4d19c17675258694a06febe32.zip hdf5-a00ad64f468e8ea4d19c17675258694a06febe32.tar.gz hdf5-a00ad64f468e8ea4d19c17675258694a06febe32.tar.bz2 |
[svn-r25825] Bring revisions #25509 - #25762 from trunk to revise_chunks.
h5committested.
Diffstat (limited to 'tools')
-rw-r--r-- | tools/h5copy/h5copy.c | 4 | ||||
-rw-r--r-- | tools/h5diff/CMakeTests.cmake | 7 | ||||
-rw-r--r-- | tools/h5dump/CMakeTests.cmake | 6 | ||||
-rw-r--r-- | tools/h5dump/h5dumpgentest.c | 154 | ||||
-rw-r--r-- | tools/h5repack/h5repack.c | 2 | ||||
-rw-r--r-- | tools/h5repack/h5repack_copy.c | 2 | ||||
-rw-r--r-- | tools/lib/h5diff.c | 14 | ||||
-rw-r--r-- | tools/lib/h5tools_dump.c | 8 | ||||
-rw-r--r-- | tools/lib/h5tools_ref.c | 2 | ||||
-rw-r--r-- | tools/testfiles/tbitnopaque.ddl | 293 | ||||
-rw-r--r-- | tools/testfiles/tbitnopaque.h5 | bin | 0 -> 8240 bytes |
11 files changed, 470 insertions, 22 deletions
diff --git a/tools/h5copy/h5copy.c b/tools/h5copy/h5copy.c index b5965ba..278cd3e 100644 --- a/tools/h5copy/h5copy.c +++ b/tools/h5copy/h5copy.c @@ -475,7 +475,7 @@ main (int argc, const char *argv[]) /* free link info path */ if (linkinfo.trg_path) - HDfree((char*)linkinfo.trg_path); + HDfree(linkinfo.trg_path); /* close propertis */ if(H5Pclose(ocpl_id)<0) @@ -496,7 +496,7 @@ error: /* free link info path */ if (linkinfo.trg_path) - HDfree((char*)linkinfo.trg_path); + HDfree(linkinfo.trg_path); H5E_BEGIN_TRY { H5Pclose(ocpl_id); diff --git a/tools/h5diff/CMakeTests.cmake b/tools/h5diff/CMakeTests.cmake index 686803b..c650dbe 100644 --- a/tools/h5diff/CMakeTests.cmake +++ b/tools/h5diff/CMakeTests.cmake @@ -1072,12 +1072,7 @@ ADD_H5_TEST (h5diff_80 1 -v ${FILE7} ${FILE8}) ADD_H5_TEST (h5diff_90 0 -v ${FILE2} ${FILE2}) # 10. read by hyperslab, print indexes -#if test -n "$pmode" -a "$mydomainname" = hdfgroup.uiuc.edu; then -# # skip this test which sometimes hangs in some THG machines -# message (STATUS "SKIP -v ${FILE9} ${FILE10}) -#else -# ADD_H5_TEST (h5diff_100 1 -v ${FILE9} ${FILE10}) -#fi +ADD_H5_TEST (h5diff_100 1 -v ${FILE9} ${FILE10}) # 11. floating point comparison ADD_H5_TEST (h5diff_101 1 -v ${FILE1} ${FILE1} g1/d1 g1/d2) diff --git a/tools/h5dump/CMakeTests.cmake b/tools/h5dump/CMakeTests.cmake index f9ebc32..afb482e 100644 --- a/tools/h5dump/CMakeTests.cmake +++ b/tools/h5dump/CMakeTests.cmake @@ -50,6 +50,7 @@ ${HDF5_TOOLS_SRC_DIR}/testfiles/tbin4.ddl ${HDF5_TOOLS_SRC_DIR}/testfiles/tbinregR.ddl ${HDF5_TOOLS_SRC_DIR}/testfiles/tbigdims.ddl + ${HDF5_TOOLS_SRC_DIR}/testfiles/tbitnopaque.ddl ${HDF5_TOOLS_SRC_DIR}/testfiles/tboot1.ddl ${HDF5_TOOLS_SRC_DIR}/testfiles/tboot2.ddl ${HDF5_TOOLS_SRC_DIR}/testfiles/tboot2A.ddl @@ -206,6 +207,7 @@ ${HDF5_TOOLS_SRC_DIR}/testfiles/tattrreg.h5 ${HDF5_TOOLS_SRC_DIR}/testfiles/tbigdims.h5 ${HDF5_TOOLS_SRC_DIR}/testfiles/tbinary.h5 + ${HDF5_TOOLS_SRC_DIR}/testfiles/tbitnopaque.h5 ${HDF5_TOOLS_SRC_DIR}/testfiles/tchar.h5 ${HDF5_TOOLS_SRC_DIR}/testfiles/tcmpdattrintsize.h5 ${HDF5_TOOLS_SRC_DIR}/testfiles/tcmpdintarray.h5 @@ -805,6 +807,8 @@ tbinregR.out.err tbigdims.out tbigdims.out.err + tbitnopaque.out + tbitnopaque.out.err tboot1.out tboot1.out.err tboot2.out @@ -1147,6 +1151,8 @@ ADD_H5ERR_MASK_TEST (tcomp-3 0 "--enable-error-stack;-t;/#6632;-g;/group2;tcompound.h5") # test complicated compound datatype ADD_H5_TEST (tcomp-4 0 --enable-error-stack tcompound_complex.h5) + # tests for bitfields and opaque data types + ADD_H5_TEST (tbitnopaque 0 --enable-error-stack tbitnopaque.h5) #test for the nested compound type ADD_H5_TEST (tnestcomp-1 0 --enable-error-stack tnestedcomp.h5) diff --git a/tools/h5dump/h5dumpgentest.c b/tools/h5dump/h5dumpgentest.c index bf3c97d..0857d80 100644 --- a/tools/h5dump/h5dumpgentest.c +++ b/tools/h5dump/h5dumpgentest.c @@ -110,6 +110,7 @@ #define FILE77 "tcmpdints.h5" #define FILE78 "tscalarintattrsize.h5" #define FILE79 "tintsattrs.h5" +#define FILE80 "tbitnopaque.h5" /*------------------------------------------------------------------------- * prototypes @@ -360,6 +361,8 @@ typedef struct s1_t { #define F77_DATASETNAME2 "CompoundRInts" #define F77_LENGTH 64 +#define F80_DIM32 32 + static void gent_group(void) { @@ -9667,6 +9670,156 @@ gent_intsattrs(void) H5Fclose(fid); } +static void gent_bitnopaquefields(void) +{ + /* Compound datatype */ + typedef struct s_t + { + unsigned char a; + unsigned int b; + unsigned long c; + unsigned long long d; + } s_t; + hid_t file, grp=-1, type=-1, space=-1, dset=-1; + size_t i; + hsize_t nelmts = F80_DIM32; + unsigned char buf[F80_DIM32]; /* bitfield, opaque */ + unsigned int buf2[F80_DIM32]; /* bitfield, opaque */ + unsigned long buf3[F80_DIM32]; /* bitfield, opaque */ + unsigned long long buf4[F80_DIM32]; /* bitfield, opaque */ + s_t buf5[F80_DIM32]; /* compound */ + + file = H5Fcreate(FILE80, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); + + if ((grp = H5Gcreate2(file, "bittypetests", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) >= 0) { + /* bitfield_1 */ + if ((type = H5Tcopy(H5T_STD_B8LE)) >= 0) { + if ((space = H5Screate_simple(1, &nelmts, NULL)) >= 0) { + if ((dset = H5Dcreate2(grp, "bitfield_1", type, space, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) >= 0) { + for (i = 0; i < nelmts; i++) { + buf[i] = (unsigned char)0xff ^ (unsigned char)i; + } + H5Dwrite(dset, type, H5S_ALL, H5S_ALL, H5P_DEFAULT, buf); + H5Dclose(dset); + } + H5Sclose(space); + } + H5Tclose(type); + } + + /* bitfield_2 */ + if ((type = H5Tcopy(H5T_STD_B16LE)) >= 0) { + if ((space = H5Screate_simple(1, &nelmts, NULL)) >= 0) { + if ((dset = H5Dcreate2(grp, "bitfield_2", type, space, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) >= 0) { + for (i = 0; i < nelmts; i++) { + buf2[i] = (unsigned int)0xffff ^ (unsigned int)(i * 16); + } + H5Dwrite(dset, type, H5S_ALL, H5S_ALL, H5P_DEFAULT, buf2); + H5Dclose(dset); + } + H5Sclose(space); + } + H5Tclose(type); + } + + /* bitfield_3 */ + if ((type = H5Tcopy(H5T_STD_B32LE)) >= 0) { + if ((space = H5Screate_simple(1, &nelmts, NULL)) >= 0) { + if ((dset = H5Dcreate2(grp, "bitfield_3", type, space, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) >= 0) { + for (i = 0; i < nelmts; i++) { + buf3[i] = (unsigned long)0xffffffff ^ (unsigned long)(i * 32); + } + H5Dwrite(dset, type, H5S_ALL, H5S_ALL, H5P_DEFAULT, buf3); + H5Dclose(dset); + } + H5Sclose(space); + } + H5Tclose(type); + } + + /* bitfield_4 */ + if ((type = H5Tcopy(H5T_STD_B64LE)) >= 0) { + if ((space = H5Screate_simple(1, &nelmts, NULL)) >= 0) { + if ((dset = H5Dcreate2(grp, "bitfield_4", type, space, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) >= 0) { + for (i = 0; i < nelmts; i++) { + buf4[i] = (unsigned long long)0xffffffffffffffff ^ (unsigned long long)(i * 64); + } + H5Dwrite(dset, type, H5S_ALL, H5S_ALL, H5P_DEFAULT, buf4); + H5Dclose(dset); + } + H5Sclose(space); + } + H5Tclose(type); + } + + H5Gclose(grp); + } + + if ((grp = H5Gcreate2(file, "opaquetypetests", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) >= 0) { + /* opaque_1 */ + if ((type = H5Tcreate(H5T_OPAQUE, 1)) >= 0) { + if ((H5Tset_tag(type, "1-byte opaque type")) >= 0) { + if ((space = H5Screate_simple(1, &nelmts, NULL)) >= 0) { + if ((dset = H5Dcreate2(grp, "opaque_1", type, space, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) >= 0) { + for(i = 0; i < nelmts; i++) + buf[i] = (unsigned char)0xff ^ (unsigned char)i; + H5Dwrite(dset, type, H5S_ALL, H5S_ALL, H5P_DEFAULT, buf); + H5Dclose(dset); + } + H5Sclose(space); + } + } + H5Tclose(type); + } + + /* opaque_2 */ + if ((type = H5Tcreate(H5T_OPAQUE, 2)) >= 0) { + if ((H5Tset_tag(type, "2-byte opaque type")) >= 0) { + if ((space = H5Screate_simple(1, &nelmts, NULL)) >= 0) { + if ((dset = H5Dcreate2(grp, "opaque_2", type, space, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) >= 0) { + for(i = 0; i < nelmts; i++) + buf2[i] = (unsigned int)0xffff ^ (unsigned int)(i * 16); + + H5Dwrite(dset, type, H5S_ALL, H5S_ALL, H5P_DEFAULT, buf2); + H5Dclose(dset); + } + H5Sclose(space); + } + } + H5Tclose(type); + } + H5Gclose(grp); + } + + if ((grp = H5Gcreate2(file, "cmpdtypetests", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) >= 0) { + /* compound_1 */ + if ((type = H5Tcreate(H5T_COMPOUND, sizeof(s_t))) >= 0) { + H5Tinsert(type, "a", HOFFSET(s_t, a), H5T_STD_B8LE); + H5Tinsert(type, "b", HOFFSET(s_t, b), H5T_STD_B16LE); + H5Tinsert(type, "c", HOFFSET(s_t, c), H5T_STD_B32LE); + H5Tinsert(type, "d", HOFFSET(s_t, d), H5T_STD_B64LE); + if ((space = H5Screate_simple(1, &nelmts, NULL)) >= 0) { + if ((dset = H5Dcreate2(grp, "compound_1", type, space, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) >= 0) { + for(i = 0; i < nelmts; i++) { + buf5[i].a = (unsigned char)0xff ^ (unsigned char)i; + buf5[i].b = (unsigned int)0xffff ^ (unsigned int)(i * 16); + buf5[i].c = (unsigned long)0xffffffff ^ (unsigned long)(i * 32); + buf5[i].d = (unsigned long long)0xffffffffffffffff ^ (unsigned long long)(i * 64); + } + + H5Dwrite(dset, type, H5S_ALL, H5S_ALL, H5P_DEFAULT, buf5); + H5Dclose(dset); + } + H5Sclose(space); + } + H5Tclose(type); + } + H5Gclose(grp); + } + + H5Fclose(file); +} + /*------------------------------------------------------------------------- * Function: main @@ -9758,6 +9911,7 @@ int main(void) gent_compound_ints(); gent_intattrscalars(); gent_intsattrs(); + gent_bitnopaquefields(); return 0; } diff --git a/tools/h5repack/h5repack.c b/tools/h5repack/h5repack.c index c79fea7..286d7f0 100644 --- a/tools/h5repack/h5repack.c +++ b/tools/h5repack/h5repack.c @@ -337,7 +337,7 @@ done: */ int named_datatype_free(named_dt_t **named_dt_head_p, int ignore_err) { named_dt_t *dt = *named_dt_head_p; - hid_t ret_value = -1; + int ret_value = -1; while (dt) { /* Pop the datatype off the stack and free it */ diff --git a/tools/h5repack/h5repack_copy.c b/tools/h5repack/h5repack_copy.c index 44bea47..b5f6861 100644 --- a/tools/h5repack/h5repack_copy.c +++ b/tools/h5repack/h5repack_copy.c @@ -68,7 +68,7 @@ static herr_t walk_error_callback(unsigned n, const H5E_error2_t *err_desc, void /* get the major number from the error stack. */ static herr_t walk_error_callback(UNUSED unsigned n, const H5E_error2_t *err_desc, void *udata) { if (err_desc) - *((int *) udata) = err_desc->maj_num; + *((hid_t *) udata) = err_desc->maj_num; return 0; } diff --git a/tools/lib/h5diff.c b/tools/lib/h5diff.c index 13cea23..badaf3c 100644 --- a/tools/lib/h5diff.c +++ b/tools/lib/h5diff.c @@ -549,7 +549,7 @@ static herr_t trav_grp_symlinks(const char *path, const H5L_info_t *linfo, done: if (lnk_info.trg_path) - HDfree((char *)lnk_info.trg_path); + HDfree(lnk_info.trg_path); return 0; } @@ -1064,9 +1064,9 @@ out: /* free link info buffer */ if (trg_linfo1.trg_path) - HDfree((char *)trg_linfo1.trg_path); + HDfree(trg_linfo1.trg_path); if (trg_linfo2.trg_path) - HDfree((char *)trg_linfo2.trg_path); + HDfree(trg_linfo2.trg_path); /* close */ H5E_BEGIN_TRY @@ -1905,9 +1905,9 @@ hsize_t diff(hid_t file1_id, /* free link info buffer */ if (linkinfo1.trg_path) - HDfree((char *)linkinfo1.trg_path); + HDfree(linkinfo1.trg_path); if (linkinfo2.trg_path) - HDfree((char *)linkinfo2.trg_path); + HDfree(linkinfo2.trg_path); return nfound; @@ -1948,9 +1948,9 @@ out2: /* free link info buffer */ if (linkinfo1.trg_path) - HDfree((char *)linkinfo1.trg_path); + HDfree(linkinfo1.trg_path); if (linkinfo2.trg_path) - HDfree((char *)linkinfo2.trg_path); + HDfree(linkinfo2.trg_path); /* close */ /* disable error reporting */ diff --git a/tools/lib/h5tools_dump.c b/tools/lib/h5tools_dump.c index b5c4251..3981b1e 100644 --- a/tools/lib/h5tools_dump.c +++ b/tools/lib/h5tools_dump.c @@ -1249,7 +1249,7 @@ h5tools_print_simple_subset(FILE *stream, const h5tool_format_t *info, h5tools_c H5Dvlen_reclaim(p_type, sm_space, H5P_DEFAULT, sm_buf); if(H5Sclose(sm_space) < 0) - H5E_THROW(H5E_tools_g, H5E_tools_min_id_g, "H5Sclose failed"); + H5E_THROW(FAIL, H5E_tools_min_id_g, "H5Sclose failed"); if(sm_buf) HDfree(sm_buf); sm_buf = NULL; @@ -1479,7 +1479,7 @@ h5tools_dump_simple_subset(FILE *stream, const h5tool_format_t *info, h5tools_co CATCH if(f_space >= 0 && H5Sclose(f_space) < 0) - H5E_THROW(H5E_tools_g, H5E_tools_min_id_g, "H5Sclose failed"); + H5E_THROW(FAIL, H5E_tools_min_id_g, "H5Sclose failed"); return ret_value; } @@ -1659,9 +1659,9 @@ CATCH done: if(sm_space >= 0 && H5Sclose(sm_space) < 0) - H5E_THROW(H5E_tools_g, H5E_tools_min_id_g, "H5Sclose failed"); + H5E_THROW(FAIL, H5E_tools_min_id_g, "H5Sclose failed"); if(f_space >= 0 && H5Sclose(f_space) < 0) - H5E_THROW(H5E_tools_g, H5E_tools_min_id_g, "H5Sclose failed"); + H5E_THROW(FAIL, H5E_tools_min_id_g, "H5Sclose failed"); return ret_value; } diff --git a/tools/lib/h5tools_ref.c b/tools/lib/h5tools_ref.c index caf71df..52d84f9 100644 --- a/tools/lib/h5tools_ref.c +++ b/tools/lib/h5tools_ref.c @@ -65,7 +65,7 @@ free_ref_path_info(void *item, void UNUSED *key, void UNUSED *operator_data/*in, { ref_path_node_t *node = (ref_path_node_t *)item; - HDfree((void *)node->path); + HDfree(node->path); HDfree(node); return(0); diff --git a/tools/testfiles/tbitnopaque.ddl b/tools/testfiles/tbitnopaque.ddl new file mode 100644 index 0000000..9000463 --- /dev/null +++ b/tools/testfiles/tbitnopaque.ddl @@ -0,0 +1,293 @@ +HDF5 "tbitnopaque.h5" { +GROUP "/" { + GROUP "bittypetests" { + DATASET "bitfield_1" { + DATATYPE H5T_STD_B8LE + DATASPACE SIMPLE { ( 32 ) / ( 32 ) } + DATA { + (0): 0xff, 0xfe, 0xfd, 0xfc, 0xfb, 0xfa, 0xf9, 0xf8, 0xf7, 0xf6, + (10): 0xf5, 0xf4, 0xf3, 0xf2, 0xf1, 0xf0, 0xef, 0xee, 0xed, 0xec, + (20): 0xeb, 0xea, 0xe9, 0xe8, 0xe7, 0xe6, 0xe5, 0xe4, 0xe3, 0xe2, + (30): 0xe1, 0xe0 + } + } + DATASET "bitfield_2" { + DATATYPE H5T_STD_B16LE + DATASPACE SIMPLE { ( 32 ) / ( 32 ) } + DATA { + (0): ff:ff, 00:00, ef:ff, 00:00, df:ff, 00:00, cf:ff, 00:00, bf:ff, + (9): 00:00, af:ff, 00:00, 9f:ff, 00:00, 8f:ff, 00:00, 7f:ff, 00:00, + (18): 6f:ff, 00:00, 5f:ff, 00:00, 4f:ff, 00:00, 3f:ff, 00:00, 2f:ff, + (27): 00:00, 1f:ff, 00:00, 0f:ff, 00:00 + } + } + DATASET "bitfield_3" { + DATATYPE H5T_STD_B32LE + DATASPACE SIMPLE { ( 32 ) / ( 32 ) } + DATA { + (0): ff:ff:ff:ff, 00:00:00:00, df:ff:ff:ff, 00:00:00:00, + (4): bf:ff:ff:ff, 00:00:00:00, 9f:ff:ff:ff, 00:00:00:00, + (8): 7f:ff:ff:ff, 00:00:00:00, 5f:ff:ff:ff, 00:00:00:00, + (12): 3f:ff:ff:ff, 00:00:00:00, 1f:ff:ff:ff, 00:00:00:00, + (16): ff:fe:ff:ff, 00:00:00:00, df:fe:ff:ff, 00:00:00:00, + (20): bf:fe:ff:ff, 00:00:00:00, 9f:fe:ff:ff, 00:00:00:00, + (24): 7f:fe:ff:ff, 00:00:00:00, 5f:fe:ff:ff, 00:00:00:00, + (28): 3f:fe:ff:ff, 00:00:00:00, 1f:fe:ff:ff, 00:00:00:00 + } + } + DATASET "bitfield_4" { + DATATYPE H5T_STD_B64LE + DATASPACE SIMPLE { ( 32 ) / ( 32 ) } + DATA { + (0): ff:ff:ff:ff:ff:ff:ff:ff, bf:ff:ff:ff:ff:ff:ff:ff, + (2): 7f:ff:ff:ff:ff:ff:ff:ff, 3f:ff:ff:ff:ff:ff:ff:ff, + (4): ff:fe:ff:ff:ff:ff:ff:ff, bf:fe:ff:ff:ff:ff:ff:ff, + (6): 7f:fe:ff:ff:ff:ff:ff:ff, 3f:fe:ff:ff:ff:ff:ff:ff, + (8): ff:fd:ff:ff:ff:ff:ff:ff, bf:fd:ff:ff:ff:ff:ff:ff, + (10): 7f:fd:ff:ff:ff:ff:ff:ff, 3f:fd:ff:ff:ff:ff:ff:ff, + (12): ff:fc:ff:ff:ff:ff:ff:ff, bf:fc:ff:ff:ff:ff:ff:ff, + (14): 7f:fc:ff:ff:ff:ff:ff:ff, 3f:fc:ff:ff:ff:ff:ff:ff, + (16): ff:fb:ff:ff:ff:ff:ff:ff, bf:fb:ff:ff:ff:ff:ff:ff, + (18): 7f:fb:ff:ff:ff:ff:ff:ff, 3f:fb:ff:ff:ff:ff:ff:ff, + (20): ff:fa:ff:ff:ff:ff:ff:ff, bf:fa:ff:ff:ff:ff:ff:ff, + (22): 7f:fa:ff:ff:ff:ff:ff:ff, 3f:fa:ff:ff:ff:ff:ff:ff, + (24): ff:f9:ff:ff:ff:ff:ff:ff, bf:f9:ff:ff:ff:ff:ff:ff, + (26): 7f:f9:ff:ff:ff:ff:ff:ff, 3f:f9:ff:ff:ff:ff:ff:ff, + (28): ff:f8:ff:ff:ff:ff:ff:ff, bf:f8:ff:ff:ff:ff:ff:ff, + (30): 7f:f8:ff:ff:ff:ff:ff:ff, 3f:f8:ff:ff:ff:ff:ff:ff + } + } + } + GROUP "cmpdtypetests" { + DATASET "compound_1" { + DATATYPE H5T_COMPOUND { + H5T_STD_B8LE "a"; + H5T_STD_B16LE "b"; + H5T_STD_B32LE "c"; + H5T_STD_B64LE "d"; + } + DATASPACE SIMPLE { ( 32 ) / ( 32 ) } + DATA { + (0): { + 0xff, + ff:ff, + ff:ff:ff:ff, + ff:ff:ff:ff:ff:ff:ff:ff + }, + (1): { + 0xfe, + ef:ff, + df:ff:ff:ff, + bf:ff:ff:ff:ff:ff:ff:ff + }, + (2): { + 0xfd, + df:ff, + bf:ff:ff:ff, + 7f:ff:ff:ff:ff:ff:ff:ff + }, + (3): { + 0xfc, + cf:ff, + 9f:ff:ff:ff, + 3f:ff:ff:ff:ff:ff:ff:ff + }, + (4): { + 0xfb, + bf:ff, + 7f:ff:ff:ff, + ff:fe:ff:ff:ff:ff:ff:ff + }, + (5): { + 0xfa, + af:ff, + 5f:ff:ff:ff, + bf:fe:ff:ff:ff:ff:ff:ff + }, + (6): { + 0xf9, + 9f:ff, + 3f:ff:ff:ff, + 7f:fe:ff:ff:ff:ff:ff:ff + }, + (7): { + 0xf8, + 8f:ff, + 1f:ff:ff:ff, + 3f:fe:ff:ff:ff:ff:ff:ff + }, + (8): { + 0xf7, + 7f:ff, + ff:fe:ff:ff, + ff:fd:ff:ff:ff:ff:ff:ff + }, + (9): { + 0xf6, + 6f:ff, + df:fe:ff:ff, + bf:fd:ff:ff:ff:ff:ff:ff + }, + (10): { + 0xf5, + 5f:ff, + bf:fe:ff:ff, + 7f:fd:ff:ff:ff:ff:ff:ff + }, + (11): { + 0xf4, + 4f:ff, + 9f:fe:ff:ff, + 3f:fd:ff:ff:ff:ff:ff:ff + }, + (12): { + 0xf3, + 3f:ff, + 7f:fe:ff:ff, + ff:fc:ff:ff:ff:ff:ff:ff + }, + (13): { + 0xf2, + 2f:ff, + 5f:fe:ff:ff, + bf:fc:ff:ff:ff:ff:ff:ff + }, + (14): { + 0xf1, + 1f:ff, + 3f:fe:ff:ff, + 7f:fc:ff:ff:ff:ff:ff:ff + }, + (15): { + 0xf0, + 0f:ff, + 1f:fe:ff:ff, + 3f:fc:ff:ff:ff:ff:ff:ff + }, + (16): { + 0xef, + ff:fe, + ff:fd:ff:ff, + ff:fb:ff:ff:ff:ff:ff:ff + }, + (17): { + 0xee, + ef:fe, + df:fd:ff:ff, + bf:fb:ff:ff:ff:ff:ff:ff + }, + (18): { + 0xed, + df:fe, + bf:fd:ff:ff, + 7f:fb:ff:ff:ff:ff:ff:ff + }, + (19): { + 0xec, + cf:fe, + 9f:fd:ff:ff, + 3f:fb:ff:ff:ff:ff:ff:ff + }, + (20): { + 0xeb, + bf:fe, + 7f:fd:ff:ff, + ff:fa:ff:ff:ff:ff:ff:ff + }, + (21): { + 0xea, + af:fe, + 5f:fd:ff:ff, + bf:fa:ff:ff:ff:ff:ff:ff + }, + (22): { + 0xe9, + 9f:fe, + 3f:fd:ff:ff, + 7f:fa:ff:ff:ff:ff:ff:ff + }, + (23): { + 0xe8, + 8f:fe, + 1f:fd:ff:ff, + 3f:fa:ff:ff:ff:ff:ff:ff + }, + (24): { + 0xe7, + 7f:fe, + ff:fc:ff:ff, + ff:f9:ff:ff:ff:ff:ff:ff + }, + (25): { + 0xe6, + 6f:fe, + df:fc:ff:ff, + bf:f9:ff:ff:ff:ff:ff:ff + }, + (26): { + 0xe5, + 5f:fe, + bf:fc:ff:ff, + 7f:f9:ff:ff:ff:ff:ff:ff + }, + (27): { + 0xe4, + 4f:fe, + 9f:fc:ff:ff, + 3f:f9:ff:ff:ff:ff:ff:ff + }, + (28): { + 0xe3, + 3f:fe, + 7f:fc:ff:ff, + ff:f8:ff:ff:ff:ff:ff:ff + }, + (29): { + 0xe2, + 2f:fe, + 5f:fc:ff:ff, + bf:f8:ff:ff:ff:ff:ff:ff + }, + (30): { + 0xe1, + 1f:fe, + 3f:fc:ff:ff, + 7f:f8:ff:ff:ff:ff:ff:ff + }, + (31): { + 0xe0, + 0f:fe, + 1f:fc:ff:ff, + 3f:f8:ff:ff:ff:ff:ff:ff + } + } + } + } + GROUP "opaquetypetests" { + DATASET "opaque_1" { + DATATYPE H5T_OPAQUE { + OPAQUE_TAG "1-byte opaque type"; + } + DATASPACE SIMPLE { ( 32 ) / ( 32 ) } + DATA { + (0): 0xff, 0xfe, 0xfd, 0xfc, 0xfb, 0xfa, 0xf9, 0xf8, 0xf7, 0xf6, + (10): 0xf5, 0xf4, 0xf3, 0xf2, 0xf1, 0xf0, 0xef, 0xee, 0xed, 0xec, + (20): 0xeb, 0xea, 0xe9, 0xe8, 0xe7, 0xe6, 0xe5, 0xe4, 0xe3, 0xe2, + (30): 0xe1, 0xe0 + } + } + DATASET "opaque_2" { + DATATYPE H5T_OPAQUE { + OPAQUE_TAG "2-byte opaque type"; + } + DATASPACE SIMPLE { ( 32 ) / ( 32 ) } + DATA { + (0): ff:ff, 00:00, ef:ff, 00:00, df:ff, 00:00, cf:ff, 00:00, bf:ff, + (9): 00:00, af:ff, 00:00, 9f:ff, 00:00, 8f:ff, 00:00, 7f:ff, 00:00, + (18): 6f:ff, 00:00, 5f:ff, 00:00, 4f:ff, 00:00, 3f:ff, 00:00, 2f:ff, + (27): 00:00, 1f:ff, 00:00, 0f:ff, 00:00 + } + } + } +} +} diff --git a/tools/testfiles/tbitnopaque.h5 b/tools/testfiles/tbitnopaque.h5 Binary files differnew file mode 100644 index 0000000..2b1f23d --- /dev/null +++ b/tools/testfiles/tbitnopaque.h5 |