diff options
author | Quincey Koziol <koziol@hdfgroup.org> | 2007-12-22 19:32:11 (GMT) |
---|---|---|
committer | Quincey Koziol <koziol@hdfgroup.org> | 2007-12-22 19:32:11 (GMT) |
commit | a0e70a08ba5a886bebca4ec305192693ec2f5a1d (patch) | |
tree | 887a7326b810f4cd8df8214e22abd2b5677ff235 /src/H5FD.c | |
parent | bffc42f6ac251d7a4d6b77721563ba2122fdddd6 (diff) | |
download | hdf5-a0e70a08ba5a886bebca4ec305192693ec2f5a1d.zip hdf5-a0e70a08ba5a886bebca4ec305192693ec2f5a1d.tar.gz hdf5-a0e70a08ba5a886bebca4ec305192693ec2f5a1d.tar.bz2 |
[svn-r14357] Description:
Add a hack to the local heap code to resize the metadata cache when
the heap block will be too large for the cache. This should be removed when
the metadata cache handles "too large" object insertions (or resizes) correctly.
Tested on:
FreeBSD/32 6.2 (duty) in debug mode
FreeBSD/64 6.2 (liberty) w/C++ & FORTRAN, in debug mode
Linux/32 2.6 (kagiso) w/PGI compilers, w/C++ & FORTRAN, w/threadsafe,
in debug mode
Linux/64-amd64 2.6 (smirom) w/default API=1.6.x, w/C++ & FORTRAN,
in production mode
Linux/64-ia64 2.6 (cobalt) w/Intel compilers, w/C++ & FORTRAN,
in production mode
Solaris/32 2.10 (linew) w/deprecated symbols disabled, w/C++ & FORTRAN,
w/szip filter, in production mode
Mac OS X/32 10.4.10 (amazon) in debug mode
Linux/64-ia64 2.4 (tg-login3) w/parallel, w/FORTRAN, in production mode
Diffstat (limited to 'src/H5FD.c')
-rw-r--r-- | src/H5FD.c | 19 |
1 files changed, 9 insertions, 10 deletions
@@ -1203,10 +1203,10 @@ static herr_t H5FD_free_freelist(H5FD_t *file) { H5FD_mem_t i; -#ifdef H5F_DEBUG +#ifdef H5FD_ALLOC_DEBUG unsigned nblocks = 0; hsize_t nbytes = 0; -#endif /* H5F_DEBUG */ +#endif /* H5FD_ALLOC_DEBUG */ FUNC_ENTER_NOAPI_NOINIT_NOFUNC(H5FD_free_freelist) @@ -1222,10 +1222,10 @@ H5FD_free_freelist(H5FD_t *file) H5FD_free_t *cur, *next; for( cur = file->fl[i]; cur; cur = next) { -#ifdef H5F_DEBUG +#ifdef H5FD_ALLOC_DEBUG ++nblocks; nbytes += cur->size; -#endif /* H5F_DEBUG */ +#endif /* H5FD_ALLOC_DEBUG */ next = cur->next; H5FL_FREE(H5FD_free_t, cur); } /* end for */ @@ -1233,12 +1233,11 @@ H5FD_free_freelist(H5FD_t *file) file->fl[i] = NULL; } /* end for */ -#ifdef H5F_DEBUG - if(nblocks && H5DEBUG(F)) - HDfprintf(H5DEBUG(F), - "H5F: leaked %Hu bytes of file memory in %u blocks\n", - nbytes, nblocks); -#endif /* H5F_DEBUG */ +#ifdef H5FD_ALLOC_DEBUG + if(nblocks) + HDfprintf(stderr, "%s: leaked %Hu bytes of file memory in %u blocks\n", + "H5FD_free_freelist", nbytes, nblocks); +#endif /* H5FD_ALLOC_DEBUG */ /* Check if we need to reset the metadata accumulator information */ if(file->feature_flags & H5FD_FEAT_ACCUMULATE_METADATA) { |