diff options
-rw-r--r-- | tools/h5diff/h5diff_common.c | 6 | ||||
-rw-r--r-- | tools/h5dump/h5dump_ddl.c | 54 | ||||
-rw-r--r-- | tools/h5dump/h5dump_xml.c | 64 | ||||
-rw-r--r-- | tools/h5dump/h5dumpgentest.c | 4 | ||||
-rw-r--r-- | tools/h5repack/h5repack_parse.c | 4 | ||||
-rw-r--r-- | tools/lib/h5diff.c | 6 | ||||
-rw-r--r-- | tools/lib/h5diff_array.c | 272 | ||||
-rw-r--r-- | tools/lib/h5diff_util.c | 2 | ||||
-rw-r--r-- | tools/lib/h5tools_str.c | 2 |
9 files changed, 207 insertions, 207 deletions
diff --git a/tools/h5diff/h5diff_common.c b/tools/h5diff/h5diff_common.c index f7532f2..35c3956 100644 --- a/tools/h5diff/h5diff_common.c +++ b/tools/h5diff/h5diff_common.c @@ -355,7 +355,7 @@ check_n_input( const char *str ) unsigned i; char c; - for ( i = 0; i < strlen(str); i++) + for ( i = 0; i < HDstrlen(str); i++) { c = str[i]; if ( i==0 ) @@ -394,7 +394,7 @@ check_p_input( const char *str ) 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') + if (HDstrlen(str)>2 && str[0]=='0' && str[1]=='x') return -1; x=atof(str); @@ -428,7 +428,7 @@ check_d_input( const char *str ) 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') + if (HDstrlen(str)>2 && str[0]=='0' && str[1]=='x') return -1; x=atof(str); diff --git a/tools/h5dump/h5dump_ddl.c b/tools/h5dump/h5dump_ddl.c index c9e5571..f53a9d2 100644 --- a/tools/h5dump/h5dump_ddl.c +++ b/tools/h5dump/h5dump_ddl.c @@ -280,12 +280,12 @@ dump_all_cb(hid_t group, const char *name, const H5L_info_t *linfo, void UNUSED /* Render the element */ h5tools_str_reset(&buffer); - if(strlen(h5tools_dump_header_format->datasetblockend)) { + if(HDstrlen(h5tools_dump_header_format->datasetblockend)) { h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->datasetblockend); - if(strlen(h5tools_dump_header_format->datasetend)) + if(HDstrlen(h5tools_dump_header_format->datasetend)) h5tools_str_append(&buffer, " "); } - if(strlen(h5tools_dump_header_format->datasetend)) + if(HDstrlen(h5tools_dump_header_format->datasetend)) h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->datasetend); h5tools_render_element(stdout, outputformat, &ctx, &buffer, &curr_pos, outputformat->line_ncols, 0, 0); @@ -323,12 +323,12 @@ dump_all_cb(hid_t group, const char *name, const H5L_info_t *linfo, void UNUSED /* Render the element */ h5tools_str_reset(&buffer); - if(strlen(h5tools_dump_header_format->datasetblockend)) { + if(HDstrlen(h5tools_dump_header_format->datasetblockend)) { h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->datasetblockend); - if(strlen(h5tools_dump_header_format->datasetend)) + if(HDstrlen(h5tools_dump_header_format->datasetend)) h5tools_str_append(&buffer, " "); } - if(strlen(h5tools_dump_header_format->datasetend)) + if(HDstrlen(h5tools_dump_header_format->datasetend)) h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->datasetend); h5tools_render_element(stdout, outputformat, &ctx, &buffer, &curr_pos, outputformat->line_ncols, 0, 0); @@ -411,12 +411,12 @@ dump_all_cb(hid_t group, const char *name, const H5L_info_t *linfo, void UNUSED /* Render the element */ h5tools_str_reset(&buffer); - if(strlen(h5tools_dump_header_format->softlinkblockend)) { + if(HDstrlen(h5tools_dump_header_format->softlinkblockend)) { h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->softlinkblockend); - if(strlen(h5tools_dump_header_format->softlinkend)) + if(HDstrlen(h5tools_dump_header_format->softlinkend)) h5tools_str_append(&buffer, " "); } - if(strlen(h5tools_dump_header_format->softlinkend)) + if(HDstrlen(h5tools_dump_header_format->softlinkend)) h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->softlinkend); h5tools_render_element(stdout, outputformat, &ctx, &buffer, &curr_pos, outputformat->line_ncols, 0, 0); @@ -482,12 +482,12 @@ dump_all_cb(hid_t group, const char *name, const H5L_info_t *linfo, void UNUSED /* Render the element */ h5tools_str_reset(&buffer); - if(strlen(h5tools_dump_header_format->extlinkblockend)) { + if(HDstrlen(h5tools_dump_header_format->extlinkblockend)) { h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->extlinkblockend); - if(strlen(h5tools_dump_header_format->extlinkend)) + if(HDstrlen(h5tools_dump_header_format->extlinkend)) h5tools_str_append(&buffer, " "); } - if(strlen(h5tools_dump_header_format->extlinkend)) + if(HDstrlen(h5tools_dump_header_format->extlinkend)) h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->extlinkend); h5tools_render_element(stdout, outputformat, &ctx, &buffer, &curr_pos, outputformat->line_ncols, 0, 0); @@ -520,12 +520,12 @@ dump_all_cb(hid_t group, const char *name, const H5L_info_t *linfo, void UNUSED h5tools_simple_prefix(stdout, outputformat, &ctx, 0, 0); /* Render the element */ h5tools_str_reset(&buffer); - if(strlen(h5tools_dump_header_format->udlinkblockend)) { + if(HDstrlen(h5tools_dump_header_format->udlinkblockend)) { h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->udlinkblockend); - if(strlen(h5tools_dump_header_format->udlinkend)) + if(HDstrlen(h5tools_dump_header_format->udlinkend)) h5tools_str_append(&buffer, " "); } - if(strlen(h5tools_dump_header_format->udlinkend)) + if(HDstrlen(h5tools_dump_header_format->udlinkend)) h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->udlinkend); h5tools_render_element(stdout, outputformat, &ctx, &buffer, &curr_pos, outputformat->line_ncols, 0, 0); @@ -680,12 +680,12 @@ dump_named_datatype(hid_t tid, const char *name) done: /* Render the element */ h5tools_str_reset(&buffer); - if(strlen(h5tools_dump_header_format->datatypeblockend)) { + if(HDstrlen(h5tools_dump_header_format->datatypeblockend)) { h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->datatypeblockend); - if(strlen(h5tools_dump_header_format->datatypeend)) + if(HDstrlen(h5tools_dump_header_format->datatypeend)) h5tools_str_append(&buffer, " "); } - if(strlen(h5tools_dump_header_format->datatypeend)) + if(HDstrlen(h5tools_dump_header_format->datatypeend)) h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->datatypeend); h5tools_render_element(stdout, outputformat, &ctx, &buffer, &curr_pos, outputformat->line_ncols, 0, 0); @@ -886,12 +886,12 @@ dump_group(hid_t gid, const char *name) /* Render the element */ h5tools_str_reset(&buffer); - if(strlen(h5tools_dump_header_format->groupblockend)) { + if(HDstrlen(h5tools_dump_header_format->groupblockend)) { h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->groupblockend); - if(strlen(h5tools_dump_header_format->groupend)) + if(HDstrlen(h5tools_dump_header_format->groupend)) h5tools_str_append(&buffer, " "); } - if(strlen(h5tools_dump_header_format->groupend)) + if(HDstrlen(h5tools_dump_header_format->groupend)) h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->groupend); h5tools_render_element(stdout, outputformat, &ctx, &buffer, &curr_pos, outputformat->line_ncols, 0, 0); @@ -1073,12 +1073,12 @@ dump_dataset(hid_t did, const char *name, struct subset_t *sset) /* Render the element */ h5tools_str_reset(&buffer); - if(strlen(h5tools_dump_header_format->datasetblockend)) { + if(HDstrlen(h5tools_dump_header_format->datasetblockend)) { h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->datasetblockend); - if(strlen(h5tools_dump_header_format->datasetend)) + if(HDstrlen(h5tools_dump_header_format->datasetend)) h5tools_str_append(&buffer, " "); } - if(strlen(h5tools_dump_header_format->datasetend)) + if(HDstrlen(h5tools_dump_header_format->datasetend)) h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->datasetend); h5tools_render_element(stdout, outputformat, &ctx, &buffer, &curr_pos, outputformat->line_ncols, 0, 0); @@ -1395,12 +1395,12 @@ handle_attributes(hid_t fid, const char *attr, void UNUSED * data, int UNUSED pe h5tools_simple_prefix(stdout, outputformat, &ctx, 0, 0); /* Render the element */ h5tools_str_reset(&buffer); - if(strlen(h5tools_dump_header_format->attributeblockend)) { + if(HDstrlen(h5tools_dump_header_format->attributeblockend)) { h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->attributeblockend); - if(strlen(h5tools_dump_header_format->attributeend)) + if(HDstrlen(h5tools_dump_header_format->attributeend)) h5tools_str_append(&buffer, " "); } - if(strlen(h5tools_dump_header_format->attributeend)) + if(HDstrlen(h5tools_dump_header_format->attributeend)) h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->attributeend); h5tools_render_element(stdout, outputformat, &ctx, &buffer, &curr_pos, outputformat->line_ncols, 0, 0); diff --git a/tools/h5dump/h5dump_xml.c b/tools/h5dump/h5dump_xml.c index 5b6cba1..934682c 100644 --- a/tools/h5dump/h5dump_xml.c +++ b/tools/h5dump/h5dump_xml.c @@ -172,12 +172,12 @@ xml_dump_all_cb(hid_t group, const char *name, const H5L_info_t *linfo, void UNU /* Render the element */ h5tools_str_reset(&buffer); - if(strlen(h5tools_dump_header_format->datasetblockend)) { + if(HDstrlen(h5tools_dump_header_format->datasetblockend)) { h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->datasetblockend); - if(strlen(h5tools_dump_header_format->datasetend)) + if(HDstrlen(h5tools_dump_header_format->datasetend)) h5tools_str_append(&buffer, " "); } - if(strlen(h5tools_dump_header_format->datasetend)) + if(HDstrlen(h5tools_dump_header_format->datasetend)) h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->datasetend); h5tools_render_element(stdout, outputformat, &ctx, &buffer, &curr_pos, outputformat->line_ncols, 0, 0); @@ -567,24 +567,24 @@ xml_escape_the_name(const char *str) return NULL; cp = str; - len = strlen(str); + len = HDstrlen(str); extra = 0; for (i = 0; i < len; i++) { if (*cp == '\"') { - extra += (strlen(quote) - 1); + extra += (HDstrlen(quote) - 1); } else if (*cp == '\'') { - extra += (strlen(apos) - 1); + extra += (HDstrlen(apos) - 1); } else if (*cp == '<') { - extra += (strlen(lt) - 1); + extra += (HDstrlen(lt) - 1); } else if (*cp == '>') { - extra += (strlen(gt) - 1); + extra += (HDstrlen(gt) - 1); } else if (*cp == '&') { - extra += (strlen(amp) - 1); + extra += (HDstrlen(amp) - 1); } cp++; @@ -601,28 +601,28 @@ xml_escape_the_name(const char *str) for (i = 0; i < len; i++) { if (*cp == '\'') { - strncpy(ncp, apos, strlen(apos)); - ncp += strlen(apos); + strncpy(ncp, apos, HDstrlen(apos)); + ncp += HDstrlen(apos); cp++; } else if (*cp == '<') { - strncpy(ncp, lt, strlen(lt)); - ncp += strlen(lt); + strncpy(ncp, lt, HDstrlen(lt)); + ncp += HDstrlen(lt); cp++; } else if (*cp == '>') { - strncpy(ncp, gt, strlen(gt)); - ncp += strlen(gt); + strncpy(ncp, gt, HDstrlen(gt)); + ncp += HDstrlen(gt); cp++; } else if (*cp == '\"') { - strncpy(ncp, quote, strlen(quote)); - ncp += strlen(quote); + strncpy(ncp, quote, HDstrlen(quote)); + ncp += HDstrlen(quote); cp++; } else if (*cp == '&') { - strncpy(ncp, amp, strlen(amp)); - ncp += strlen(amp); + strncpy(ncp, amp, HDstrlen(amp)); + ncp += HDstrlen(amp); cp++; } else { @@ -664,7 +664,7 @@ xml_escape_the_string(const char *str, int slen) cp = str; if (slen < 0) - len = strlen(str); + len = HDstrlen(str); else len = slen; @@ -678,16 +678,16 @@ xml_escape_the_string(const char *str, int slen) extra++; } else if (*cp == '\'') { - extra += (strlen(apos) - 1); + extra += (HDstrlen(apos) - 1); } else if (*cp == '<') { - extra += (strlen(lt) - 1); + extra += (HDstrlen(lt) - 1); } else if (*cp == '>') { - extra += (strlen(gt) - 1); + extra += (HDstrlen(gt) - 1); } else if (*cp == '&') { - extra += (strlen(amp) - 1); + extra += (HDstrlen(amp) - 1); } cp++; } @@ -708,23 +708,23 @@ xml_escape_the_string(const char *str, int slen) *ncp++ = *cp++; } else if (*cp == '\'') { - strncpy(ncp, apos, strlen(apos)); - ncp += strlen(apos); + strncpy(ncp, apos, HDstrlen(apos)); + ncp += HDstrlen(apos); cp++; } else if (*cp == '<') { - strncpy(ncp, lt, strlen(lt)); - ncp += strlen(lt); + strncpy(ncp, lt, HDstrlen(lt)); + ncp += HDstrlen(lt); cp++; } else if (*cp == '>') { - strncpy(ncp, gt, strlen(gt)); - ncp += strlen(gt); + strncpy(ncp, gt, HDstrlen(gt)); + ncp += HDstrlen(gt); cp++; } else if (*cp == '&') { - strncpy(ncp, amp, strlen(amp)); - ncp += strlen(amp); + strncpy(ncp, amp, HDstrlen(amp)); + ncp += HDstrlen(amp); cp++; } else { diff --git a/tools/h5dump/h5dumpgentest.c b/tools/h5dump/h5dumpgentest.c index f87f93a..5b97434 100644 --- a/tools/h5dump/h5dumpgentest.c +++ b/tools/h5dump/h5dumpgentest.c @@ -3528,7 +3528,7 @@ void gent_split_file(void) root = H5Gopen2(fid, "/", H5P_DEFAULT); atype = H5Tcopy(H5T_C_S1); - H5Tset_size(atype, strlen(meta) + 1); + H5Tset_size(atype, HDstrlen(meta) + 1); H5Tset_strpad(atype, H5T_STR_NULLTERM); dims[0] = 1; @@ -3729,7 +3729,7 @@ static void gent_char(void) hid_t sid1; /* Dataspace ID */ hsize_t dims1[1]; - dims1[0] = strlen(wdata); + dims1[0] = HDstrlen(wdata); /* Create file */ fid1 = H5Fcreate(FILE39, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); diff --git a/tools/h5repack/h5repack_parse.c b/tools/h5repack/h5repack_parse.c index 5258c4e..6fab819 100644 --- a/tools/h5repack/h5repack_parse.c +++ b/tools/h5repack/h5repack_parse.c @@ -52,7 +52,7 @@ obj_list_t* parse_filter(const char *str, { unsigned i, u; char c; - size_t len=strlen(str); + size_t len=HDstrlen(str); int j, m, n, k, l, end_obj=-1, no_param=0; char sobj[MAX_NC_NAME]; char scomp[10]; @@ -479,7 +479,7 @@ obj_list_t* parse_layout(const char *str, obj_list_t* obj_list=NULL; unsigned i; char c; - size_t len=strlen(str); + size_t len=HDstrlen(str); int j, n, k, end_obj=-1, c_index; char sobj[MAX_NC_NAME]; char sdim[10]; diff --git a/tools/lib/h5diff.c b/tools/lib/h5diff.c index 4ffee2b..53688d9 100644 --- a/tools/lib/h5diff.c +++ b/tools/lib/h5diff.c @@ -274,7 +274,7 @@ static int is_exclude_path (char * path, h5trav_type_t type, diff_opt_t *options if (exclude_path_ptr->obj_type == H5TRAV_TYPE_GROUP) { ret_cmp = HDstrncmp(exclude_path_ptr->obj_path, path, - strlen(exclude_path_ptr->obj_path)); + HDstrlen(exclude_path_ptr->obj_path)); if (ret_cmp == 0) { /* check if given path belong to an excluding group, if so @@ -1180,12 +1180,12 @@ hsize_t diff_match(hid_t file1_id, const char *grp1, trav_info_t *info1, { objtype = table->objs[i].type; /* make full path for obj1 */ - obj1_fullpath = (char*)HDcalloc (strlen(grp1_path) + strlen (table->objs[i].name) + 1, sizeof (char)); + obj1_fullpath = (char*)HDcalloc (HDstrlen(grp1_path) + strlen (table->objs[i].name) + 1, sizeof (char)); HDstrcpy(obj1_fullpath, grp1_path); HDstrcat(obj1_fullpath, table->objs[i].name); /* make full path for obj2 */ - obj2_fullpath = (char*)HDcalloc (strlen(grp2_path) + strlen (table->objs[i].name) + 1, sizeof (char)); + obj2_fullpath = (char*)HDcalloc (HDstrlen(grp2_path) + strlen (table->objs[i].name) + 1, sizeof (char)); HDstrcpy(obj2_fullpath, grp2_path); HDstrcat(obj2_fullpath, table->objs[i].name); diff --git a/tools/lib/h5diff_array.c b/tools/lib/h5diff_array.c index 6437809..172986d 100644 --- a/tools/lib/h5diff_array.c +++ b/tools/lib/h5diff_array.c @@ -898,8 +898,8 @@ hsize_t diff_datum(void *_mem1, char temp1_char; char temp2_char; HDassert(type_size==sizeof(char)); - memcpy(&temp1_char, mem1, sizeof(char)); - memcpy(&temp2_char, mem2, sizeof(char)); + HDmemcpy(&temp1_char, mem1, sizeof(char)); + HDmemcpy(&temp2_char, mem2, sizeof(char)); /* -d and !-p */ if (options->d && !options->p) { @@ -995,8 +995,8 @@ hsize_t diff_datum(void *_mem1, unsigned char temp2_uchar; HDassert(type_size==sizeof(unsigned char)); - memcpy(&temp1_uchar, mem1, sizeof(unsigned char)); - memcpy(&temp2_uchar, mem2, sizeof(unsigned char)); + HDmemcpy(&temp1_uchar, mem1, sizeof(unsigned char)); + HDmemcpy(&temp2_uchar, mem2, sizeof(unsigned char)); /* -d and !-p */ if (options->d && !options->p) { @@ -1094,8 +1094,8 @@ hsize_t diff_datum(void *_mem1, short temp2_short; HDassert(type_size==sizeof(short)); - memcpy(&temp1_short, mem1, sizeof(short)); - memcpy(&temp2_short, mem2, sizeof(short)); + HDmemcpy(&temp1_short, mem1, sizeof(short)); + HDmemcpy(&temp2_short, mem2, sizeof(short)); /* -d and !-p */ if (options->d && !options->p) { @@ -1193,8 +1193,8 @@ hsize_t diff_datum(void *_mem1, unsigned short temp2_ushort; HDassert(type_size==sizeof(short)); - memcpy(&temp1_ushort, mem1, sizeof(unsigned short)); - memcpy(&temp2_ushort, mem2, sizeof(unsigned short)); + HDmemcpy(&temp1_ushort, mem1, sizeof(unsigned short)); + HDmemcpy(&temp2_ushort, mem2, sizeof(unsigned short)); /* -d and !-p */ if (options->d && !options->p) { @@ -1293,8 +1293,8 @@ hsize_t diff_datum(void *_mem1, int temp2_int; HDassert(type_size==sizeof(int)); - memcpy(&temp1_int, mem1, sizeof(int)); - memcpy(&temp2_int, mem2, sizeof(int)); + HDmemcpy(&temp1_int, mem1, sizeof(int)); + HDmemcpy(&temp2_int, mem2, sizeof(int)); /* -d and !-p */ if (options->d && !options->p) { @@ -1391,8 +1391,8 @@ hsize_t diff_datum(void *_mem1, unsigned int temp2_uint; HDassert(type_size==sizeof(int)); - memcpy(&temp1_uint, mem1, sizeof(unsigned int)); - memcpy(&temp2_uint, mem2, sizeof(unsigned int)); + HDmemcpy(&temp1_uint, mem1, sizeof(unsigned int)); + HDmemcpy(&temp2_uint, mem2, sizeof(unsigned int)); /* -d and !-p */ if (options->d && !options->p) { @@ -1489,8 +1489,8 @@ hsize_t diff_datum(void *_mem1, long temp2_long; HDassert(type_size==sizeof(long)); - memcpy(&temp1_long, mem1, sizeof(long)); - memcpy(&temp2_long, mem2, sizeof(long)); + HDmemcpy(&temp1_long, mem1, sizeof(long)); + HDmemcpy(&temp2_long, mem2, sizeof(long)); /* -d and !-p */ if (options->d && !options->p) { @@ -1589,8 +1589,8 @@ hsize_t diff_datum(void *_mem1, unsigned long temp2_ulong; HDassert(type_size==sizeof(unsigned long)); - memcpy(&temp1_ulong, mem1, sizeof(unsigned long)); - memcpy(&temp2_ulong, mem2, sizeof(unsigned long)); + HDmemcpy(&temp1_ulong, mem1, sizeof(unsigned long)); + HDmemcpy(&temp2_ulong, mem2, sizeof(unsigned long)); /* -d and !-p */ if (options->d && !options->p) { @@ -1688,8 +1688,8 @@ hsize_t diff_datum(void *_mem1, long long temp2_llong; HDassert(type_size==sizeof(long long)); - memcpy(&temp1_llong, mem1, sizeof(long long)); - memcpy(&temp2_llong, mem2, sizeof(long long)); + HDmemcpy(&temp1_llong, mem1, sizeof(long long)); + HDmemcpy(&temp2_llong, mem2, sizeof(long long)); /* -d and !-p */ if (options->d && !options->p) { @@ -1786,8 +1786,8 @@ hsize_t diff_datum(void *_mem1, unsigned long long temp2_ullong; HDassert(type_size==sizeof(unsigned long long)); - memcpy(&temp1_ullong, mem1, sizeof(unsigned long long)); - memcpy(&temp2_ullong, mem2, sizeof(unsigned long long)); + HDmemcpy(&temp1_ullong, mem1, sizeof(unsigned long long)); + HDmemcpy(&temp2_ullong, mem2, sizeof(unsigned long long)); /* -d and !-p */ if (options->d && !options->p) { @@ -1906,8 +1906,8 @@ hsize_t diff_datum(void *_mem1, HDassert(type_size==sizeof(float)); - memcpy(&temp1_float, mem1, sizeof(float)); - memcpy(&temp2_float, mem2, sizeof(float)); + HDmemcpy(&temp1_float, mem1, sizeof(float)); + HDmemcpy(&temp2_float, mem2, sizeof(float)); /* logic for detecting NaNs is different with options -d, -p and no options */ @@ -2119,8 +2119,8 @@ hsize_t diff_datum(void *_mem1, HDassert(type_size==sizeof(double)); - memcpy(&temp1_double, mem1, sizeof(double)); - memcpy(&temp2_double, mem2, sizeof(double)); + HDmemcpy(&temp1_double, mem1, sizeof(double)); + HDmemcpy(&temp2_double, mem2, sizeof(double)); /* logic for detecting NaNs is different with options -d, -p and no options */ @@ -2334,8 +2334,8 @@ hsize_t diff_datum(void *_mem1, HDassert(type_size==sizeof(long double)); - memcpy(&temp1_double, mem1, sizeof(long double)); - memcpy(&temp2_double, mem2, sizeof(long double)); + HDmemcpy(&temp1_double, mem1, sizeof(long double)); + HDmemcpy(&temp2_double, mem2, sizeof(long double)); /* logic for detecting NaNs is different with options -d, -p and no options */ @@ -2820,8 +2820,8 @@ hsize_t character_compare(unsigned char *mem1, unsigned char temp1_uchar; unsigned char temp2_uchar; - memcpy(&temp1_uchar, mem1, sizeof(unsigned char)); - memcpy(&temp2_uchar, mem2, sizeof(unsigned char)); + HDmemcpy(&temp1_uchar, mem1, sizeof(unsigned char)); + HDmemcpy(&temp2_uchar, mem2, sizeof(unsigned char)); if (temp1_uchar != temp2_uchar) { @@ -2869,8 +2869,8 @@ hsize_t character_compare_opt(unsigned char *mem1, double per; int both_zero; - memcpy(&temp1_uchar, mem1, sizeof(unsigned char)); - memcpy(&temp2_uchar, mem2, sizeof(unsigned char)); + HDmemcpy(&temp1_uchar, mem1, sizeof(unsigned char)); + HDmemcpy(&temp2_uchar, mem2, sizeof(unsigned char)); /* -d and !-p */ @@ -2975,8 +2975,8 @@ hsize_t diff_float(unsigned char *mem1, { for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_float, mem1, sizeof(float)); - memcpy(&temp2_float, mem2, sizeof(float)); + HDmemcpy(&temp1_float, mem1, sizeof(float)); + HDmemcpy(&temp2_float, mem2, sizeof(float)); /*------------------------------------------------------------------------- * detect NaNs @@ -3029,8 +3029,8 @@ hsize_t diff_float(unsigned char *mem1, { for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_float, mem1, sizeof(float)); - memcpy(&temp2_float, mem2, sizeof(float)); + HDmemcpy(&temp1_float, mem1, sizeof(float)); + HDmemcpy(&temp2_float, mem2, sizeof(float)); /*------------------------------------------------------------------------- * detect NaNs @@ -3102,8 +3102,8 @@ hsize_t diff_float(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_float, mem1, sizeof(float)); - memcpy(&temp2_float, mem2, sizeof(float)); + HDmemcpy(&temp1_float, mem1, sizeof(float)); + HDmemcpy(&temp2_float, mem2, sizeof(float)); /*------------------------------------------------------------------------- * detect NaNs @@ -3176,8 +3176,8 @@ hsize_t diff_float(unsigned char *mem1, { for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_float, mem1, sizeof(float)); - memcpy(&temp2_float, mem2, sizeof(float)); + HDmemcpy(&temp1_float, mem1, sizeof(float)); + HDmemcpy(&temp2_float, mem2, sizeof(float)); if (equal_float(temp1_float,temp2_float,options)==FALSE) { @@ -3248,8 +3248,8 @@ hsize_t diff_double(unsigned char *mem1, { for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_double, mem1, sizeof(double)); - memcpy(&temp2_double, mem2, sizeof(double)); + HDmemcpy(&temp1_double, mem1, sizeof(double)); + HDmemcpy(&temp2_double, mem2, sizeof(double)); /*------------------------------------------------------------------------- * detect NaNs @@ -3302,8 +3302,8 @@ hsize_t diff_double(unsigned char *mem1, { for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_double, mem1, sizeof(double)); - memcpy(&temp2_double, mem2, sizeof(double)); + HDmemcpy(&temp1_double, mem1, sizeof(double)); + HDmemcpy(&temp2_double, mem2, sizeof(double)); /*------------------------------------------------------------------------- * detect NaNs @@ -3375,8 +3375,8 @@ hsize_t diff_double(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_double, mem1, sizeof(double)); - memcpy(&temp2_double, mem2, sizeof(double)); + HDmemcpy(&temp1_double, mem1, sizeof(double)); + HDmemcpy(&temp2_double, mem2, sizeof(double)); /*------------------------------------------------------------------------- * detect NaNs @@ -3452,8 +3452,8 @@ hsize_t diff_double(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_double, mem1, sizeof(double)); - memcpy(&temp2_double, mem2, sizeof(double)); + HDmemcpy(&temp1_double, mem1, sizeof(double)); + HDmemcpy(&temp2_double, mem2, sizeof(double)); if (equal_double(temp1_double,temp2_double,options)==FALSE) @@ -3531,8 +3531,8 @@ hsize_t diff_ldouble(unsigned char *mem1, { for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_double, mem1, sizeof(long double)); - memcpy(&temp2_double, mem2, sizeof(long double)); + HDmemcpy(&temp1_double, mem1, sizeof(long double)); + HDmemcpy(&temp2_double, mem2, sizeof(long double)); /*------------------------------------------------------------------------- * detect NaNs @@ -3585,8 +3585,8 @@ hsize_t diff_ldouble(unsigned char *mem1, { for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_double, mem1, sizeof(long double)); - memcpy(&temp2_double, mem2, sizeof(long double)); + HDmemcpy(&temp1_double, mem1, sizeof(long double)); + HDmemcpy(&temp2_double, mem2, sizeof(long double)); /*------------------------------------------------------------------------- * detect NaNs @@ -3658,8 +3658,8 @@ hsize_t diff_ldouble(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_double, mem1, sizeof(long double)); - memcpy(&temp2_double, mem2, sizeof(long double)); + HDmemcpy(&temp1_double, mem1, sizeof(long double)); + HDmemcpy(&temp2_double, mem2, sizeof(long double)); /*------------------------------------------------------------------------- * detect NaNs @@ -3735,8 +3735,8 @@ hsize_t diff_ldouble(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_double, mem1, sizeof(long double)); - memcpy(&temp2_double, mem2, sizeof(long double)); + HDmemcpy(&temp1_double, mem1, sizeof(long double)); + HDmemcpy(&temp2_double, mem2, sizeof(long double)); if (equal_ldouble(temp1_double,temp2_double,options)==FALSE) @@ -3809,8 +3809,8 @@ hsize_t diff_schar(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_char, mem1, sizeof(char)); - memcpy(&temp2_char, mem2, sizeof(char)); + HDmemcpy(&temp1_char, mem1, sizeof(char)); + HDmemcpy(&temp2_char, mem2, sizeof(char)); if (ABS(temp1_char-temp2_char) > options->delta) { @@ -3835,8 +3835,8 @@ hsize_t diff_schar(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_char, mem1, sizeof(char)); - memcpy(&temp2_char, mem2, sizeof(char)); + HDmemcpy(&temp1_char, mem1, sizeof(char)); + HDmemcpy(&temp2_char, mem2, sizeof(char)); PER(temp1_char,temp2_char); @@ -3879,8 +3879,8 @@ hsize_t diff_schar(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_char, mem1, sizeof(char)); - memcpy(&temp2_char, mem2, sizeof(char)); + HDmemcpy(&temp1_char, mem1, sizeof(char)); + HDmemcpy(&temp2_char, mem2, sizeof(char)); PER(temp1_char,temp2_char); @@ -3922,8 +3922,8 @@ hsize_t diff_schar(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_char, mem1, sizeof(char)); - memcpy(&temp2_char, mem2, sizeof(char)); + HDmemcpy(&temp1_char, mem1, sizeof(char)); + HDmemcpy(&temp2_char, mem2, sizeof(char)); if (temp1_char != temp2_char) { @@ -3986,8 +3986,8 @@ hsize_t diff_uchar(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_uchar, mem1, sizeof(unsigned char)); - memcpy(&temp2_uchar, mem2, sizeof(unsigned char)); + HDmemcpy(&temp1_uchar, mem1, sizeof(unsigned char)); + HDmemcpy(&temp2_uchar, mem2, sizeof(unsigned char)); if ( PDIFF(temp1_uchar,temp2_uchar) > options->delta) { @@ -4013,8 +4013,8 @@ hsize_t diff_uchar(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_uchar, mem1, sizeof(unsigned char)); - memcpy(&temp2_uchar, mem2, sizeof(unsigned char)); + HDmemcpy(&temp1_uchar, mem1, sizeof(unsigned char)); + HDmemcpy(&temp2_uchar, mem2, sizeof(unsigned char)); PER_UNSIGN(signed char,temp1_uchar,temp2_uchar); @@ -4057,8 +4057,8 @@ hsize_t diff_uchar(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_uchar, mem1, sizeof(unsigned char)); - memcpy(&temp2_uchar, mem2, sizeof(unsigned char)); + HDmemcpy(&temp1_uchar, mem1, sizeof(unsigned char)); + HDmemcpy(&temp2_uchar, mem2, sizeof(unsigned char)); PER_UNSIGN(signed char,temp1_uchar,temp2_uchar); @@ -4100,8 +4100,8 @@ hsize_t diff_uchar(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_uchar, mem1, sizeof(unsigned char)); - memcpy(&temp2_uchar, mem2, sizeof(unsigned char)); + HDmemcpy(&temp1_uchar, mem1, sizeof(unsigned char)); + HDmemcpy(&temp2_uchar, mem2, sizeof(unsigned char)); if (temp1_uchar != temp2_uchar) { @@ -4161,8 +4161,8 @@ hsize_t diff_short(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_short, mem1, sizeof(short)); - memcpy(&temp2_short, mem2, sizeof(short)); + HDmemcpy(&temp1_short, mem1, sizeof(short)); + HDmemcpy(&temp2_short, mem2, sizeof(short)); if (ABS(temp1_short-temp2_short) > options->delta) { @@ -4188,8 +4188,8 @@ hsize_t diff_short(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_short, mem1, sizeof(short)); - memcpy(&temp2_short, mem2, sizeof(short)); + HDmemcpy(&temp1_short, mem1, sizeof(short)); + HDmemcpy(&temp2_short, mem2, sizeof(short)); PER(temp1_short,temp2_short); @@ -4234,8 +4234,8 @@ hsize_t diff_short(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_short, mem1, sizeof(short)); - memcpy(&temp2_short, mem2, sizeof(short)); + HDmemcpy(&temp1_short, mem1, sizeof(short)); + HDmemcpy(&temp2_short, mem2, sizeof(short)); PER(temp1_short,temp2_short); @@ -4277,8 +4277,8 @@ hsize_t diff_short(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_short, mem1, sizeof(short)); - memcpy(&temp2_short, mem2, sizeof(short)); + HDmemcpy(&temp1_short, mem1, sizeof(short)); + HDmemcpy(&temp2_short, mem2, sizeof(short)); if (temp1_short != temp2_short) { @@ -4339,8 +4339,8 @@ hsize_t diff_ushort(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_ushort, mem1, sizeof(unsigned short)); - memcpy(&temp2_ushort, mem2, sizeof(unsigned short)); + HDmemcpy(&temp1_ushort, mem1, sizeof(unsigned short)); + HDmemcpy(&temp2_ushort, mem2, sizeof(unsigned short)); if ( PDIFF(temp1_ushort,temp2_ushort) > options->delta) { @@ -4366,8 +4366,8 @@ hsize_t diff_ushort(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_ushort, mem1, sizeof(unsigned short)); - memcpy(&temp2_ushort, mem2, sizeof(unsigned short)); + HDmemcpy(&temp1_ushort, mem1, sizeof(unsigned short)); + HDmemcpy(&temp2_ushort, mem2, sizeof(unsigned short)); PER_UNSIGN(signed short,temp1_ushort,temp2_ushort); @@ -4412,8 +4412,8 @@ hsize_t diff_ushort(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_ushort, mem1, sizeof(unsigned short)); - memcpy(&temp2_ushort, mem2, sizeof(unsigned short)); + HDmemcpy(&temp1_ushort, mem1, sizeof(unsigned short)); + HDmemcpy(&temp2_ushort, mem2, sizeof(unsigned short)); PER_UNSIGN(signed short,temp1_ushort,temp2_ushort); @@ -4455,8 +4455,8 @@ hsize_t diff_ushort(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_ushort, mem1, sizeof(unsigned short)); - memcpy(&temp2_ushort, mem2, sizeof(unsigned short)); + HDmemcpy(&temp1_ushort, mem1, sizeof(unsigned short)); + HDmemcpy(&temp2_ushort, mem2, sizeof(unsigned short)); if (temp1_ushort != temp2_ushort) { @@ -4518,8 +4518,8 @@ hsize_t diff_int(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_int, mem1, sizeof(int)); - memcpy(&temp2_int, mem2, sizeof(int)); + HDmemcpy(&temp1_int, mem1, sizeof(int)); + HDmemcpy(&temp2_int, mem2, sizeof(int)); if (ABS(temp1_int-temp2_int) > options->delta) { @@ -4545,8 +4545,8 @@ hsize_t diff_int(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_int, mem1, sizeof(int)); - memcpy(&temp2_int, mem2, sizeof(int)); + HDmemcpy(&temp1_int, mem1, sizeof(int)); + HDmemcpy(&temp2_int, mem2, sizeof(int)); PER(temp1_int,temp2_int); @@ -4591,8 +4591,8 @@ hsize_t diff_int(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_int, mem1, sizeof(int)); - memcpy(&temp2_int, mem2, sizeof(int)); + HDmemcpy(&temp1_int, mem1, sizeof(int)); + HDmemcpy(&temp2_int, mem2, sizeof(int)); PER(temp1_int,temp2_int); @@ -4634,8 +4634,8 @@ hsize_t diff_int(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_int, mem1, sizeof(int)); - memcpy(&temp2_int, mem2, sizeof(int)); + HDmemcpy(&temp1_int, mem1, sizeof(int)); + HDmemcpy(&temp2_int, mem2, sizeof(int)); if (temp1_int != temp2_int) { @@ -4697,8 +4697,8 @@ hsize_t diff_uint(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_uint, mem1, sizeof(unsigned int)); - memcpy(&temp2_uint, mem2, sizeof(unsigned int)); + HDmemcpy(&temp1_uint, mem1, sizeof(unsigned int)); + HDmemcpy(&temp2_uint, mem2, sizeof(unsigned int)); if ( PDIFF(temp1_uint,temp2_uint) > options->delta) { @@ -4724,8 +4724,8 @@ hsize_t diff_uint(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_uint, mem1, sizeof(unsigned int)); - memcpy(&temp2_uint, mem2, sizeof(unsigned int)); + HDmemcpy(&temp1_uint, mem1, sizeof(unsigned int)); + HDmemcpy(&temp2_uint, mem2, sizeof(unsigned int)); PER_UNSIGN(signed int,temp1_uint,temp2_uint); @@ -4769,8 +4769,8 @@ hsize_t diff_uint(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_uint, mem1, sizeof(unsigned int)); - memcpy(&temp2_uint, mem2, sizeof(unsigned int)); + HDmemcpy(&temp1_uint, mem1, sizeof(unsigned int)); + HDmemcpy(&temp2_uint, mem2, sizeof(unsigned int)); PER_UNSIGN(signed int,temp1_uint,temp2_uint); @@ -4811,8 +4811,8 @@ hsize_t diff_uint(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_uint, mem1, sizeof(unsigned int)); - memcpy(&temp2_uint, mem2, sizeof(unsigned int)); + HDmemcpy(&temp1_uint, mem1, sizeof(unsigned int)); + HDmemcpy(&temp2_uint, mem2, sizeof(unsigned int)); if (temp1_uint != temp2_uint) { @@ -4877,8 +4877,8 @@ hsize_t diff_long(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_long, mem1, sizeof(long)); - memcpy(&temp2_long, mem2, sizeof(long)); + HDmemcpy(&temp1_long, mem1, sizeof(long)); + HDmemcpy(&temp2_long, mem2, sizeof(long)); if (ABS(temp1_long-temp2_long) > options->delta) { @@ -4904,8 +4904,8 @@ hsize_t diff_long(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_long, mem1, sizeof(long)); - memcpy(&temp2_long, mem2, sizeof(long)); + HDmemcpy(&temp1_long, mem1, sizeof(long)); + HDmemcpy(&temp2_long, mem2, sizeof(long)); PER(temp1_long,temp2_long); @@ -4950,8 +4950,8 @@ hsize_t diff_long(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_long, mem1, sizeof(long)); - memcpy(&temp2_long, mem2, sizeof(long)); + HDmemcpy(&temp1_long, mem1, sizeof(long)); + HDmemcpy(&temp2_long, mem2, sizeof(long)); PER(temp1_long,temp2_long); @@ -4993,8 +4993,8 @@ hsize_t diff_long(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_long, mem1, sizeof(long)); - memcpy(&temp2_long, mem2, sizeof(long)); + HDmemcpy(&temp1_long, mem1, sizeof(long)); + HDmemcpy(&temp2_long, mem2, sizeof(long)); if (temp1_long != temp2_long) { @@ -5061,8 +5061,8 @@ hsize_t diff_ulong(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_ulong, mem1, sizeof(unsigned long)); - memcpy(&temp2_ulong, mem2, sizeof(unsigned long)); + HDmemcpy(&temp1_ulong, mem1, sizeof(unsigned long)); + HDmemcpy(&temp2_ulong, mem2, sizeof(unsigned long)); if ( PDIFF(temp1_ulong,temp2_ulong) > options->delta) { @@ -5090,8 +5090,8 @@ hsize_t diff_ulong(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_ulong, mem1, sizeof(unsigned long)); - memcpy(&temp2_ulong, mem2, sizeof(unsigned long)); + HDmemcpy(&temp1_ulong, mem1, sizeof(unsigned long)); + HDmemcpy(&temp2_ulong, mem2, sizeof(unsigned long)); PER_UNSIGN(signed long,temp1_ulong,temp2_ulong); @@ -5135,8 +5135,8 @@ hsize_t diff_ulong(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_ulong, mem1, sizeof(unsigned long)); - memcpy(&temp2_ulong, mem2, sizeof(unsigned long)); + HDmemcpy(&temp1_ulong, mem1, sizeof(unsigned long)); + HDmemcpy(&temp2_ulong, mem2, sizeof(unsigned long)); PER_UNSIGN(signed long,temp1_ulong,temp2_ulong); @@ -5177,8 +5177,8 @@ hsize_t diff_ulong(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_ulong, mem1, sizeof(unsigned long)); - memcpy(&temp2_ulong, mem2, sizeof(unsigned long)); + HDmemcpy(&temp1_ulong, mem1, sizeof(unsigned long)); + HDmemcpy(&temp2_ulong, mem2, sizeof(unsigned long)); if (temp1_ulong != temp2_ulong) { @@ -5240,8 +5240,8 @@ hsize_t diff_llong(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_llong, mem1, sizeof(long long)); - memcpy(&temp2_llong, mem2, sizeof(long long)); + HDmemcpy(&temp1_llong, mem1, sizeof(long long)); + HDmemcpy(&temp2_llong, mem2, sizeof(long long)); if (ABS( temp1_llong-temp2_llong) > options->delta) { @@ -5267,8 +5267,8 @@ hsize_t diff_llong(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_llong, mem1, sizeof(long long)); - memcpy(&temp2_llong, mem2, sizeof(long long)); + HDmemcpy(&temp1_llong, mem1, sizeof(long long)); + HDmemcpy(&temp2_llong, mem2, sizeof(long long)); PER(temp1_llong,temp2_llong); @@ -5310,8 +5310,8 @@ hsize_t diff_llong(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_llong, mem1, sizeof(long long)); - memcpy(&temp2_llong, mem2, sizeof(long long)); + HDmemcpy(&temp1_llong, mem1, sizeof(long long)); + HDmemcpy(&temp2_llong, mem2, sizeof(long long)); PER(temp1_llong,temp2_llong); @@ -5350,8 +5350,8 @@ hsize_t diff_llong(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_llong, mem1, sizeof(long long)); - memcpy(&temp2_llong, mem2, sizeof(long long)); + HDmemcpy(&temp1_llong, mem1, sizeof(long long)); + HDmemcpy(&temp2_llong, mem2, sizeof(long long)); if (temp1_llong != temp2_llong) { @@ -5414,8 +5414,8 @@ hsize_t diff_ullong(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_ullong, mem1, sizeof(unsigned long long)); - memcpy(&temp2_ullong, mem2, sizeof(unsigned long long)); + HDmemcpy(&temp1_ullong, mem1, sizeof(unsigned long long)); + HDmemcpy(&temp2_ullong, mem2, sizeof(unsigned long long)); if ( PDIFF(temp1_ullong,temp2_ullong) > (unsigned long long) options->delta) { @@ -5441,8 +5441,8 @@ hsize_t diff_ullong(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_ullong, mem1, sizeof(unsigned long long)); - memcpy(&temp2_ullong, mem2, sizeof(unsigned long long)); + HDmemcpy(&temp1_ullong, mem1, sizeof(unsigned long long)); + HDmemcpy(&temp2_ullong, mem2, sizeof(unsigned long long)); ull2float(temp1_ullong,&f1); ull2float(temp2_ullong,&f2); @@ -5486,8 +5486,8 @@ hsize_t diff_ullong(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_ullong, mem1, sizeof(unsigned long long)); - memcpy(&temp2_ullong, mem2, sizeof(unsigned long long)); + HDmemcpy(&temp1_ullong, mem1, sizeof(unsigned long long)); + HDmemcpy(&temp2_ullong, mem2, sizeof(unsigned long long)); ull2float(temp1_ullong,&f1); ull2float(temp2_ullong,&f2); @@ -5528,8 +5528,8 @@ hsize_t diff_ullong(unsigned char *mem1, for ( i = 0; i < nelmts; i++) { - memcpy(&temp1_ullong, mem1, sizeof(unsigned long long)); - memcpy(&temp2_ullong, mem2, sizeof(unsigned long long)); + HDmemcpy(&temp1_ullong, mem1, sizeof(unsigned long long)); + HDmemcpy(&temp2_ullong, mem2, sizeof(unsigned long long)); if (temp1_ullong != temp2_ullong) { @@ -5582,13 +5582,13 @@ int ull2float(unsigned long long ull_value, float *f_value) dst_size = H5Tget_size(H5T_NATIVE_FLOAT); buf = (unsigned char*)calloc(1, MAX(src_size, dst_size)); - memcpy(buf, &ull_value, src_size); + HDmemcpy(buf, &ull_value, src_size); /* do conversion */ if(H5Tconvert(H5T_NATIVE_ULLONG, H5T_NATIVE_FLOAT, 1, buf, NULL, dxpl_id)<0) goto error; - memcpy(f_value, buf, dst_size); + HDmemcpy(f_value, buf, dst_size); if(buf) HDfree(buf); diff --git a/tools/lib/h5diff_util.c b/tools/lib/h5diff_util.c index dfdc8b3..0d476b6 100644 --- a/tools/lib/h5diff_util.c +++ b/tools/lib/h5diff_util.c @@ -183,7 +183,7 @@ diff_basename(const char *name) return NULL; /* Find the end of the base name */ - i = strlen(name); + i = HDstrlen(name); while (i>0 && '/'==name[i-1]) --i; diff --git a/tools/lib/h5tools_str.c b/tools/lib/h5tools_str.c index c3fbb1b..846c01b 100644 --- a/tools/lib/h5tools_str.c +++ b/tools/lib/h5tools_str.c @@ -157,7 +157,7 @@ h5tools_str_append(h5tools_str_t *str/*in,out*/, const char *fmt, ...) */ if (nchars < 0 #ifndef H5_VSNPRINTF_WORKS - && (strlen(str->s) < str->nalloc) + && (HDstrlen(str->s) < str->nalloc) #endif ) { /* failure, such as bad format */ |