From b694ad6c877eda39822abf3af6f088ff55bfe9d7 Mon Sep 17 00:00:00 2001 From: Pedro Vicente Nunes Date: Wed, 22 Oct 2008 17:33:58 -0500 Subject: [svn-r15933] for some reason , the use of H5_PRINTF_LL_WIDTH to convert to a unsigned long long format is not working in ia64 linux (tg-login3) hardcoded the format to "%llu" tested: windows, linux (kagiso), solaris, ia64 linux (tg-login3) --- tools/lib/h5diff_array.c | 2 +- tools/lib/h5diff_dset.c | 29 ----------------------------- tools/lib/h5diff_util.c | 10 +++++++--- 3 files changed, 8 insertions(+), 33 deletions(-) diff --git a/tools/lib/h5diff_array.c b/tools/lib/h5diff_array.c index 0629c3e..9d4edc6 100644 --- a/tools/lib/h5diff_array.c +++ b/tools/lib/h5diff_array.c @@ -247,7 +247,7 @@ void print_pos( int *ph, /* print header */ parallel_print("[ " ); for ( i = 0; i < rank; i++) { - parallel_print("%"H5_PRINTF_LL_WIDTH"u ", (unsigned long_long)pos[i]); + parallel_print("%llu ", (unsigned long_long)pos[i]); } parallel_print("]" ); } diff --git a/tools/lib/h5diff_dset.c b/tools/lib/h5diff_dset.c index 84aff45..212f089 100644 --- a/tools/lib/h5diff_dset.c +++ b/tools/lib/h5diff_dset.c @@ -18,35 +18,6 @@ #include "H5private.h" #include "h5tools.h" -/*------------------------------------------------------------------------- -* Function: print_size -* -* Purpose: print dimensions -* -*------------------------------------------------------------------------- -*/ -#if defined (H5DIFF_DEBUG) -static void -print_size (int rank, hsize_t *dims) -{ - int i; - unsigned long_long dim; - - parallel_print("[" ); - for ( i = 0; i < rank-1; i++) - { - dim = dims[i]; - parallel_print("%"H5_PRINTF_LL_WIDTH"u", *((unsigned long_long *)((void *)dim)))); - parallel_print("x"); - } - dim = dims[rank-1]; - parallel_print("%"H5_PRINTF_LL_WIDTH"u", *((unsigned long_long *)((void *)dim))))); - parallel_print("]\n" ); - -} -#endif /* H5DIFF_DEBUG */ - - /*------------------------------------------------------------------------- * Function: diff_dataset diff --git a/tools/lib/h5diff_util.c b/tools/lib/h5diff_util.c index 39bd973..559c5e5 100644 --- a/tools/lib/h5diff_util.c +++ b/tools/lib/h5diff_util.c @@ -100,15 +100,19 @@ void parallel_print(const char* format, ...) void print_dimensions (int rank, hsize_t *dims) { - int i; + int i; + char fmt_ullong[8]; + sprintf(fmt_ullong, "%%llu"); + parallel_print("[" ); for ( i = 0; i < rank-1; i++) { - parallel_print("%"H5_PRINTF_LL_WIDTH"u", (unsigned long_long)dims[i]); + parallel_print(fmt_ullong, dims[i]); parallel_print("x"); } - parallel_print("%"H5_PRINTF_LL_WIDTH"u", (unsigned long_long)dims[rank-1]); + + parallel_print(fmt_ullong, dims[rank-1]); parallel_print("]" ); } -- cgit v0.12