From 0d501ca25b45f94284e6dc219553bb6e915710a5 Mon Sep 17 00:00:00 2001 From: Scot Breitenfeld Date: Tue, 9 Jun 2009 10:52:02 -0500 Subject: [svn-r17018] Merged changes from the trunk into the branch: svn merge -r16933:17016 https://svn.hdfgroup.uiuc.edu/hdf5/trunk Tested: smirom --- README.txt | 2 +- c++/src/Makefile.in | 2 +- config/lt_vers.am | 2 +- configure | 22 +- configure.in | 2 +- fortran/src/Makefile.in | 2 +- hl/c++/src/Makefile.in | 2 +- hl/fortran/src/Makefile.in | 2 +- hl/src/Makefile.in | 2 +- perform/sio_engine.c | 44 +-- perform/sio_perf.c | 22 +- perform/sio_timer.c | 394 ++++++++++----------- perform/sio_timer.h | 4 + release_docs/RELEASE.txt | 2 +- src/H5C.c | 12 +- src/H5Cprivate.h | 6 +- src/H5Dchunk.c | 20 +- src/H5Dint.c | 16 +- src/H5Dpkg.h | 2 - src/H5EA.c | 649 +++++++++++++++++++++------------- src/H5EApkg.h | 7 +- src/H5EAprivate.h | 7 + src/H5EAtest.c | 17 +- src/H5F.c | 1 + src/H5Fpkg.h | 1 + src/H5Fprivate.h | 3 + src/H5Fquery.c | 29 ++ src/H5Gobj.c | 12 +- src/H5O.c | 81 +++-- src/H5Opkg.h | 5 + src/H5Oprivate.h | 4 +- src/H5S.c | 73 ++-- src/H5Sprivate.h | 2 +- src/H5private.h | 5 +- src/H5public.h | 4 +- src/H5system.c | 46 +++ src/H5win32defs.h | 17 +- src/Makefile.in | 2 +- test/Makefile.in | 8 +- test/cache.c | 482 +++++++++++++------------ test/earray.c | 547 +++++++++++++++++++++++++++- tools/h5diff/testfiles/h5diff_201.txt | 2 +- tools/h5diff/testfiles/h5diff_202.txt | 2 +- tools/h5diff/testfiles/h5diff_203.txt | 2 +- tools/h5diff/testfiles/h5diff_204.txt | 2 +- tools/h5diff/testfiles/h5diff_205.txt | 2 +- tools/h5diff/testfiles/h5diff_207.txt | 2 +- tools/h5diff/testfiles/h5diff_70.txt | 2 +- tools/h5diff/testfiles/h5diff_80.txt | 6 +- tools/h5diff/testfiles/h5diff_90.txt | 4 +- tools/lib/h5diff_dset.c | 9 +- vms/src/h5pubconf.h | 6 +- windows/src/H5pubconf.h | 6 +- 53 files changed, 1735 insertions(+), 872 deletions(-) diff --git a/README.txt b/README.txt index c4cff13..81eb4b1 100644 --- a/README.txt +++ b/README.txt @@ -1,4 +1,4 @@ -HDF5 version 1.9.39 currently under development +HDF5 version 1.9.41 currently under development ==> README.txt <== Messages to be sent to the list should be sent to "@hdfgroup.org". diff --git a/c++/src/Makefile.in b/c++/src/Makefile.in index abe8590..ff429ed 100644 --- a/c++/src/Makefile.in +++ b/c++/src/Makefile.in @@ -360,7 +360,7 @@ CHECK_CLEANFILES = *.chkexe *.chklog *.clog # Add libtool shared library version numbers to the HDF5 library # See libtool versioning documentation online. LT_VERS_INTERFACE = 6 -LT_VERS_REVISION = 29 +LT_VERS_REVISION = 31 LT_VERS_AGE = 0 # Include src directory diff --git a/config/lt_vers.am b/config/lt_vers.am index c460133..38bd635 100644 --- a/config/lt_vers.am +++ b/config/lt_vers.am @@ -17,7 +17,7 @@ # Add libtool shared library version numbers to the HDF5 library # See libtool versioning documentation online. LT_VERS_INTERFACE = 6 -LT_VERS_REVISION = 29 +LT_VERS_REVISION = 31 LT_VERS_AGE = 0 ## If the API changes *at all*, increment LT_VERS_INTERFACE and diff --git a/configure b/configure index 056496a..4cc100f 100755 --- a/configure +++ b/configure @@ -1,7 +1,7 @@ #! /bin/sh -# From configure.in Id: configure.in 16875 2009-04-28 19:41:42Z brtnfld . +# From configure.in Id: configure.in 16936 2009-05-11 17:37:32Z brtnfld . # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.61 for HDF5 1.9.39. +# Generated by GNU Autoconf 2.61 for HDF5 1.9.41. # # Report bugs to . # @@ -724,8 +724,8 @@ SHELL=${CONFIG_SHELL-/bin/sh} # Identity of this package. PACKAGE_NAME='HDF5' PACKAGE_TARNAME='hdf5' -PACKAGE_VERSION='1.9.39' -PACKAGE_STRING='HDF5 1.9.39' +PACKAGE_VERSION='1.9.41' +PACKAGE_STRING='HDF5 1.9.41' PACKAGE_BUGREPORT='help@hdfgroup.org' ac_unique_file="src/H5.c" @@ -1502,7 +1502,7 @@ if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures HDF5 1.9.39 to adapt to many kinds of systems. +\`configure' configures HDF5 1.9.41 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1572,7 +1572,7 @@ fi if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of HDF5 1.9.39:";; + short | recursive ) echo "Configuration of HDF5 1.9.41:";; esac cat <<\_ACEOF @@ -1756,7 +1756,7 @@ fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -HDF5 configure 1.9.39 +HDF5 configure 1.9.41 generated by GNU Autoconf 2.61 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, @@ -1770,7 +1770,7 @@ cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by HDF5 $as_me 1.9.39, which was +It was created by HDF5 $as_me 1.9.41, which was generated by GNU Autoconf 2.61. Invocation command line was $ $0 $@ @@ -2465,7 +2465,7 @@ fi # Define the identity of the package. PACKAGE='hdf5' - VERSION='1.9.39' + VERSION='1.9.41' cat >>confdefs.h <<_ACEOF @@ -52422,7 +52422,7 @@ exec 6>&1 # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by HDF5 $as_me 1.9.39, which was +This file was extended by HDF5 $as_me 1.9.41, which was generated by GNU Autoconf 2.61. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -52475,7 +52475,7 @@ Report bugs to ." _ACEOF cat >>$CONFIG_STATUS <<_ACEOF ac_cs_version="\\ -HDF5 config.status 1.9.39 +HDF5 config.status 1.9.41 configured by $0, generated by GNU Autoconf 2.61, with options \\"`echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\" diff --git a/configure.in b/configure.in index e0e6a91..29f7eef 100644 --- a/configure.in +++ b/configure.in @@ -26,7 +26,7 @@ dnl dnl NOTE: Don't forget to change the version number here when we do a dnl release!!! dnl -AC_INIT([HDF5], [1.9.39], [help@hdfgroup.org]) +AC_INIT([HDF5], [1.9.41], [help@hdfgroup.org]) AC_CONFIG_SRCDIR([src/H5.c]) AM_CONFIG_HEADER([src/H5config.h]) diff --git a/fortran/src/Makefile.in b/fortran/src/Makefile.in index 5b80fa0..96ea60a 100644 --- a/fortran/src/Makefile.in +++ b/fortran/src/Makefile.in @@ -389,7 +389,7 @@ CHECK_CLEANFILES = *.chkexe *.chklog *.clog # Add libtool shared library version numbers to the HDF5 library # See libtool versioning documentation online. LT_VERS_INTERFACE = 6 -LT_VERS_REVISION = 29 +LT_VERS_REVISION = 31 LT_VERS_AGE = 0 # Include src directory in both Fortran and C flags (C compiler is used diff --git a/hl/c++/src/Makefile.in b/hl/c++/src/Makefile.in index 4e1cf8d..acf2071 100644 --- a/hl/c++/src/Makefile.in +++ b/hl/c++/src/Makefile.in @@ -349,7 +349,7 @@ CHECK_CLEANFILES = *.chkexe *.chklog *.clog # Add libtool shared library version numbers to the HDF5 library # See libtool versioning documentation online. LT_VERS_INTERFACE = 6 -LT_VERS_REVISION = 29 +LT_VERS_REVISION = 31 LT_VERS_AGE = 0 # Include src directory diff --git a/hl/fortran/src/Makefile.in b/hl/fortran/src/Makefile.in index 8387e66..395643a 100644 --- a/hl/fortran/src/Makefile.in +++ b/hl/fortran/src/Makefile.in @@ -354,7 +354,7 @@ CHECK_CLEANFILES = *.chkexe *.chklog *.clog # Add libtool shared library version numbers to the HDF5 library # See libtool versioning documentation online. LT_VERS_INTERFACE = 6 -LT_VERS_REVISION = 29 +LT_VERS_REVISION = 31 LT_VERS_AGE = 0 INCLUDES = -I$(top_srcdir)/src -I$(top_srcdir)/hl/src -I$(top_builddir)/hl/src \ -I$(top_srcdir)/fortran/src -I$(top_builddir)/fortran/src diff --git a/hl/src/Makefile.in b/hl/src/Makefile.in index 71ed29b..ab14d11 100644 --- a/hl/src/Makefile.in +++ b/hl/src/Makefile.in @@ -350,7 +350,7 @@ CHECK_CLEANFILES = *.chkexe *.chklog *.clog # Add libtool shared library version numbers to the HDF5 library # See libtool versioning documentation online. LT_VERS_INTERFACE = 6 -LT_VERS_REVISION = 29 +LT_VERS_REVISION = 31 LT_VERS_AGE = 0 # Add include directories to the C preprocessor flags diff --git a/perform/sio_engine.c b/perform/sio_engine.c index d4e7ad3..8e792bd 100644 --- a/perform/sio_engine.c +++ b/perform/sio_engine.c @@ -21,7 +21,9 @@ #include #include #include -#include +#ifdef H5_HAVE_UNISTD_H +# include +#endif #include #include "hdf5.h" @@ -227,7 +229,7 @@ do_sio(parameters param) */ /* Open file for write */ - strcpy(base_name, "#sio_tmp"); + HDstrcpy(base_name, "#sio_tmp"); sio_create_filename(iot, base_name, fname, sizeof(fname), ¶m); if (sio_debug_level > 0) @@ -335,7 +337,7 @@ sio_create_filename(iotype iot, const char *base_name, char *fullname, size_t si } /* First use the environment variable and then try the constant */ - prefix = getenv("HDF5_PREFIX"); + prefix = HDgetenv("HDF5_PREFIX"); #ifdef HDF5_PREFIX if (!prefix) @@ -349,8 +351,8 @@ sio_create_filename(iotype iot, const char *base_name, char *fullname, size_t si * directory instead. */ register char *user, *login, *subdir; - user = getenv("USER"); - login = getenv("LOGIN"); + user = HDgetenv("USER"); + login = HDgetenv("LOGIN"); subdir = (user ? user : login); if (subdir) { @@ -363,24 +365,24 @@ sio_create_filename(iotype iot, const char *base_name, char *fullname, size_t si fullname[i] = subdir[j]; } else { /* We didn't append the prefix yet */ - strncpy(fullname, prefix, MIN(strlen(prefix), size)); + HDstrncpy(fullname, prefix, MIN(HDstrlen(prefix), size)); } - if ((strlen(fullname) + strlen(base_name) + 1) < size) { + if ((HDstrlen(fullname) + HDstrlen(base_name) + 1) < size) { /* Append the base_name with a slash first. Multiple slashes are * handled below. */ h5_stat_t buf; if (HDstat(fullname, &buf) < 0) /* The directory doesn't exist just yet */ - if (mkdir(fullname, (mode_t)0755) < 0 && errno != EEXIST) { + if (HDmkdir(fullname, 0755) < 0 && errno != EEXIST) { /* We couldn't make the "/tmp/${USER,LOGIN}" subdirectory. * Default to PREFIX's original prefix value. */ - strcpy(fullname, prefix); + HDstrcpy(fullname, prefix); } - strcat(fullname, "/"); - strcat(fullname, base_name); + HDstrcat(fullname, "/"); + HDstrcat(fullname, base_name); } else { /* Buffer is too small */ return NULL; @@ -389,19 +391,19 @@ sio_create_filename(iotype iot, const char *base_name, char *fullname, size_t si /* Buffer is too small */ return NULL; } else { - strcpy(fullname, base_name); + HDstrcpy(fullname, base_name); } /* Append a suffix */ if (suffix) { - if (strlen(fullname) + strlen(suffix) >= size) + if (HDstrlen(fullname) + HDstrlen(suffix) >= size) return NULL; - strcat(fullname, suffix); + HDstrcat(fullname, suffix); } /* Remove any double slashes in the filename */ - for (ptr = fullname, i = j = 0; ptr && i < size; i++, ptr++) { + for (ptr = fullname, i = j = 0; ptr && (i < size); i++, ptr++) { if (*ptr != '/' || last != '/') fullname[j++] = *ptr; @@ -537,14 +539,14 @@ do_write(results *res, file_descr *fd, parameters *parms, void *buffer) h5dset_space_id, H5P_DEFAULT, h5dcpl, H5P_DEFAULT); if (h5ds_id < 0) { - fprintf(stderr, "HDF5 Dataset Create failed\n"); + HDfprintf(stderr, "HDF5 Dataset Create failed\n"); GOTOERROR(FAIL); } hrc = H5Pclose(h5dcpl); /* verifying the close of the dcpl */ if (hrc < 0) { - fprintf(stderr, "HDF5 Property List Close failed\n"); + HDfprintf(stderr, "HDF5 Property List Close failed\n"); GOTOERROR(FAIL); } @@ -841,7 +843,7 @@ do_read(results *res, file_descr *fd, parameters *parms, void *buffer) sprintf(dname, "Dataset_%ld", parms->num_bytes); h5ds_id = H5Dopen2(fd->h5fd, dname, H5P_DEFAULT); if (h5ds_id < 0) { - fprintf(stderr, "HDF5 Dataset open failed\n"); + HDfprintf(stderr, "HDF5 Dataset open failed\n"); GOTOERROR(FAIL); } @@ -1048,7 +1050,7 @@ do_fopen(parameters *param, char *fname, file_descr *fd /*out*/, int flags) fd->posixfd = POSIXOPEN(fname, O_RDONLY); if (fd->posixfd < 0 ) { - fprintf(stderr, "POSIX File Open failed(%s)\n", fname); + HDfprintf(stderr, "POSIX File Open failed(%s)\n", fname); GOTOERROR(FAIL); } @@ -1129,7 +1131,7 @@ set_vfd(parameters *param) HDmemset(memb_name, 0, sizeof memb_name); HDmemset(memb_addr, 0, sizeof memb_addr); - assert(HDstrlen(multi_letters)==H5FD_MEM_NTYPES); + HDassert(HDstrlen(multi_letters)==H5FD_MEM_NTYPES); for (mt=H5FD_MEM_DEFAULT; mtoutput_file) { - if ((output = fopen(opts->output_file, "w")) == NULL) { + if ((output = HDfopen(opts->output_file, "w")) == NULL) { fprintf(stderr, "%s: cannot open output file\n", progname); perror(opts->output_file); goto finish; @@ -918,7 +918,7 @@ report_parameters(struct options *opts) } { - char *prefix = getenv("HDF5_PREFIX"); + char *prefix = HDgetenv("HDF5_PREFIX"); HDfprintf(output, "Env HDF5_PREFIX=%s\n", (prefix ? prefix : "not set")); @@ -992,9 +992,9 @@ parse_command_line(int argc, char *argv[]) if (isalnum(*end) && i < 10) buf[i++] = *end; - if (!strcasecmp(buf, "hdf5")) { + if (!HDstrcasecmp(buf, "hdf5")) { cl_opts->io_types |= SIO_HDF5; - } else if (!strcasecmp(buf, "posix")) { + } else if (!HDstrcasecmp(buf, "posix")) { cl_opts->io_types |= SIO_POSIX; } else { fprintf(stderr, "sio_perf: invalid --api option %s\n", @@ -1145,19 +1145,19 @@ parse_command_line(int argc, char *argv[]) cl_opts->h5_threshold = parse_size_directive(opt_arg); break; case 'v': - if (!strcasecmp(opt_arg, "sec2")) { + if (!HDstrcasecmp(opt_arg, "sec2")) { cl_opts->vfd=sec2; - } else if (!strcasecmp(opt_arg, "stdio")) { + } else if (!HDstrcasecmp(opt_arg, "stdio")) { cl_opts->vfd=stdio; - } else if (!strcasecmp(opt_arg, "core")) { + } else if (!HDstrcasecmp(opt_arg, "core")) { cl_opts->vfd=core; - } else if (!strcasecmp(opt_arg, "split")) { + } else if (!HDstrcasecmp(opt_arg, "split")) { cl_opts->vfd=split; - } else if (!strcasecmp(opt_arg, "multi")) { + } else if (!HDstrcasecmp(opt_arg, "multi")) { cl_opts->vfd=multi; - } else if (!strcasecmp(opt_arg, "family")) { + } else if (!HDstrcasecmp(opt_arg, "family")) { cl_opts->vfd=family; - } else if (!strcasecmp(opt_arg, "direct")) { + } else if (!HDstrcasecmp(opt_arg, "direct")) { cl_opts->vfd=direct; } else { fprintf(stderr, "sio_perf: invalid --api option %s\n", diff --git a/perform/sio_timer.c b/perform/sio_timer.c index cce4f4b..f188a10 100644 --- a/perform/sio_timer.c +++ b/perform/sio_timer.c @@ -1,197 +1,197 @@ -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * Copyright by The HDF Group. * - * All rights reserved. * - * * - * This file is part of HDF5. The full HDF5 copyright notice, including * - * terms governing use, modification, and redistribution, is contained in * - * the files COPYING and Copyright.html. COPYING can be found at the root * - * of the source code distribution tree; Copyright.html can be found at the * - * root level of an installed copy of the electronic HDF5 document set and * - * is linked from the top-level documents page. It can also be found at * - * http://hdfgroup.org/HDF5/doc/Copyright.html. If you do not have * - * access to either file, you may request a copy from help@hdfgroup.org. * - * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ - -/* - * Purpose: - * - * This is a module of useful timing functions for performance testing. - */ - -#include -#include - -#include "sio_timer.h" - - -#include "sio_perf.h" - -/* - * The number to divide the tv_usec field with to get a nice decimal to add to - * the number of seconds. - */ -#define MICROSECOND 1000000.0 - -/* global variables */ -sio_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 - * Programmer: Leon Arber, 1/27/06 - */ -static double sub_time(struct timeval* a, struct timeval* b) -{ - return (((double)a->tv_sec + - ((double)a->tv_usec) / MICROSECOND) - - ((double)b->tv_sec + - ((double)b->tv_usec) / MICROSECOND)); -} - - -/* - * Function: sio_time_new - * Purpose: Build us a brand, spankin', new performance time object. - * The object is a black box to the user. - * Return: Pointer to sio_time object - * Programmer: Bill Wendling, 01. October 2001 - * Modifications: - */ -sio_time * -sio_time_new(void) -{ - sio_time *pt = (sio_time *)calloc(1, sizeof(struct sio_time_)); - - /* set global timer variable */ - timer_g = pt; - - return pt; -} - -/* - * Function: sio_time_destroy - * Purpose: Remove the memory allocated for the sio_time object. Only - * need to call on a pointer allocated with the ``sio_time_new'' - * function. - * Return: Nothing - * Programmer: Bill Wendling, 01. October 2001 - * Modifications: - */ -void -sio_time_destroy(sio_time *pt) -{ - free(pt); - /* reset the global timer pointer too. */ - timer_g = NULL; -} - - - -/* - * Function: set_time - * Purpose: Set the time in a ``sio_time'' object. - * Return: Pointer to the passed in ``sio_time'' object. - * Programmer: Bill Wendling, 01. October 2001 - * Modifications: - */ -sio_time * -set_time(sio_time *pt, timer_type t, int start_stop) -{ - if (pt) { - if (start_stop == START) { - gettimeofday(&pt->sys_timer[t], NULL); - - /* When we start the timer for HDF5_FINE_WRITE_FIXED_DIMS or HDF5_FINE_READ_FIXED_DIMS - * we compute the time it took to only open the file */ - if(t == HDF5_FINE_WRITE_FIXED_DIMS) - pt->total_time[HDF5_FILE_WRITE_OPEN] += sub_time(&(pt->sys_timer[t]), &(pt->sys_timer[HDF5_GROSS_WRITE_FIXED_DIMS])); - 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; - - gettimeofday(&sys_t, NULL); - pt->total_time[t] += sub_time(&sys_t, &(pt->sys_timer[t])); - -/* ((double)sys_t.tv_sec + - ((double)sys_t.tv_usec) / MICROSECOND) - - ((double)pt->sys_timer[t].tv_sec + - ((double)pt->sys_timer[t].tv_usec) / MICROSECOND);*/ - - /* 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 */ - if(t == HDF5_GROSS_WRITE_FIXED_DIMS) - 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])); - - } - - if (sio_debug_level >= 4) { - const char *msg; - - switch (t) { - case HDF5_FILE_OPENCLOSE: - msg = "File Open/Close"; - break; - case HDF5_DATASET_CREATE: - msg = "Dataset Create"; - break; - case HDF5_MPI_WRITE: - msg = "MPI Write"; - break; - case HDF5_MPI_READ: - msg = "MPI Read"; - break; - case HDF5_FINE_WRITE_FIXED_DIMS: - msg = "Fine Write"; - break; - case HDF5_FINE_READ_FIXED_DIMS: - msg = "Fine Read"; - break; - case HDF5_GROSS_WRITE_FIXED_DIMS: - msg = "Gross Write"; - break; - case HDF5_GROSS_READ_FIXED_DIMS: - msg = "Gross Read"; - break; - case HDF5_RAW_WRITE_FIXED_DIMS: - msg = "Raw Write"; - break; - case HDF5_RAW_READ_FIXED_DIMS: - msg = "Raw Read"; - break; - default: - msg = "Unknown Timer"; - break; - } - - fprintf(output, " %s %s: %.2f\n", msg, - (start_stop == START ? "Start" : "Stop"), - pt->total_time[t]); - } - } - - return pt; -} - -/* - * Function: get_time - * Purpose: Get the time from a ``sio_time'' object. - * Return: The number of seconds as a DOUBLE. - * Programmer: Bill Wendling, 01. October 2001 - * Modifications: - */ -double -get_time(sio_time *pt, timer_type t) -{ - return pt->total_time[t]; -} -#ifdef STANDALONE -#include "sio_standalone.c" -#endif - +/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * + * Copyright by The HDF Group. * + * All rights reserved. * + * * + * This file is part of HDF5. The full HDF5 copyright notice, including * + * terms governing use, modification, and redistribution, is contained in * + * the files COPYING and Copyright.html. COPYING can be found at the root * + * of the source code distribution tree; Copyright.html can be found at the * + * root level of an installed copy of the electronic HDF5 document set and * + * is linked from the top-level documents page. It can also be found at * + * http://hdfgroup.org/HDF5/doc/Copyright.html. If you do not have * + * access to either file, you may request a copy from help@hdfgroup.org. * + * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ + +/* + * Purpose: + * + * This is a module of useful timing functions for performance testing. + */ + +#include +#include + +#include "sio_timer.h" + + +#include "sio_perf.h" + +/* + * The number to divide the tv_usec field with to get a nice decimal to add to + * the number of seconds. + */ +#define MICROSECOND 1000000.0 + +/* global variables */ +sio_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 + * Programmer: Leon Arber, 1/27/06 + */ +static double sub_time(struct timeval* a, struct timeval* b) +{ + return (((double)a->tv_sec + + ((double)a->tv_usec) / MICROSECOND) - + ((double)b->tv_sec + + ((double)b->tv_usec) / MICROSECOND)); +} + + +/* + * Function: sio_time_new + * Purpose: Build us a brand, spankin', new performance time object. + * The object is a black box to the user. + * Return: Pointer to sio_time object + * Programmer: Bill Wendling, 01. October 2001 + * Modifications: + */ +sio_time * +sio_time_new(void) +{ + sio_time *pt = (sio_time *)calloc(1, sizeof(struct sio_time_)); + + /* set global timer variable */ + timer_g = pt; + + return pt; +} + +/* + * Function: sio_time_destroy + * Purpose: Remove the memory allocated for the sio_time object. Only + * need to call on a pointer allocated with the ``sio_time_new'' + * function. + * Return: Nothing + * Programmer: Bill Wendling, 01. October 2001 + * Modifications: + */ +void +sio_time_destroy(sio_time *pt) +{ + free(pt); + /* reset the global timer pointer too. */ + timer_g = NULL; +} + + + +/* + * Function: set_time + * Purpose: Set the time in a ``sio_time'' object. + * Return: Pointer to the passed in ``sio_time'' object. + * Programmer: Bill Wendling, 01. October 2001 + * Modifications: + */ +sio_time * +set_time(sio_time *pt, timer_type t, int start_stop) +{ + if (pt) { + if (start_stop == START) { + HDgettimeofday(&pt->sys_timer[t], NULL); + + /* When we start the timer for HDF5_FINE_WRITE_FIXED_DIMS or HDF5_FINE_READ_FIXED_DIMS + * we compute the time it took to only open the file */ + if(t == HDF5_FINE_WRITE_FIXED_DIMS) + pt->total_time[HDF5_FILE_WRITE_OPEN] += sub_time(&(pt->sys_timer[t]), &(pt->sys_timer[HDF5_GROSS_WRITE_FIXED_DIMS])); + 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; + + HDgettimeofday(&sys_t, NULL); + pt->total_time[t] += sub_time(&sys_t, &(pt->sys_timer[t])); + +/* ((double)sys_t.tv_sec + + ((double)sys_t.tv_usec) / MICROSECOND) - + ((double)pt->sys_timer[t].tv_sec + + ((double)pt->sys_timer[t].tv_usec) / MICROSECOND);*/ + + /* 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 */ + if(t == HDF5_GROSS_WRITE_FIXED_DIMS) + 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])); + + } + + if (sio_debug_level >= 4) { + const char *msg; + + switch (t) { + case HDF5_FILE_OPENCLOSE: + msg = "File Open/Close"; + break; + case HDF5_DATASET_CREATE: + msg = "Dataset Create"; + break; + case HDF5_MPI_WRITE: + msg = "MPI Write"; + break; + case HDF5_MPI_READ: + msg = "MPI Read"; + break; + case HDF5_FINE_WRITE_FIXED_DIMS: + msg = "Fine Write"; + break; + case HDF5_FINE_READ_FIXED_DIMS: + msg = "Fine Read"; + break; + case HDF5_GROSS_WRITE_FIXED_DIMS: + msg = "Gross Write"; + break; + case HDF5_GROSS_READ_FIXED_DIMS: + msg = "Gross Read"; + break; + case HDF5_RAW_WRITE_FIXED_DIMS: + msg = "Raw Write"; + break; + case HDF5_RAW_READ_FIXED_DIMS: + msg = "Raw Read"; + break; + default: + msg = "Unknown Timer"; + break; + } + + fprintf(output, " %s %s: %.2f\n", msg, + (start_stop == START ? "Start" : "Stop"), + pt->total_time[t]); + } + } + + return pt; +} + +/* + * Function: get_time + * Purpose: Get the time from a ``sio_time'' object. + * Return: The number of seconds as a DOUBLE. + * Programmer: Bill Wendling, 01. October 2001 + * Modifications: + */ +double +get_time(sio_time *pt, timer_type t) +{ + return pt->total_time[t]; +} +#ifdef STANDALONE +#include "sio_standalone.c" +#endif + diff --git a/perform/sio_timer.h b/perform/sio_timer.h index 445a02e..943ce28 100644 --- a/perform/sio_timer.h +++ b/perform/sio_timer.h @@ -26,6 +26,10 @@ # include #endif +#ifdef _WIN32 +# include +#endif /* _WIN32 */ + /* The different types of timers we can have */ typedef enum timer_type_ { HDF5_FILE_OPENCLOSE, diff --git a/release_docs/RELEASE.txt b/release_docs/RELEASE.txt index ca818d5..d7be4ea 100644 --- a/release_docs/RELEASE.txt +++ b/release_docs/RELEASE.txt @@ -1,4 +1,4 @@ -HDF5 version 1.9.39 currently under development +HDF5 version 1.9.41 currently under development ================================================================================ diff --git a/src/H5C.c b/src/H5C.c index 8c67f10..03a77a3 100644 --- a/src/H5C.c +++ b/src/H5C.c @@ -2048,6 +2048,7 @@ if ( (cache_ptr)->index_size != \ (cache_ptr)->pel_tail_ptr, \ (cache_ptr)->pel_len, \ (cache_ptr)->pel_size, (fail_val)) \ + HDassert( (cache_ptr)->pel_len >= 0 ); \ \ } else { \ \ @@ -2110,6 +2111,7 @@ if ( (cache_ptr)->index_size != \ (cache_ptr)->pel_tail_ptr, \ (cache_ptr)->pel_len, \ (cache_ptr)->pel_size, (fail_val)) \ + HDassert( (cache_ptr)->pel_len >= 0 ); \ \ } else { \ \ @@ -2475,6 +2477,7 @@ if ( (cache_ptr)->index_size != \ H5C__DLL_REMOVE((entry_ptr), (cache_ptr)->pel_head_ptr, \ (cache_ptr)->pel_tail_ptr, (cache_ptr)->pel_len, \ (cache_ptr)->pel_size, (fail_val)) \ + HDassert( (cache_ptr)->pel_len >= 0 ); \ \ /* modified LRU specific code */ \ \ @@ -2527,6 +2530,7 @@ if ( (cache_ptr)->index_size != \ H5C__DLL_REMOVE((entry_ptr), (cache_ptr)->pel_head_ptr, \ (cache_ptr)->pel_tail_ptr, (cache_ptr)->pel_len, \ (cache_ptr)->pel_size, (fail_val)) \ + HDassert( (cache_ptr)->pel_len >= 0 ); \ \ /* modified LRU specific code */ \ \ @@ -7778,12 +7782,12 @@ H5C_unpin_entry_from_client(H5C_t * cache_ptr, if(!entry_ptr->pinned_from_client) HGOTO_ERROR(H5E_CACHE, H5E_CANTUNPIN, FAIL, "Entry wasn't pinned by cache client") - /* If requested, update the replacement policy if the entry is not protected */ - if(update_rp && !entry_ptr->is_protected) - H5C__UPDATE_RP_FOR_UNPIN(cache_ptr, entry_ptr, FAIL) - /* Check if the entry is not pinned from a flush dependency */ if(!entry_ptr->pinned_from_cache) { + /* If requested, update the replacement policy if the entry is not protected */ + if(update_rp && !entry_ptr->is_protected) + H5C__UPDATE_RP_FOR_UNPIN(cache_ptr, entry_ptr, FAIL) + /* Unpin the entry now */ entry_ptr->is_pinned = FALSE; diff --git a/src/H5Cprivate.h b/src/H5Cprivate.h index e5a2dba..5524f2b 100644 --- a/src/H5Cprivate.h +++ b/src/H5Cprivate.h @@ -201,10 +201,12 @@ typedef herr_t (*H5C_log_flush_func_t)(H5C_t * cache_ptr, /* Maximum height of flush dependency relationships between entries. This is * currently tuned to the extensible array (H5EA) data structure, which only - * requires 4 levels of dependency (i.e. heights 0-4). + * requires 6 levels of dependency (i.e. heights 0-6) (actually, the extensible + * array needs 4 levels, plus another 2 levels are needed: one for the layer + * under the extensible array and one for the layer above it). */ -#define H5C__NUM_FLUSH_DEP_HEIGHTS 4 +#define H5C__NUM_FLUSH_DEP_HEIGHTS 6 diff --git a/src/H5Dchunk.c b/src/H5Dchunk.c index d972043..1b38a70 100644 --- a/src/H5Dchunk.c +++ b/src/H5Dchunk.c @@ -2159,12 +2159,12 @@ H5D_chunk_flush_entry(const H5D_t *dset, hid_t dxpl_id, const H5D_dxpl_cache_t * udata.common.mesg = &dset->shared->layout; udata.common.offset = ent->offset; udata.filter_mask = 0; - udata.nbytes = ent->chunk_size; + udata.nbytes = dset->shared->layout.u.chunk.size; udata.addr = ent->chunk_addr; /* Should the chunk be filtered before writing it to disk? */ if(dset->shared->dcpl_cache.pline.nused) { - size_t alloc = ent->alloc_size; /* Bytes allocated for BUF */ + size_t alloc = udata.nbytes; /* Bytes allocated for BUF */ size_t nbytes; /* Chunk size (in bytes) */ if(!reset) { @@ -2173,10 +2173,10 @@ H5D_chunk_flush_entry(const H5D_t *dset, hid_t dxpl_id, const H5D_dxpl_cache_t * * the pipeline because we'll want to save the original buffer * for later. */ - H5_ASSIGN_OVERFLOW(alloc, ent->chunk_size, uint32_t, size_t); + H5_ASSIGN_OVERFLOW(alloc, udata.nbytes, uint32_t, size_t); if(NULL == (buf = H5MM_malloc(alloc))) HGOTO_ERROR(H5E_RESOURCE, H5E_NOSPACE, FAIL, "memory allocation failed for pipeline") - HDmemcpy(buf, ent->chunk, ent->chunk_size); + HDmemcpy(buf, ent->chunk, udata.nbytes); } /* end if */ else { /* @@ -2325,7 +2325,7 @@ H5D_chunk_cache_evict(const H5D_t *dset, hid_t dxpl_id, const H5D_dxpl_cache_t * /* Remove from cache */ rdcc->slot[ent->idx] = NULL; ent->idx = UINT_MAX; - rdcc->nbytes_used -= ent->chunk_size; + rdcc->nbytes_used -= dset->shared->layout.u.chunk.size; --rdcc->nused; /* Free */ @@ -2395,8 +2395,8 @@ H5D_chunk_cache_prune(const H5D_t *dset, hid_t dxpl_id, for(i = 0; i < nmeth && (rdcc->nbytes_used + size) > total; i++) { if(0 == i && p[0] && !p[0]->locked && ((0 == p[0]->rd_count && 0 == p[0]->wr_count) || - (0 == p[0]->rd_count && p[0]->chunk_size == p[0]->wr_count) || - (p[0]->chunk_size == p[0]->rd_count && 0 == p[0]->wr_count))) { + (0 == p[0]->rd_count && dset->shared->layout.u.chunk.size == p[0]->wr_count) || + (dset->shared->layout.u.chunk.size == p[0]->rd_count && 0 == p[0]->wr_count))) { /* * Method 0: Preempt entries that have been completely written * and/or completely read but not entries that are partially @@ -2630,8 +2630,6 @@ H5D_chunk_lock(const H5D_io_info_t *io_info, H5D_chunk_ud_t *udata, ent->locked = 0; ent->dirty = FALSE; ent->chunk_addr = chunk_addr; - H5_ASSIGN_OVERFLOW(ent->chunk_size, chunk_size, size_t, uint32_t); - ent->alloc_size = chunk_size; for(u = 0; u < layout->u.chunk.ndims; u++) ent->offset[u] = io_info->store->chunk.offset[u]; H5_ASSIGN_OVERFLOW(ent->rd_count, chunk_size, size_t, uint32_t); @@ -2766,8 +2764,6 @@ H5D_chunk_unlock(const H5D_io_info_t *io_info, const H5D_chunk_ud_t *udata, HDmemcpy(x.offset, io_info->store->chunk.offset, layout->u.chunk.ndims * sizeof(x.offset[0])); HDassert(layout->u.chunk.size > 0); x.chunk_addr = udata->addr; - x.chunk_size = layout->u.chunk.size; - H5_ASSIGN_OVERFLOW(x.alloc_size, x.chunk_size, uint32_t, size_t); x.chunk = (uint8_t *)chunk; if(H5D_chunk_flush_entry(io_info->dset, io_info->dxpl_id, io_info->dxpl_cache, &x, TRUE) < 0) @@ -3653,7 +3649,7 @@ H5D_chunk_prune_by_extent(H5D_t *dset, hid_t dxpl_id, const hsize_t *old_dims) HGOTO_ERROR(H5E_RESOURCE, H5E_NOSPACE, H5_ITER_ERROR, "memory allocation failed for stack node") /* Set up chunk record for fill routine */ - tmp_stack->rec.nbytes = ent->chunk_size; + tmp_stack->rec.nbytes = dset->shared->layout.u.chunk.size; HDmemcpy(tmp_stack->rec.offset, ent->offset, sizeof(tmp_stack->rec.offset)); tmp_stack->rec.filter_mask = 0; /* Since the chunk is already in cache this doesn't matter */ tmp_stack->rec.chunk_addr = ent->chunk_addr; diff --git a/src/H5Dint.c b/src/H5Dint.c index 00bc347..36ad640 100644 --- a/src/H5Dint.c +++ b/src/H5Dint.c @@ -844,8 +844,8 @@ H5D_update_oh_info(H5F_t *file, hid_t dxpl_id, H5D_t *dset) HDassert(file == dset->oloc.file); /* Get a pointer to the object header itself */ - if((oh = H5O_protect(oloc, dxpl_id)) == NULL) - HGOTO_ERROR(H5E_DATASET, H5E_CANTPROTECT, FAIL, "unable to protect dataset object header") + if(NULL == (oh = H5O_pin(oloc, dxpl_id))) + HGOTO_ERROR(H5E_DATASET, H5E_CANTPIN, FAIL, "unable to pin dataset object header") /* Write new fill value message */ if(H5O_msg_append_oh(file, dxpl_id, oh, H5O_FILL_NEW_ID, H5O_MSG_FLAG_CONSTANT, 0, fill_prop) < 0) @@ -981,8 +981,8 @@ H5D_update_oh_info(H5F_t *file, hid_t dxpl_id, H5D_t *dset) done: /* Release pointer to object header itself */ if(oloc != NULL && oh != NULL) - if(H5O_unprotect(oloc, oh) < 0) - HDONE_ERROR(H5E_DATASET, H5E_CANTUNPROTECT, FAIL, "unable to unprotect dataset object header") + if(H5O_unpin(oloc, oh) < 0) + HDONE_ERROR(H5E_DATASET, H5E_CANTUNPIN, FAIL, "unable to unpin dataset object header") FUNC_LEAVE_NOAPI(ret_value) } /* end H5D_update_oh_info() */ @@ -2410,8 +2410,8 @@ H5D_flush_real(H5D_t *dataset, hid_t dxpl_id, unsigned flags) unsigned update_flags = H5O_UPDATE_TIME; /* Modification time flag */ /* Get a pointer to the dataset's object header */ - if((oh = H5O_protect(&dataset->oloc, dxpl_id)) == NULL) - HGOTO_ERROR(H5E_DATASET, H5E_CANTPROTECT, FAIL, "unable to protect dataset object header") + if(NULL == (oh = H5O_pin(&dataset->oloc, dxpl_id))) + HGOTO_ERROR(H5E_DATASET, H5E_CANTPIN, FAIL, "unable to pin dataset object header") /* Update the layout on disk, if it's been changed */ if(dataset->shared->layout_dirty) { @@ -2479,8 +2479,8 @@ H5D_flush_real(H5D_t *dataset, hid_t dxpl_id, unsigned flags) done: /* Release pointer to object header */ if(oh != NULL) - if(H5O_unprotect(&(dataset->oloc), oh) < 0) - HDONE_ERROR(H5E_DATASET, H5E_CANTUNPROTECT, FAIL, "unable to unprotect dataset object header") + if(H5O_unpin(&(dataset->oloc), oh) < 0) + HDONE_ERROR(H5E_DATASET, H5E_CANTUNPIN, FAIL, "unable to unpin dataset object header") FUNC_LEAVE_NOAPI(ret_value) } /* end H5D_flush_real() */ diff --git a/src/H5Dpkg.h b/src/H5Dpkg.h index 69126ee..45d9a7d 100644 --- a/src/H5Dpkg.h +++ b/src/H5Dpkg.h @@ -486,8 +486,6 @@ typedef struct H5D_rdcc_ent_t { uint32_t rd_count; /*bytes remaining to be read */ uint32_t wr_count; /*bytes remaining to be written */ haddr_t chunk_addr; /*address of chunk in file */ - uint32_t chunk_size; /*size of a chunk */ - size_t alloc_size; /*amount allocated for the chunk */ uint8_t *chunk; /*the unfiltered chunk data */ unsigned idx; /*index in hash table */ struct H5D_rdcc_ent_t *next;/*next item in doubly-linked list */ diff --git a/src/H5EA.c b/src/H5EA.c index e35738d..ea21b15 100644 --- a/src/H5EA.c +++ b/src/H5EA.c @@ -60,6 +60,10 @@ /* Local Typedefs */ /******************/ +/* Typedef for generically unprotecting an object */ +typedef herr_t (*H5EA__unprotect_func_t)(void *thing, hid_t dxpl_id, + unsigned cache_flags); + /********************/ /* Package Typedefs */ @@ -308,9 +312,10 @@ END_FUNC(PRIV) /* end H5EA_get_addr() */ /*------------------------------------------------------------------------- - * Function: H5EA_set + * Function: H5EA_lookup_elmt * - * Purpose: Set an element of an extensible array + * Purpose: Retrieve the metadata object and the element buffer for a + * given element in the array. * * Return: SUCCEED/FAIL * @@ -320,9 +325,11 @@ END_FUNC(PRIV) /* end H5EA_get_addr() */ * *------------------------------------------------------------------------- */ -BEGIN_FUNC(PRIV, ERR, +BEGIN_FUNC(STATIC, ERR, herr_t, SUCCEED, FAIL, -H5EA_set(const H5EA_t *ea, hid_t dxpl_id, hsize_t idx, const void *elmt)) +H5EA__lookup_elmt(const H5EA_t *ea, hid_t dxpl_id, hsize_t idx, H5AC_protect_t thing_acc, + void **thing, uint8_t **thing_elmt_buf, hsize_t *thing_elmt_idx, + H5EA__unprotect_func_t *thing_unprot_func)) /* Local variables */ H5EA_hdr_t *hdr = ea->hdr; /* Header for EA */ @@ -332,8 +339,6 @@ H5EA_set(const H5EA_t *ea, hid_t dxpl_id, hsize_t idx, const void *elmt)) H5EA_dblk_page_t *dblk_page = NULL; /* Pointer to data block page for EA */ unsigned iblock_cache_flags = H5AC__NO_FLAGS_SET; /* Flags to unprotecting index block */ unsigned sblock_cache_flags = H5AC__NO_FLAGS_SET; /* Flags to unprotecting super block */ - unsigned dblock_cache_flags = H5AC__NO_FLAGS_SET; /* Flags to unprotecting data block */ - unsigned dblk_page_cache_flags = H5AC__NO_FLAGS_SET; /* Flags to unprotecting data block page */ hbool_t stats_changed = FALSE; /* Whether array statistics changed */ hbool_t hdr_dirty = FALSE; /* Whether the array header changed */ @@ -346,35 +351,51 @@ HDfprintf(stderr, "%s: Index %Hu\n", FUNC, idx); * Check arguments. */ HDassert(ea); - HDassert(ea->hdr); + HDassert(hdr); + HDassert(thing); + HDassert(thing_elmt_buf); + HDassert(thing_unprot_func); /* Set the shared array header's file context for this operation */ hdr->f = ea->f; + /* Reset the pointers to the 'thing' info */ + *thing = NULL; + *thing_elmt_buf = NULL; + *thing_elmt_idx = 0; + *thing_unprot_func = (H5EA__unprotect_func_t)NULL; + /* Check if we should create the index block */ if(!H5F_addr_defined(hdr->idx_blk_addr)) { #ifdef QAK HDfprintf(stderr, "%s: Index block address not defined!\n", FUNC, idx); #endif /* QAK */ - /* Create the index block */ - hdr->idx_blk_addr = H5EA__iblock_create(hdr, dxpl_id, &stats_changed); - if(!H5F_addr_defined(hdr->idx_blk_addr)) - H5E_THROW(H5E_CANTCREATE, "unable to create index block") - hdr_dirty = TRUE; + /* Check if we are allowed to create the thing */ + if(H5AC_WRITE == thing_acc) { + /* Create the index block */ + hdr->idx_blk_addr = H5EA__iblock_create(hdr, dxpl_id, &stats_changed); + if(!H5F_addr_defined(hdr->idx_blk_addr)) + H5E_THROW(H5E_CANTCREATE, "unable to create index block") + hdr_dirty = TRUE; + } /* end if */ + else + H5_LEAVE(SUCCEED) } /* end if */ #ifdef QAK HDfprintf(stderr, "%s: Index block address is: %a\n", FUNC, hdr->idx_blk_addr); #endif /* QAK */ /* Protect index block */ - if(NULL == (iblock = H5EA__iblock_protect(hdr, dxpl_id, H5AC_WRITE))) + if(NULL == (iblock = H5EA__iblock_protect(hdr, dxpl_id, thing_acc))) H5E_THROW(H5E_CANTPROTECT, "unable to protect extensible array index block, address = %llu", (unsigned long long)hdr->idx_blk_addr) /* Check if element is in index block */ if(idx < hdr->cparam.idx_blk_elmts) { - /* Set element in index block */ - HDmemcpy(((uint8_t *)iblock->elmts) + (hdr->cparam.cls->nat_elmt_size * idx), elmt, hdr->cparam.cls->nat_elmt_size); - dblock_cache_flags |= H5AC__DIRTIED_FLAG; + /* Set 'thing' info to refer to the index block */ + *thing = iblock; + *thing_elmt_buf = (uint8_t *)iblock->elmts; + *thing_elmt_idx = idx; + *thing_unprot_func = (H5EA__unprotect_func_t)H5EA__iblock_unprotect; } /* end if */ else { unsigned sblk_idx; /* Which superblock does this index fall in? */ @@ -407,57 +428,68 @@ HDfprintf(stderr, "%s: dblk_idx = %u, iblock->ndblk_addrs = %Zu\n", FUNC, dblk_i /* Check if the data block has been allocated on disk yet */ if(!H5F_addr_defined(iblock->dblk_addrs[dblk_idx])) { - haddr_t dblk_addr; /* Address of data block created */ - hsize_t dblk_off; /* Offset of data block in array */ - - /* Create data block */ - dblk_off = hdr->sblk_info[sblk_idx].start_idx + (dblk_idx * hdr->sblk_info[sblk_idx].dblk_nelmts); - dblk_addr = H5EA__dblock_create(hdr, dxpl_id, iblock, &stats_changed, dblk_off, hdr->sblk_info[sblk_idx].dblk_nelmts); - if(!H5F_addr_defined(dblk_addr)) - H5E_THROW(H5E_CANTCREATE, "unable to create extensible array data block") - - /* Set data block address in index block */ - iblock->dblk_addrs[dblk_idx] = dblk_addr; - dblock_cache_flags |= H5AC__DIRTIED_FLAG; + /* Check if we are allowed to create the thing */ + if(H5AC_WRITE == thing_acc) { + haddr_t dblk_addr; /* Address of data block created */ + hsize_t dblk_off; /* Offset of data block in array */ + + /* Create data block */ + dblk_off = hdr->sblk_info[sblk_idx].start_idx + (dblk_idx * hdr->sblk_info[sblk_idx].dblk_nelmts); + dblk_addr = H5EA__dblock_create(hdr, dxpl_id, iblock, &stats_changed, dblk_off, hdr->sblk_info[sblk_idx].dblk_nelmts); + if(!H5F_addr_defined(dblk_addr)) + H5E_THROW(H5E_CANTCREATE, "unable to create extensible array data block") + + /* Set data block address in index block */ + iblock->dblk_addrs[dblk_idx] = dblk_addr; + iblock_cache_flags |= H5AC__DIRTIED_FLAG; + } /* end if */ + else + H5_LEAVE(SUCCEED) } /* end if */ /* Protect data block */ - if(NULL == (dblock = H5EA__dblock_protect(hdr, dxpl_id, iblock, iblock->dblk_addrs[dblk_idx], hdr->sblk_info[sblk_idx].dblk_nelmts, H5AC_WRITE))) + if(NULL == (dblock = H5EA__dblock_protect(hdr, dxpl_id, iblock, iblock->dblk_addrs[dblk_idx], hdr->sblk_info[sblk_idx].dblk_nelmts, thing_acc))) H5E_THROW(H5E_CANTPROTECT, "unable to protect extensible array data block, address = %llu", (unsigned long long)iblock->dblk_addrs[dblk_idx]) /* Adjust index to offset in data block */ elmt_idx %= hdr->sblk_info[sblk_idx].dblk_nelmts; - /* Set element in data block */ - HDmemcpy(((uint8_t *)dblock->elmts) + (hdr->cparam.cls->nat_elmt_size * elmt_idx), elmt, hdr->cparam.cls->nat_elmt_size); - dblock_cache_flags |= H5AC__DIRTIED_FLAG; + /* Set 'thing' info to refer to the data block */ + *thing = dblock; + *thing_elmt_buf = (uint8_t *)dblock->elmts; + *thing_elmt_idx = elmt_idx; + *thing_unprot_func = (H5EA__unprotect_func_t)H5EA__dblock_unprotect; } /* end if */ else { - unsigned sblk_off; /* Offset of super block in index block array of super blocks */ - void *elmts; /* Buffer for elements */ + size_t sblk_off; /* Offset of super block in index block array of super blocks */ /* Calculate offset of super block in index block's array */ sblk_off = sblk_idx - iblock->nsblks; /* Check if the super block has been allocated on disk yet */ if(!H5F_addr_defined(iblock->sblk_addrs[sblk_off])) { - haddr_t sblk_addr; /* Address of data block created */ + /* Check if we are allowed to create the thing */ + if(H5AC_WRITE == thing_acc) { + haddr_t sblk_addr; /* Address of data block created */ - /* Create super block */ - sblk_addr = H5EA__sblock_create(hdr, dxpl_id, iblock, &stats_changed, sblk_idx); + /* Create super block */ + sblk_addr = H5EA__sblock_create(hdr, dxpl_id, iblock, &stats_changed, sblk_idx); #ifdef QAK HDfprintf(stderr, "%s: New super block address is: %a\n", FUNC, sblk_addr); #endif /* QAK */ - if(!H5F_addr_defined(sblk_addr)) - H5E_THROW(H5E_CANTCREATE, "unable to create extensible array super block") + if(!H5F_addr_defined(sblk_addr)) + H5E_THROW(H5E_CANTCREATE, "unable to create extensible array super block") - /* Set super block address in index block */ - iblock->sblk_addrs[sblk_off] = sblk_addr; - dblock_cache_flags |= H5AC__DIRTIED_FLAG; + /* Set super block address in index block */ + iblock->sblk_addrs[sblk_off] = sblk_addr; + iblock_cache_flags |= H5AC__DIRTIED_FLAG; + } /* end if */ + else + H5_LEAVE(SUCCEED) } /* end if */ /* Protect super block */ - if(NULL == (sblock = H5EA__sblock_protect(hdr, dxpl_id, iblock, iblock->sblk_addrs[sblk_off], sblk_idx, H5AC_WRITE))) + if(NULL == (sblock = H5EA__sblock_protect(hdr, dxpl_id, iblock, iblock->sblk_addrs[sblk_off], sblk_idx, thing_acc))) H5E_THROW(H5E_CANTPROTECT, "unable to protect extensible array super block, address = %llu", (unsigned long long)iblock->sblk_addrs[sblk_off]) /* Compute the data block index in super block */ @@ -469,18 +501,23 @@ HDfprintf(stderr, "%s: dblk_idx = %u, sblock->ndblks = %Zu\n", FUNC, dblk_idx, s /* Check if the data block has been allocated on disk yet */ if(!H5F_addr_defined(sblock->dblk_addrs[dblk_idx])) { - haddr_t dblk_addr; /* Address of data block created */ - hsize_t dblk_off; /* Offset of data block in array */ - - /* Create data block */ - dblk_off = hdr->sblk_info[sblk_idx].start_idx + (dblk_idx * hdr->sblk_info[sblk_idx].dblk_nelmts); - dblk_addr = H5EA__dblock_create(hdr, dxpl_id, sblock, &stats_changed, dblk_off, sblock->dblk_nelmts); - if(!H5F_addr_defined(dblk_addr)) - H5E_THROW(H5E_CANTCREATE, "unable to create extensible array data block") - - /* Set data block address in index block */ - sblock->dblk_addrs[dblk_idx] = dblk_addr; - sblock_cache_flags |= H5AC__DIRTIED_FLAG; + /* Check if we are allowed to create the thing */ + if(H5AC_WRITE == thing_acc) { + haddr_t dblk_addr; /* Address of data block created */ + hsize_t dblk_off; /* Offset of data block in array */ + + /* Create data block */ + dblk_off = hdr->sblk_info[sblk_idx].start_idx + (dblk_idx * hdr->sblk_info[sblk_idx].dblk_nelmts); + dblk_addr = H5EA__dblock_create(hdr, dxpl_id, sblock, &stats_changed, dblk_off, sblock->dblk_nelmts); + if(!H5F_addr_defined(dblk_addr)) + H5E_THROW(H5E_CANTCREATE, "unable to create extensible array data block") + + /* Set data block address in index block */ + sblock->dblk_addrs[dblk_idx] = dblk_addr; + sblock_cache_flags |= H5AC__DIRTIED_FLAG; + } /* end if */ + else + H5_LEAVE(SUCCEED) } /* end if */ #ifdef QAK @@ -524,53 +561,53 @@ HDfprintf(stderr, "%s: sblock->dblk_page_size = %Zu\n", FUNC, sblock->dblk_page_ /* Check if page has been initialized yet */ if(!H5V_bit_get(sblock->page_init, page_init_idx)) { - /* Create the data block page */ - if(H5EA__dblk_page_create(hdr, dxpl_id, sblock, dblk_page_addr) < 0) - H5E_THROW(H5E_CANTCREATE, "unable to create data block page") - - /* Mark data block page as initialized in super block */ - H5V_bit_set(sblock->page_init, page_init_idx, TRUE); - sblock_cache_flags |= H5AC__DIRTIED_FLAG; + /* Check if we are allowed to create the thing */ + if(H5AC_WRITE == thing_acc) { + /* Create the data block page */ + if(H5EA__dblk_page_create(hdr, dxpl_id, sblock, dblk_page_addr) < 0) + H5E_THROW(H5E_CANTCREATE, "unable to create data block page") + + /* Mark data block page as initialized in super block */ + H5V_bit_set(sblock->page_init, page_init_idx, TRUE); + sblock_cache_flags |= H5AC__DIRTIED_FLAG; + } /* end if */ + else + H5_LEAVE(SUCCEED) } /* end if */ /* Protect data block page */ - if(NULL == (dblk_page = H5EA__dblk_page_protect(hdr, dxpl_id, sblock, dblk_page_addr, H5AC_WRITE))) + if(NULL == (dblk_page = H5EA__dblk_page_protect(hdr, dxpl_id, sblock, dblk_page_addr, thing_acc))) H5E_THROW(H5E_CANTPROTECT, "unable to protect extensible array data block page, address = %llu", (unsigned long long)dblk_page_addr) - /* Set pointer to elements */ - elmts = dblk_page->elmts; + /* Set 'thing' info to refer to the data block page */ + *thing = dblk_page; + *thing_elmt_buf = (uint8_t *)dblk_page->elmts; + *thing_elmt_idx = elmt_idx; + *thing_unprot_func = (H5EA__unprotect_func_t)H5EA__dblk_page_unprotect; } /* end if */ else { /* Protect data block */ - if(NULL == (dblock = H5EA__dblock_protect(hdr, dxpl_id, sblock, sblock->dblk_addrs[dblk_idx], sblock->dblk_nelmts, H5AC_WRITE))) + if(NULL == (dblock = H5EA__dblock_protect(hdr, dxpl_id, sblock, sblock->dblk_addrs[dblk_idx], sblock->dblk_nelmts, thing_acc))) H5E_THROW(H5E_CANTPROTECT, "unable to protect extensible array data block, address = %llu", (unsigned long long)sblock->dblk_addrs[dblk_idx]) - /* Set pointer to elements */ - elmts = dblock->elmts; + /* Set 'thing' info to refer to the data block */ + *thing = dblock; + *thing_elmt_buf = (uint8_t *)dblock->elmts; + *thing_elmt_idx = elmt_idx; + *thing_unprot_func = (H5EA__unprotect_func_t)H5EA__dblock_unprotect; } /* end else */ - - /* Set element in data block */ - HDmemcpy(((uint8_t *)elmts) + (hdr->cparam.cls->nat_elmt_size * elmt_idx), elmt, hdr->cparam.cls->nat_elmt_size); - - /* Mark data block/data block page as dirty now */ - if(sblock->dblk_npages) - dblk_page_cache_flags |= H5AC__DIRTIED_FLAG; - else - dblock_cache_flags |= H5AC__DIRTIED_FLAG; } /* end else */ } /* end else */ - /* Update max. element set in array, if appropriate */ -#ifdef QAK -HDfprintf(stderr, "%s: idx = %Hu, hdr->stats.max_idx_set = %Hu\n", FUNC, idx, hdr->stats.max_idx_set); -#endif /* QAK */ - if(idx >= hdr->stats.stored.max_idx_set) { - HDassert(iblock); - hdr->stats.stored.max_idx_set = idx + 1; - stats_changed = TRUE; +CATCH + /* Reset 'thing' info on error */ + if(ret_value < 0) { + *thing = NULL; + *thing_elmt_buf = NULL; + *thing_elmt_idx = 0; + *thing_unprot_func = (H5EA__unprotect_func_t)NULL; } /* end if */ -CATCH /* Check for updating array statistics */ if(stats_changed) hdr_dirty = TRUE; @@ -581,15 +618,87 @@ CATCH H5E_THROW(H5E_CANTMARKDIRTY, "unable to mark extensible array header as modified") /* Release resources */ - if(iblock && H5EA__iblock_unprotect(iblock, dxpl_id, iblock_cache_flags) < 0) + if(iblock && *thing != iblock && H5EA__iblock_unprotect(iblock, dxpl_id, iblock_cache_flags) < 0) H5E_THROW(H5E_CANTUNPROTECT, "unable to release extensible array index block") + /* (Note: super blocks don't contain elements, so don't have a '*thing != sblock' check) */ if(sblock && H5EA__sblock_unprotect(sblock, dxpl_id, sblock_cache_flags) < 0) H5E_THROW(H5E_CANTUNPROTECT, "unable to release extensible array super block") - if(dblock && H5EA__dblock_unprotect(dblock, dxpl_id, dblock_cache_flags) < 0) + if(dblock && *thing != dblock && H5EA__dblock_unprotect(dblock, dxpl_id, H5AC__NO_FLAGS_SET) < 0) H5E_THROW(H5E_CANTUNPROTECT, "unable to release extensible array data block") - if(dblk_page && H5EA__dblk_page_unprotect(dblk_page, dxpl_id, dblk_page_cache_flags) < 0) + if(dblk_page && *thing != dblk_page && H5EA__dblk_page_unprotect(dblk_page, dxpl_id, H5AC__NO_FLAGS_SET) < 0) H5E_THROW(H5E_CANTUNPROTECT, "unable to release extensible array data block page") +END_FUNC(STATIC) /* end H5EA_lookup_elmt() */ + + +/*------------------------------------------------------------------------- + * Function: H5EA_set + * + * Purpose: Set an element of an extensible array + * + * Return: SUCCEED/FAIL + * + * Programmer: Quincey Koziol + * koziol@hdfgroup.org + * Sep 9 2008 + * + *------------------------------------------------------------------------- + */ +BEGIN_FUNC(PRIV, ERR, +herr_t, SUCCEED, FAIL, +H5EA_set(const H5EA_t *ea, hid_t dxpl_id, hsize_t idx, const void *elmt)) + + /* Local variables */ + H5EA_hdr_t *hdr = ea->hdr; /* Header for EA */ + void *thing = NULL; /* Pointer to the array metadata containing the array index we are interested in */ + uint8_t *thing_elmt_buf; /* Pointer to the element buffer for the array metadata */ + hsize_t thing_elmt_idx; /* Index of the element in the element buffer for the array metadata */ + H5EA__unprotect_func_t thing_unprot_func; /* Function pointer for unprotecting the array metadata */ + unsigned thing_cache_flags = H5AC__NO_FLAGS_SET; /* Flags for unprotecting array metadata */ + +#ifdef QAK +HDfprintf(stderr, "%s: Called\n", FUNC); +HDfprintf(stderr, "%s: Index %Hu\n", FUNC, idx); +#endif /* QAK */ + + /* + * Check arguments. + */ + HDassert(ea); + HDassert(hdr); + + /* Set the shared array header's file context for this operation */ + hdr->f = ea->f; + + /* Look up the array metadata containing the element we want to set */ + if(H5EA__lookup_elmt(ea, dxpl_id, idx, H5AC_WRITE, &thing, &thing_elmt_buf, &thing_elmt_idx, &thing_unprot_func) < 0) + H5E_THROW(H5E_CANTPROTECT, "unable to protect array metadata") + + /* Sanity check */ + HDassert(thing); + HDassert(thing_elmt_buf); + HDassert(thing_unprot_func); + + /* Set element in thing's element buffer */ + HDmemcpy(thing_elmt_buf + (hdr->cparam.cls->nat_elmt_size * thing_elmt_idx), elmt, hdr->cparam.cls->nat_elmt_size); + thing_cache_flags |= H5AC__DIRTIED_FLAG; + + /* Update max. element set in array, if appropriate */ +#ifdef QAK +HDfprintf(stderr, "%s: idx = %Hu, hdr->stats.max_idx_set = %Hu\n", FUNC, idx, hdr->stats.max_idx_set); +#endif /* QAK */ + if(idx >= hdr->stats.stored.max_idx_set) { + /* Update the max index for the array */ + hdr->stats.stored.max_idx_set = idx + 1; + if(H5EA__hdr_modified(hdr) < 0) + H5E_THROW(H5E_CANTMARKDIRTY, "unable to mark extensible array header as modified") + } /* end if */ + +CATCH + /* Release resources */ + if(thing && (thing_unprot_func)(thing, dxpl_id, thing_cache_flags) < 0) + H5E_THROW(H5E_CANTUNPROTECT, "unable to release extensible array metadata") + END_FUNC(PRIV) /* end H5EA_set() */ @@ -612,10 +721,8 @@ H5EA_get(const H5EA_t *ea, hid_t dxpl_id, hsize_t idx, void *elmt)) /* Local variables */ H5EA_hdr_t *hdr = ea->hdr; /* Header for EA */ - H5EA_iblock_t *iblock = NULL; /* Pointer to index block for EA */ - H5EA_sblock_t *sblock = NULL; /* Pointer to super block for EA */ - H5EA_dblock_t *dblock = NULL; /* Pointer to data block for EA */ - H5EA_dblk_page_t *dblk_page = NULL; /* Pointer to data block page for EA */ + void *thing = NULL; /* Pointer to the array metadata containing the array index we are interested in */ + H5EA__unprotect_func_t thing_unprot_func; /* Function pointer for unprotecting the array metadata */ #ifdef QAK HDfprintf(stderr, "%s: Called\n", FUNC); @@ -626,10 +733,7 @@ HDfprintf(stderr, "%s: Index %Hu\n", FUNC, idx); * Check arguments. */ HDassert(ea); - HDassert(ea->hdr); - - /* Set the shared array header's file context for this operation */ - hdr->f = ea->f; + HDassert(hdr); /* Check for element beyond max. element in array */ if(idx >= hdr->stats.stored.max_idx_set) { @@ -641,186 +745,243 @@ HDfprintf(stderr, "%s: Element beyond max. index set, hdr->stats.max_idx_set = % H5E_THROW(H5E_CANTSET, "can't set element to class's fill value") } /* end if */ else { + uint8_t *thing_elmt_buf; /* Pointer to the element buffer for the array metadata */ + hsize_t thing_elmt_idx; /* Index of the element in the element buffer for the array metadata */ + #ifdef QAK HDfprintf(stderr, "%s: Index block address is: %a\n", FUNC, hdr->idx_blk_addr); #endif /* QAK */ - /* Protect index block */ - if(NULL == (iblock = H5EA__iblock_protect(hdr, dxpl_id, H5AC_READ))) - H5E_THROW(H5E_CANTPROTECT, "unable to protect extensible array index block, address = %llu", (unsigned long long)hdr->idx_blk_addr) + /* Set the shared array header's file context for this operation */ + hdr->f = ea->f; + + /* Look up the array metadata containing the element we want to set */ + if(H5EA__lookup_elmt(ea, dxpl_id, idx, H5AC_READ, &thing, &thing_elmt_buf, &thing_elmt_idx, &thing_unprot_func) < 0) + H5E_THROW(H5E_CANTPROTECT, "unable to protect array metadata") - /* Check if element is in index block */ - if(idx < hdr->cparam.idx_blk_elmts) { - /* Get element from index block */ - HDmemcpy(elmt, ((uint8_t *)iblock->elmts) + (hdr->cparam.cls->nat_elmt_size * idx), hdr->cparam.cls->nat_elmt_size); + /* Check if the thing holding the element has been created yet */ + if(NULL == thing) { + /* Call the class's 'fill' callback */ + if((hdr->cparam.cls->fill)(elmt, (size_t)1) < 0) + H5E_THROW(H5E_CANTSET, "can't set element to class's fill value") } /* end if */ - else { - unsigned sblk_idx; /* Which superblock does this index fall in? */ - size_t dblk_idx; /* Data block index */ - hsize_t elmt_idx; /* Offset of element in super block */ + else + /* Get element from thing's element buffer */ + HDmemcpy(elmt, thing_elmt_buf + (hdr->cparam.cls->nat_elmt_size * thing_elmt_idx), hdr->cparam.cls->nat_elmt_size); + } /* end else */ - /* Get super block index where element is located */ - sblk_idx = H5EA__dblock_sblk_idx(hdr, idx); +CATCH + /* Release thing */ + if(thing && (thing_unprot_func)(thing, dxpl_id, H5AC__NO_FLAGS_SET) < 0) + H5E_THROW(H5E_CANTUNPROTECT, "unable to release extensible array metadata") - /* Adjust index to offset in super block */ - elmt_idx = idx - (hdr->cparam.idx_blk_elmts + hdr->sblk_info[sblk_idx].start_idx); -#ifdef QAK -HDfprintf(stderr, "%s: after adjusting for super block elements, elmt_idx = %Hu\n", FUNC, elmt_idx); -#endif /* QAK */ +END_FUNC(PRIV) /* end H5EA_get() */ + + +/*------------------------------------------------------------------------- + * Function: H5EA_depend + * + * Purpose: Make a child flush dependency between the extensible array's + * header and another piece of metadata in the file. + * + * Return: SUCCEED/FAIL + * + * Programmer: Quincey Koziol + * koziol@hdfgroup.org + * May 27 2009 + * + *------------------------------------------------------------------------- + */ +BEGIN_FUNC(PRIV, ERR, +herr_t, SUCCEED, FAIL, +H5EA_depend(H5AC_info_t *parent_entry, H5EA_t *ea)) + + /* Local variables */ + H5EA_hdr_t *hdr = ea->hdr; /* Header for EA */ - /* Check for data block containing element address in the index block */ - if(sblk_idx < iblock->nsblks) { -#ifdef QAK -HDfprintf(stderr, "%s: Element in data block pointed to by address in index block\n", FUNC); -#endif /* QAK */ - /* Compute the data block index in index block */ - dblk_idx = (size_t)(hdr->sblk_info[sblk_idx].start_dblk + (elmt_idx / hdr->sblk_info[sblk_idx].dblk_nelmts)); #ifdef QAK -HDfprintf(stderr, "%s: dblk_idx = %u\n", FUNC, dblk_idx); +HDfprintf(stderr, "%s: Called\n", FUNC); #endif /* QAK */ - HDassert(dblk_idx < iblock->ndblk_addrs); - /* Check if the data block has been allocated on disk yet */ - if(!H5F_addr_defined(iblock->dblk_addrs[dblk_idx])) { - /* Call the class's 'fill' callback */ - if((hdr->cparam.cls->fill)(elmt, (size_t)1) < 0) - H5E_THROW(H5E_CANTSET, "can't set element to class's fill value") - } /* end if */ - else { - /* Protect data block */ - if(NULL == (dblock = H5EA__dblock_protect(hdr, dxpl_id, iblock, iblock->dblk_addrs[dblk_idx], hdr->sblk_info[sblk_idx].dblk_nelmts, H5AC_READ))) - H5E_THROW(H5E_CANTPROTECT, "unable to protect extensible array data block, address = %llu", (unsigned long long)iblock->dblk_addrs[dblk_idx]) + /* + * Check arguments. + */ + HDassert(ea); + HDassert(hdr); - /* Adjust index to offset in data block */ - elmt_idx %= hdr->sblk_info[sblk_idx].dblk_nelmts; + /* Set the shared array header's file context for this operation */ + hdr->f = ea->f; - /* Retrieve element from data block */ - HDmemcpy(elmt, ((uint8_t *)dblock->elmts) + (hdr->cparam.cls->nat_elmt_size * elmt_idx), hdr->cparam.cls->nat_elmt_size); - } /* end else */ - } /* end if */ - else { - unsigned sblk_off; /* Offset of super block in index block array of super blocks */ + /* Set up flush dependency between child_entry and metadata array 'thing' */ + if(H5EA__create_flush_depend(hdr, parent_entry, (H5AC_info_t *)hdr) < 0) + H5E_THROW(H5E_CANTDEPEND, "unable to create flush dependency on file metadata") - /* Calculate offset of super block in index block's array */ - sblk_off = sblk_idx - iblock->nsblks; +CATCH - /* Check if the super block has been allocated on disk yet */ - if(!H5F_addr_defined(iblock->sblk_addrs[sblk_off])) { - /* Call the class's 'fill' callback */ - if((hdr->cparam.cls->fill)(elmt, (size_t)1) < 0) - H5E_THROW(H5E_CANTSET, "can't set element to class's fill value") - } /* end if */ - else { - /* Protect super block */ - if(NULL == (sblock = H5EA__sblock_protect(hdr, dxpl_id, iblock, iblock->sblk_addrs[sblk_off], sblk_idx, H5AC_READ))) - H5E_THROW(H5E_CANTPROTECT, "unable to protect extensible array super block, address = %llu", (unsigned long long)iblock->sblk_addrs[sblk_off]) +END_FUNC(PRIV) /* end H5EA_depend() */ - /* Compute the data block index in super block */ - dblk_idx = (size_t)(elmt_idx / sblock->dblk_nelmts); -#ifdef QAK -HDfprintf(stderr, "%s: dblk_idx = %u, sblock->ndblks = %Zu\n", FUNC, dblk_idx, sblock->ndblks); -#endif /* QAK */ - HDassert(dblk_idx < sblock->ndblks); + +/*------------------------------------------------------------------------- + * Function: H5EA_undepend + * + * Purpose: Remove a child flush dependency between the extensible array's + * header and another piece of metadata in the file. + * + * Return: SUCCEED/FAIL + * + * Programmer: Quincey Koziol + * koziol@hdfgroup.org + * May 27 2009 + * + *------------------------------------------------------------------------- + */ +BEGIN_FUNC(PRIV, ERR, +herr_t, SUCCEED, FAIL, +H5EA_undepend(H5AC_info_t *parent_entry, H5EA_t *ea)) - /* Check if the data block has been allocated on disk yet */ - if(!H5F_addr_defined(sblock->dblk_addrs[dblk_idx])) { - /* Call the class's 'fill' callback */ - if((hdr->cparam.cls->fill)(elmt, (size_t)1) < 0) - H5E_THROW(H5E_CANTSET, "can't set element to class's fill value") - } /* end if */ - else { - void *elmts; /* Buffer for elements */ + /* Local variables */ + H5EA_hdr_t *hdr = ea->hdr; /* Header for EA */ #ifdef QAK -if(sblock->dblk_npages) - HDfprintf(stderr, "%s: Check 1.0: elmt_idx = %Hu\n", FUNC, elmt_idx); -#endif /* QAK */ - /* Adjust index to offset in data block */ - elmt_idx %= sblock->dblk_nelmts; -#ifdef QAK -if(sblock->dblk_npages) - HDfprintf(stderr, "%s: Check 2.0: elmt_idx = %Hu\n", FUNC, elmt_idx); +HDfprintf(stderr, "%s: Called\n", FUNC); #endif /* QAK */ - /* Check if the data block is paged */ - if(sblock->dblk_npages) { - size_t page_idx; /* Index of page within data block */ - size_t page_init_idx; /* Index of 'page init' bit */ + /* + * Check arguments. + */ + HDassert(ea); + HDassert(hdr); + + /* Set the shared array header's file context for this operation */ + hdr->f = ea->f; + + /* Remove flush dependency between child_entry and metadata array 'thing' */ + if(H5EA__destroy_flush_depend(hdr, parent_entry, (H5AC_info_t *)hdr) < 0) + H5E_THROW(H5E_CANTUNDEPEND, "unable to destroy flush dependency on file metadata") + +CATCH + +END_FUNC(PRIV) /* end H5EA_undepend() */ - /* Compute page index */ - page_idx = (size_t)elmt_idx / hdr->dblk_page_nelmts; + +/*------------------------------------------------------------------------- + * Function: H5EA_support + * + * Purpose: Create a child flush dependency on the array metadata that + * contains the element for an array index. + * + * Return: SUCCEED/FAIL + * + * Programmer: Quincey Koziol + * koziol@hdfgroup.org + * May 21 2009 + * + *------------------------------------------------------------------------- + */ +BEGIN_FUNC(PRIV, ERR, +herr_t, SUCCEED, FAIL, +H5EA_support(const H5EA_t *ea, hid_t dxpl_id, hsize_t idx, H5AC_info_t *child_entry)) - /* Compute 'page init' index */ - page_init_idx = (dblk_idx * sblock->dblk_npages) + page_idx; + /* Local variables */ + H5EA_hdr_t *hdr = ea->hdr; /* Header for EA */ + void *thing = NULL; /* Pointer to the array metadata containing the array index we are interested in */ + uint8_t *thing_elmt_buf; /* Pointer to the element buffer for the array metadata */ + hsize_t thing_elmt_idx; /* Index of the element in the element buffer for the array metadata */ + H5EA__unprotect_func_t thing_unprot_func; /* Function pointer for unprotecting the array metadata */ #ifdef QAK -HDfprintf(stderr, "%s: sblock->addr = %a\n", FUNC, sblock->addr); -HDfprintf(stderr, "%s: sblock->dblk_addrs[%Zu] = %a\n", FUNC, dblk_idx, sblock->dblk_addrs[dblk_idx]); -HDfprintf(stderr, "%s: H5EA_DBLOCK_PREFIX_SIZE(sblock) = %u\n", FUNC, (unsigned)H5EA_DBLOCK_PREFIX_SIZE(sblock)); -HDfprintf(stderr, "%s: sblock->page_init[%Zu] = %t\n", FUNC, page_init_idx, H5V_bit_get(sblock->page_init, page_init_idx)); -HDfprintf(stderr, "%s: page_idx = %Zu\n", FUNC, page_idx); -HDfprintf(stderr, "%s: sblock->dblk_page_size = %Zu\n", FUNC, sblock->dblk_page_size); +HDfprintf(stderr, "%s: Called\n", FUNC); +HDfprintf(stderr, "%s: Index %Hu\n", FUNC, idx); #endif /* QAK */ - /* Check if page has been initialized yet */ - if(!H5V_bit_get(sblock->page_init, page_init_idx)) { - /* Call the class's 'fill' callback */ - if((hdr->cparam.cls->fill)(elmt, (size_t)1) < 0) - H5E_THROW(H5E_CANTSET, "can't set element to class's fill value") - - /* We've retrieved the value, leave now */ - H5_LEAVE(SUCCEED) - } /* end if */ - else { - haddr_t dblk_page_addr; /* Address of data block page */ - - /* Adjust index to offset in data block page */ - elmt_idx %= hdr->dblk_page_nelmts; - - /* Compute data block page address */ - dblk_page_addr = sblock->dblk_addrs[dblk_idx] + - H5EA_DBLOCK_PREFIX_SIZE(sblock) + - (page_idx * sblock->dblk_page_size); + /* + * Check arguments. + */ + HDassert(ea); + HDassert(hdr); + + /* Set the shared array header's file context for this operation */ + hdr->f = ea->f; + + /* Look up the array metadata containing the element we want to set */ + if(H5EA__lookup_elmt(ea, dxpl_id, idx, H5AC_WRITE, &thing, &thing_elmt_buf, &thing_elmt_idx, &thing_unprot_func) < 0) + H5E_THROW(H5E_CANTPROTECT, "unable to protect array metadata") + + /* Sanity check */ + HDassert(thing); + HDassert(thing_elmt_buf); + HDassert(thing_unprot_func); + + /* Set up flush dependency between child_entry and metadata array 'thing' */ + if(H5EA__create_flush_depend(hdr, (H5AC_info_t *)thing, child_entry) < 0) + H5E_THROW(H5E_CANTDEPEND, "unable to create flush dependency on array metadata") + +CATCH + /* Release resources */ + if(thing && (thing_unprot_func)(thing, dxpl_id, H5AC__NO_FLAGS_SET) < 0) + H5E_THROW(H5E_CANTUNPROTECT, "unable to release extensible array metadata") + +END_FUNC(PRIV) /* end H5EA_support() */ + + +/*------------------------------------------------------------------------- + * Function: H5EA_unsupport + * + * Purpose: Remove a flush dependency on the array metadata that contains + * the element for an array index. + * + * Return: SUCCEED/FAIL + * + * Programmer: Quincey Koziol + * koziol@hdfgroup.org + * May 21 2009 + * + *------------------------------------------------------------------------- + */ +BEGIN_FUNC(PRIV, ERR, +herr_t, SUCCEED, FAIL, +H5EA_unsupport(const H5EA_t *ea, hid_t dxpl_id, hsize_t idx, H5AC_info_t *child_entry)) + + /* Local variables */ + H5EA_hdr_t *hdr = ea->hdr; /* Header for EA */ + void *thing = NULL; /* Pointer to the array metadata containing the array index we are interested in */ + uint8_t *thing_elmt_buf; /* Pointer to the element buffer for the array metadata */ + hsize_t thing_elmt_idx; /* Index of the element in the element buffer for the array metadata */ + H5EA__unprotect_func_t thing_unprot_func; /* Function pointer for unprotecting the array metadata */ + #ifdef QAK -HDfprintf(stderr, "%s: elmt_idx = %Hu, dblk_page_addr = %a\n", FUNC, elmt_idx, dblk_page_addr); +HDfprintf(stderr, "%s: Called\n", FUNC); +HDfprintf(stderr, "%s: Index %Hu\n", FUNC, idx); #endif /* QAK */ - /* Protect data block page */ - if(NULL == (dblk_page = H5EA__dblk_page_protect(hdr, dxpl_id, sblock, dblk_page_addr, H5AC_READ))) - H5E_THROW(H5E_CANTPROTECT, "unable to protect extensible array data block page, address = %llu", (unsigned long long)dblk_page_addr) - - /* Set pointer to elements */ - elmts = dblk_page->elmts; - } /* end else */ - } /* end if */ - else { - /* Protect data block */ - if(NULL == (dblock = H5EA__dblock_protect(hdr, dxpl_id, sblock, sblock->dblk_addrs[dblk_idx], sblock->dblk_nelmts, H5AC_READ))) - H5E_THROW(H5E_CANTPROTECT, "unable to protect extensible array data block, address = %llu", (unsigned long long)sblock->dblk_addrs[dblk_idx]) - - /* Set pointer to elements */ - elmts = dblock->elmts; - } /* end else */ - - /* Retrieve element from data block */ - HDmemcpy(elmt, ((uint8_t *)elmts) + (hdr->cparam.cls->nat_elmt_size * elmt_idx), hdr->cparam.cls->nat_elmt_size); - } /* end else */ - } /* end else */ - } /* end else */ - } /* end else */ - } /* end else */ + /* + * Check arguments. + */ + HDassert(ea); + HDassert(hdr); + + /* Set the shared array header's file context for this operation */ + hdr->f = ea->f; + + /* Look up the array metadata containing the element we want to set */ + if(H5EA__lookup_elmt(ea, dxpl_id, idx, H5AC_READ, &thing, &thing_elmt_buf, &thing_elmt_idx, &thing_unprot_func) < 0) + H5E_THROW(H5E_CANTPROTECT, "unable to protect array metadata") + + /* Sanity check */ + HDassert(thing); + HDassert(thing_elmt_buf); + HDassert(thing_unprot_func); + + /* Remove flush dependency between child_entry and metadata array 'thing' */ + if(H5EA__destroy_flush_depend(hdr, (H5AC_info_t *)thing, child_entry) < 0) + H5E_THROW(H5E_CANTUNDEPEND, "unable to destroy flush dependency on array metadata") CATCH - if(iblock && H5EA__iblock_unprotect(iblock, dxpl_id, H5AC__NO_FLAGS_SET) < 0) - H5E_THROW(H5E_CANTUNPROTECT, "unable to release extensible array index block") - if(sblock && H5EA__sblock_unprotect(sblock, dxpl_id, H5AC__NO_FLAGS_SET) < 0) - H5E_THROW(H5E_CANTUNPROTECT, "unable to release extensible array super block") - if(dblock && H5EA__dblock_unprotect(dblock, dxpl_id, H5AC__NO_FLAGS_SET) < 0) - H5E_THROW(H5E_CANTUNPROTECT, "unable to release extensible array data block") - if(dblk_page && H5EA__dblk_page_unprotect(dblk_page, dxpl_id, H5AC__NO_FLAGS_SET) < 0) - H5E_THROW(H5E_CANTUNPROTECT, "unable to release extensible array data block page") + /* Release resources */ + if(thing && (thing_unprot_func)(thing, dxpl_id, H5AC__NO_FLAGS_SET) < 0) + H5E_THROW(H5E_CANTUNPROTECT, "unable to release extensible array metadata") -END_FUNC(PRIV) /* end H5EA_get() */ +END_FUNC(PRIV) /* end H5EA_unsupport() */ /*------------------------------------------------------------------------- @@ -894,7 +1055,7 @@ HDfprintf(stderr, "%s: Called\n", FUNC); } /* end if */ /* Release the extensible array wrapper */ - ea = H5FL_FREE(H5EA_t, ea); + ea = (H5EA_t *)H5FL_FREE(H5EA_t, ea); CATCH diff --git a/src/H5EApkg.h b/src/H5EApkg.h index f64f520..bed47e2 100644 --- a/src/H5EApkg.h +++ b/src/H5EApkg.h @@ -32,7 +32,6 @@ #include "H5EAprivate.h" /* Other private headers needed by this file */ -#include "H5ACprivate.h" /* Metadata cache */ #include "H5FLprivate.h" /* Free Lists */ /************************************************/ @@ -624,6 +623,12 @@ typedef struct H5EA_sblock_load_ud_t { unsigned sblk_idx; /* Index of super block */ } H5EA_sblock_load_ud_t; +#ifdef H5EA_TESTING +typedef struct H5EA__ctx_cb_t { + herr_t (*encode)(const void *elmt, size_t nelmts, void *udata); /* Perform action during encode step */ + void *udata; /* User data for encode action */ +} H5EA__ctx_cb_t; +#endif /* H5EA_TESTING */ /*****************************/ /* Package Private Variables */ diff --git a/src/H5EAprivate.h b/src/H5EAprivate.h index f525a01..a132006 100644 --- a/src/H5EAprivate.h +++ b/src/H5EAprivate.h @@ -34,6 +34,7 @@ #endif /* NOT_YET */ /* Private headers needed by this file */ +#include "H5ACprivate.h" /* Metadata cache */ #include "H5Fprivate.h" /* File access */ @@ -126,6 +127,12 @@ H5_DLL herr_t H5EA_get_nelmts(const H5EA_t *ea, hsize_t *nelmts); H5_DLL herr_t H5EA_get_addr(const H5EA_t *ea, haddr_t *addr); H5_DLL herr_t H5EA_set(const H5EA_t *ea, hid_t dxpl_id, hsize_t idx, const void *elmt); H5_DLL herr_t H5EA_get(const H5EA_t *ea, hid_t dxpl_id, hsize_t idx, void *elmt); +H5_DLL herr_t H5EA_depend(H5AC_info_t *parent_entry, H5EA_t *ea); +H5_DLL herr_t H5EA_undepend(H5AC_info_t *parent_entry, H5EA_t *ea); +H5_DLL herr_t H5EA_support(const H5EA_t *ea, hid_t dxpl_id, hsize_t idx, + H5AC_info_t *child_entry); +H5_DLL herr_t H5EA_unsupport(const H5EA_t *ea, hid_t dxpl_id, hsize_t idx, + H5AC_info_t *child_entry); H5_DLL herr_t H5EA_close(H5EA_t *ea, hid_t dxpl_id); H5_DLL herr_t H5EA_delete(H5F_t *f, hid_t dxpl_id, haddr_t ea_addr); diff --git a/src/H5EAtest.c b/src/H5EAtest.c index 93cd518..12d14ae 100644 --- a/src/H5EAtest.c +++ b/src/H5EAtest.c @@ -57,6 +57,7 @@ /* Callback context */ typedef struct H5EA__test_ctx_t { uint32_t bogus; /* Placeholder field to verify that context is working */ + H5EA__ctx_cb_t *cb; /* Pointer to context's callback action */ } H5EA__test_ctx_t; /********************/ @@ -126,10 +127,11 @@ H5FL_DEFINE_STATIC(H5EA__test_ctx_t); */ BEGIN_FUNC(STATIC, ERR, void *, NULL, NULL, -H5EA__test_crt_context(void UNUSED *udata)) +H5EA__test_crt_context(void *_udata)) /* Local variables */ H5EA__test_ctx_t *ctx; /* Context for callbacks */ + H5EA__ctx_cb_t *udata = (H5EA__ctx_cb_t *)_udata; /* User data for context */ /* Sanity checks */ @@ -139,6 +141,7 @@ H5EA__test_crt_context(void UNUSED *udata)) /* Initialize the context */ ctx->bogus = H5EA__TEST_BOGUS_VAL; + ctx->cb = udata; /* Set return value */ ret_value = ctx; @@ -219,8 +222,8 @@ END_FUNC(STATIC) /* end H5EA__test_fill() */ * *------------------------------------------------------------------------- */ -BEGIN_FUNC(STATIC, NOERR, -herr_t, SUCCEED, -, +BEGIN_FUNC(STATIC, ERR, +herr_t, SUCCEED, FAIL, H5EA__test_encode(void *raw, const void *_elmt, size_t nelmts, void *_ctx)) /* Local variables */ @@ -233,6 +236,12 @@ H5EA__test_encode(void *raw, const void *_elmt, size_t nelmts, void *_ctx)) HDassert(nelmts); HDassert(H5EA__TEST_BOGUS_VAL == ctx->bogus); + /* Check for callback action */ + if(ctx->cb) { + if((*ctx->cb->encode)(elmt, nelmts, ctx->cb->udata) < 0) + H5E_THROW(H5E_BADVALUE, "extensible array testing callback action failed") + } /* end if */ + /* Encode native elements into raw elements */ while(nelmts) { /* Encode element */ @@ -246,6 +255,8 @@ H5EA__test_encode(void *raw, const void *_elmt, size_t nelmts, void *_ctx)) nelmts--; } /* end while */ +CATCH + END_FUNC(STATIC) /* end H5EA__test_encode() */ diff --git a/src/H5F.c b/src/H5F.c index fc85688..3af83fa 100644 --- a/src/H5F.c +++ b/src/H5F.c @@ -894,6 +894,7 @@ H5F_new(H5F_file_t *shared, hid_t fcpl_id, hid_t fapl_id, H5FD_t *lf) f->shared->accum.loc = HADDR_UNDEF; f->shared->lf = lf; f->shared->root_addr = HADDR_UNDEF; + f->shared->next_proxy_addr = HADDR_MAX; /* * Copy the file creation and file access property lists into the diff --git a/src/H5Fpkg.h b/src/H5Fpkg.h index 49af73e..0f14b46 100644 --- a/src/H5Fpkg.h +++ b/src/H5Fpkg.h @@ -162,6 +162,7 @@ typedef struct H5F_file_t { haddr_t root_addr; /* Root group address */ H5FO_t *open_objs; /* Open objects in file */ H5RC_t *grp_btree_shared; /* Ref-counted group B-tree node info */ + haddr_t next_proxy_addr; /* Next address to use for metadata cache proxy entries */ /* File space allocation information */ unsigned fs_aggr_merge[H5FD_MEM_NTYPES]; /* Flags for whether free space can merge with aggregator(s) */ diff --git a/src/H5Fprivate.h b/src/H5Fprivate.h index cd6bcd0..59bdd10 100644 --- a/src/H5Fprivate.h +++ b/src/H5Fprivate.h @@ -265,6 +265,7 @@ typedef struct H5F_blk_aggr_t H5F_blk_aggr_t; #define H5F_HAS_FEATURE(F,FL) ((F)->shared->lf->feature_flags & (FL)) #define H5F_DRIVER_ID(F) ((F)->shared->lf->driver_id) #define H5F_GET_FILENO(F,FILENUM) ((FILENUM) = (F)->shared->lf->fileno) +#define H5F_GET_NEXT_PROXY_ADDR(F) ((F)->shared->next_proxy_addr--) #else /* H5F_PACKAGE */ #define H5F_INTENT(F) (H5F_get_intent(F)) #define H5F_FCPL(F) (H5F_get_fcpl(F)) @@ -287,6 +288,7 @@ typedef struct H5F_blk_aggr_t H5F_blk_aggr_t; #define H5F_HAS_FEATURE(F,FL) (H5F_has_feature(F,FL)) #define H5F_DRIVER_ID(F) (H5F_get_driver_id(F)) #define H5F_GET_FILENO(F,FILENUM) (H5F_get_fileno((F), &(FILENUM))) +#define H5F_GET_NEXT_PROXY_ADDR(F) (H5F_get_next_proxy_addr(F)) #endif /* H5F_PACKAGE */ @@ -472,6 +474,7 @@ H5_DLL char *H5F_get_name(const H5F_t *f); H5_DLL hid_t H5F_get_id(H5F_t *file, hbool_t app_ref); H5_DLL size_t H5F_get_obj_count(const H5F_t *f, unsigned types, hbool_t app_ref); H5_DLL size_t H5F_get_obj_ids(const H5F_t *f, unsigned types, size_t max_objs, hid_t *obj_id_list, hbool_t app_ref); +H5_DLL haddr_t H5F_get_next_proxy_addr(const H5F_t *f); /* Functions than retrieve values set/cached from the superblock/FCPL */ H5_DLL hid_t H5F_get_fcpl(const H5F_t *f); diff --git a/src/H5Fquery.c b/src/H5Fquery.c index 275061d..d070b94 100644 --- a/src/H5Fquery.c +++ b/src/H5Fquery.c @@ -687,3 +687,32 @@ done: FUNC_LEAVE_NOAPI(ret_value) } /* end H5F_get_fileno() */ + +/*------------------------------------------------------------------------- + * Function: H5F_get_next_proxy_addr + * + * Purpose: Quick and dirty routine to retrieve the next metadata proxy + * address for a file. + * (Mainly added to stop non-file routines from poking about in the + * H5F_t data structure) + * + * Return: Success: Address to use for metadata cache proxy + * Failure: abort (should not happen) + * + * Programmer: Quincey Koziol + * May 19, 2009 + * + *------------------------------------------------------------------------- + */ +haddr_t +H5F_get_next_proxy_addr(const H5F_t *f) +{ + /* Use FUNC_ENTER_NOAPI_NOINIT_NOFUNC here to avoid performance issues */ + FUNC_ENTER_NOAPI_NOINIT_NOFUNC(H5F_get_next_proxy_addr) + + HDassert(f); + HDassert(f->shared); + + FUNC_LEAVE_NOAPI(f->shared->next_proxy_addr--) +} /* end H5F_get_next_proxy_addr() */ + diff --git a/src/H5Gobj.c b/src/H5Gobj.c index 08a9268..a11dc13 100644 --- a/src/H5Gobj.c +++ b/src/H5Gobj.c @@ -806,8 +806,8 @@ H5G_obj_remove_update_linfo(H5O_loc_t *oloc, H5O_linfo_t *linfo, hid_t dxpl_id) HGOTO_ERROR(H5E_SYM, H5E_CANTNEXT, FAIL, "error iterating over links") /* Get a pointer to the object header itself */ - if((oh = H5O_protect(oloc, dxpl_id)) == NULL) - HGOTO_ERROR(H5E_SYM, H5E_CANTINIT, FAIL, "unable to protect dataset object header") + if(NULL == (oh = H5O_pin(oloc, dxpl_id))) + HGOTO_ERROR(H5E_SYM, H5E_CANTPIN, FAIL, "unable to pin group object header") /* Inspect links in table for ones that can't be converted back * into link message form (currently only links which can't fit @@ -825,8 +825,8 @@ H5G_obj_remove_update_linfo(H5O_loc_t *oloc, H5O_linfo_t *linfo, hid_t dxpl_id) for(u = 0; u < linfo->nlinks; u++) if(H5O_msg_append_oh(oloc->file, dxpl_id, oh, H5O_LINK_ID, 0, H5O_UPDATE_TIME, &(ltable.lnks[u])) < 0) { /* Release object header */ - if(H5O_unprotect(oloc, oh) < 0) - HDONE_ERROR(H5E_DATASET, H5E_CANTINIT, FAIL, "unable to unprotect dataset object header") + if(H5O_unpin(oloc, oh) < 0) + HDONE_ERROR(H5E_SYM, H5E_CANTUNPIN, FAIL, "unable to unpin group object header") HGOTO_ERROR(H5E_SYM, H5E_CANTINIT, FAIL, "can't create message") } /* end if */ @@ -837,8 +837,8 @@ H5G_obj_remove_update_linfo(H5O_loc_t *oloc, H5O_linfo_t *linfo, hid_t dxpl_id) } /* end if */ /* Release object header */ - if(H5O_unprotect(oloc, oh) < 0) - HDONE_ERROR(H5E_DATASET, H5E_CANTINIT, FAIL, "unable to unprotect dataset object header") + if(H5O_unpin(oloc, oh) < 0) + HGOTO_ERROR(H5E_SYM, H5E_CANTUNPIN, FAIL, "unable to unpin group object header") /* Free link table information */ if(H5G_link_release_table(<able) < 0) diff --git a/src/H5O.c b/src/H5O.c index 85fda74..2017e1c 100644 --- a/src/H5O.c +++ b/src/H5O.c @@ -439,8 +439,11 @@ H5Olink(hid_t obj_id, hid_t new_loc_id, const char *new_name, hid_t lcpl_id, HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a location") if(!new_name || !*new_name) HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "no name specified") +/* Avoid compiler warning on 32-bit machines */ +#if H5_SIZEOF_SIZE_T > H5_SIZEOF_INT32_T if(HDstrlen(new_name) > H5L_MAX_LINK_NAME_LEN) HGOTO_ERROR(H5E_ARGS, H5E_BADRANGE, FAIL, "name too long") +#endif /* H5_SIZEOF_SIZE_T > H5_SIZEOF_INT32_T */ if(lcpl_id != H5P_DEFAULT && (TRUE != H5P_isa_class(lcpl_id, H5P_LINK_CREATE))) HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a link creation property list") @@ -1128,9 +1131,13 @@ H5O_create(H5F_t *f, hid_t dxpl_id, size_t size_hint, hid_t ocpl_id, oh->flags |= H5O_HDR_ATTR_STORE_PHASE_CHANGE; /* Determine correct value for chunk #0 size bits */ +/* Avoid compiler warning on 32-bit machines */ +#if H5_SIZEOF_SIZE_T > H5_SIZEOF_INT32_T if(size_hint > 4294967295) oh->flags |= H5O_HDR_CHUNK0_8; - else if(size_hint > 65535) + else +#endif /* H5_SIZEOF_SIZE_T > H5_SIZEOF_INT32_T */ + if(size_hint > 65535) oh->flags |= H5O_HDR_CHUNK0_4; else if(size_hint > 255) oh->flags |= H5O_HDR_CHUNK0_2; @@ -1545,15 +1552,14 @@ done: /*------------------------------------------------------------------------- - * Function: H5O_protect + * Function: H5O_pin * - * Purpose: Wrapper around H5AC_protect for use during a H5O_protect-> - * H5O_msg_append->...->H5O_msg_append->H5O_unprotect sequence of calls - * during an object's creation. + * Purpose: Pin an object header down for use during a sequence of message + * operations, which prevents the object header from being + * evicted from the cache. * * Return: Success: Pointer to the object header structure for the * object. - * * Failure: NULL * * Programmer: Quincey Koziol @@ -1563,11 +1569,12 @@ done: *------------------------------------------------------------------------- */ H5O_t * -H5O_protect(H5O_loc_t *loc, hid_t dxpl_id) +H5O_pin(H5O_loc_t *loc, hid_t dxpl_id) { - H5O_t *ret_value; /* Return value */ + H5O_t *oh = NULL; /* Object header */ + H5O_t *ret_value; /* Return value */ - FUNC_ENTER_NOAPI(H5O_protect, NULL) + FUNC_ENTER_NOAPI(H5O_pin, NULL) /* check args */ HDassert(loc); @@ -1579,34 +1586,38 @@ H5O_protect(H5O_loc_t *loc, hid_t dxpl_id) HGOTO_ERROR(H5E_OHDR, H5E_WRITEERROR, NULL, "no write intent on file") /* Lock the object header into the cache */ - if(NULL == (ret_value = (H5O_t *)H5AC_protect(loc->file, dxpl_id, H5AC_OHDR, loc->addr, NULL, NULL, H5AC_WRITE))) - HGOTO_ERROR(H5E_OHDR, H5E_CANTLOAD, NULL, "unable to load object header") - - /* Mark object header as un-evictable */ - if(H5AC_pin_protected_entry(loc->file, ret_value) < 0) { - if(H5AC_unprotect(loc->file, dxpl_id, H5AC_OHDR, loc->addr, ret_value, H5AC__NO_FLAGS_SET) < 0) - HDONE_ERROR(H5E_OHDR, H5E_PROTECT, NULL, "unable to release object header") + if(NULL == (oh = (H5O_t *)H5AC_protect(loc->file, dxpl_id, H5AC_OHDR, loc->addr, NULL, NULL, H5AC_WRITE))) + HGOTO_ERROR(H5E_OHDR, H5E_CANTPROTECT, NULL, "unable to load object header") - HGOTO_ERROR(H5E_OHDR, H5E_CANTPIN, NULL, "unable to pin object header") + /* Check if the object header needs to be pinned */ + if(0 == oh->npins) { + /* Mark object header as un-evictable */ + if(H5AC_pin_protected_entry(loc->file, oh) < 0) + HGOTO_ERROR(H5E_OHDR, H5E_CANTPIN, NULL, "unable to pin object header") } /* end if */ - /* Release the object header from the cache */ - if(H5AC_unprotect(loc->file, dxpl_id, H5AC_OHDR, loc->addr, ret_value, H5AC__NO_FLAGS_SET) < 0) - HGOTO_ERROR(H5E_OHDR, H5E_PROTECT, NULL, "unable to release object header") + /* Increment the pin count */ + oh->npins++; + + /* Set the return value */ + ret_value = oh; + done: + /* Release the object header from the cache */ + if(oh && H5AC_unprotect(loc->file, dxpl_id, H5AC_OHDR, loc->addr, ret_value, H5AC__NO_FLAGS_SET) < 0) + HDONE_ERROR(H5E_OHDR, H5E_CANTUNPROTECT, NULL, "unable to release object header") + FUNC_LEAVE_NOAPI(ret_value) -} /* end H5O_protect() */ +} /* end H5O_pin() */ /*------------------------------------------------------------------------- - * Function: H5O_unprotect + * Function: H5O_unpin * - * Purpose: Wrapper around H5AC_unprotect for use during a H5O_protect-> - * H5O_msg_append->...->H5O_msg_append->H5O_unprotect sequence of calls - * during an object's creation. + * Purpose: Unpin an object header, allowing it to be evicted from the + * metadata cache. * * Return: Success: Non-negative - * * Failure: Negative * * Programmer: Quincey Koziol @@ -1616,11 +1627,11 @@ done: *------------------------------------------------------------------------- */ herr_t -H5O_unprotect(H5O_loc_t *loc, H5O_t *oh) +H5O_unpin(H5O_loc_t *loc, H5O_t *oh) { herr_t ret_value = SUCCEED; /* Return value */ - FUNC_ENTER_NOAPI(H5O_unprotect, FAIL) + FUNC_ENTER_NOAPI(H5O_unpin, FAIL) /* check args */ HDassert(loc); @@ -1628,13 +1639,19 @@ H5O_unprotect(H5O_loc_t *loc, H5O_t *oh) HDassert(H5F_addr_defined(loc->addr)); HDassert(oh); - /* Mark object header as evictable again */ - if(H5AC_unpin_entry(loc->file, oh) < 0) - HGOTO_ERROR(H5E_OHDR, H5E_CANTUNPIN, FAIL, "unable to unpin object header") + /* Check if this is the last unpin operation */ + if(1 == oh->npins) { + /* Mark object header as evictable again */ + if(H5AC_unpin_entry(loc->file, oh) < 0) + HGOTO_ERROR(H5E_OHDR, H5E_CANTUNPIN, FAIL, "unable to unpin object header") + } /* end if */ + + /* Decrement the pin count */ + oh->npins--; done: FUNC_LEAVE_NOAPI(ret_value) -} /* end H5O_unprotect() */ +} /* end H5O_unpin() */ /*------------------------------------------------------------------------- diff --git a/src/H5Opkg.h b/src/H5Opkg.h index 9981461..8569119 100644 --- a/src/H5Opkg.h +++ b/src/H5Opkg.h @@ -266,6 +266,11 @@ struct H5O_t { /* File-specific information (not stored) */ size_t sizeof_size; /* Size of file sizes */ size_t sizeof_addr; /* Size of file addresses */ + + /* Misc. information (not stored) */ + unsigned npins; /* Number of times the header is pinned */ + + /* Debugging information (not stored) */ #ifdef H5O_ENABLE_BAD_MESG_COUNT hbool_t store_bad_mesg_count; /* Flag to indicate that a bad message count should be stored */ /* (This is to simulate a bug in earlier diff --git a/src/H5Oprivate.h b/src/H5Oprivate.h index 018bc77..bf416f4 100644 --- a/src/H5Oprivate.h +++ b/src/H5Oprivate.h @@ -578,8 +578,8 @@ H5_DLL herr_t H5O_open(H5O_loc_t *loc); H5_DLL herr_t H5O_close(H5O_loc_t *loc); H5_DLL int H5O_link(const H5O_loc_t *loc, int adjust, hid_t dxpl_id); H5_DLL int H5O_link_oh(H5F_t *f, int adjust, hid_t dxpl_id, H5O_t *oh, unsigned *oh_flags); -H5_DLL H5O_t *H5O_protect(H5O_loc_t *loc, hid_t dxpl_id); -H5_DLL herr_t H5O_unprotect(H5O_loc_t *loc, H5O_t *oh); +H5_DLL H5O_t *H5O_pin(H5O_loc_t *loc, hid_t dxpl_id); +H5_DLL herr_t H5O_unpin(H5O_loc_t *loc, H5O_t *oh); H5_DLL herr_t H5O_touch(H5O_loc_t *loc, hbool_t force, hid_t dxpl_id); H5_DLL herr_t H5O_touch_oh(H5F_t *f, hid_t dxpl_id, H5O_t *oh, hbool_t force); diff --git a/src/H5S.c b/src/H5S.c index 40134a6..9de4e95 100644 --- a/src/H5S.c +++ b/src/H5S.c @@ -1756,27 +1756,25 @@ done: /*------------------------------------------------------------------------- - * Function: H5S_set_extent + * Function: H5S_set_extent * - * Purpose: Modify the dimensions of a dataspace. Based on H5S_extend + * Purpose: Modify the dimensions of a dataspace. Based on H5S_extend * - * Return: Success: Non-negative + * Return: Success: Non-negative + * Failure: Negative * - * Failure: Negative - * - * Programmer: Pedro Vicente, pvn@ncsa.uiuc.edu - * - * Date: March 13, 2002 + * Programmer: Pedro Vicente, pvn@ncsa.uiuc.edu + * March 13, 2002 * *------------------------------------------------------------------------- */ -int +htri_t H5S_set_extent(H5S_t *space, const hsize_t *size) { unsigned u; /* Local index variable */ - herr_t ret_value = 0; /* Return value */ + htri_t ret_value = FALSE; /* Return value */ - FUNC_ENTER_NOAPI(H5S_set_extent, FAIL); + FUNC_ENTER_NOAPI(H5S_set_extent, FAIL) /* Check args */ HDassert(space && H5S_SIMPLE == H5S_GET_EXTENT_TYPE(space)); @@ -1785,21 +1783,26 @@ H5S_set_extent(H5S_t *space, const hsize_t *size) /* Verify that the dimensions being changed are allowed to change */ for(u = 0; u < space->extent.rank; u++) { if(space->extent.size[u] != size[u]) { + /* Check for invalid dimension size modification */ if(space->extent.max && H5S_UNLIMITED != space->extent.max[u] && space->extent.max[u] < size[u]) - HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "dimension cannot be modified") - ret_value++; + HGOTO_ERROR(H5E_DATASPACE, H5E_BADVALUE, FAIL, "dimension cannot be modified") + + /* Indicate that dimension size can be modified */ + ret_value = TRUE; } /* end if */ } /* end for */ - /* Update */ + /* Update dimension size(s) */ if(ret_value) - H5S_set_extent_real(space, size); + if(H5S_set_extent_real(space, size) < 0) + HGOTO_ERROR(H5E_DATASPACE, H5E_CANTSET, FAIL, "failed to change dimension size(s)") done: - FUNC_LEAVE_NOAPI(ret_value); -} + FUNC_LEAVE_NOAPI(ret_value) +} /* end H5S_set_extent() */ + /*------------------------------------------------------------------------- * Function: H5S_has_extent * @@ -1824,7 +1827,7 @@ H5S_has_extent(const H5S_t *ds) HDassert(ds); - if(ds->extent.rank==0 && ds->extent.nelem == 0 && ds->extent.type != H5S_NULL) + if(0 == ds->extent.rank && 0 == ds->extent.nelem && H5S_NULL != ds->extent.type) ret_value = FALSE; else ret_value = TRUE; @@ -1835,43 +1838,41 @@ done: /*------------------------------------------------------------------------- - * Function: H5S_set_extent_real - * - * Purpose: Modify the dimensions of a dataspace. Based on H5S_extend - * - * Return: Success: Non-negative + * Function: H5S_set_extent_real * - * Failure: Negative + * Purpose: Modify the dimensions of a dataspace. Based on H5S_extend * - * Programmer: Pedro Vicente, pvn@ncsa.uiuc.edu + * Return: Success: Non-negative + * Failure: Negative * - * Date: March 13, 2002 + * Programmer: Pedro Vicente, pvn@ncsa.uiuc.edu + * March 13, 2002 * *------------------------------------------------------------------------- */ herr_t -H5S_set_extent_real( H5S_t *space, const hsize_t *size ) +H5S_set_extent_real(H5S_t *space, const hsize_t *size) { hsize_t nelem; /* Number of elements in extent */ unsigned u; /* Local index variable */ - herr_t ret_value=SUCCEED; /* Return value */ + herr_t ret_value = SUCCEED; /* Return value */ - FUNC_ENTER_NOAPI(H5S_set_extent_real, FAIL ); + FUNC_ENTER_NOAPI(H5S_set_extent_real, FAIL) /* Check args */ - assert(space && H5S_SIMPLE==H5S_GET_EXTENT_TYPE(space)); - assert(size); + HDassert(space && H5S_SIMPLE == H5S_GET_EXTENT_TYPE(space)); + HDassert(size); /* Change the dataspace size & re-compute the number of elements in the extent */ - for (u=0, nelem=1; u < space->extent.rank; u++ ) { + for(u = 0, nelem = 1; u < space->extent.rank; u++ ) { space->extent.size[u] = size[u]; - nelem*=space->extent.size[u]; + nelem *= space->extent.size[u]; } /* end for */ space->extent.nelem = nelem; /* If the selection is 'all', update the number of elements selected */ - if(H5S_GET_SELECT_TYPE(space)==H5S_SEL_ALL) - if(H5S_select_all(space, FALSE)<0) + if(H5S_SEL_ALL == H5S_GET_SELECT_TYPE(space)) + if(H5S_select_all(space, FALSE) < 0) HGOTO_ERROR(H5E_DATASPACE, H5E_CANTDELETE, FAIL, "can't change selection") /* Mark the dataspace as no longer shared if it was before */ @@ -1879,7 +1880,7 @@ H5S_set_extent_real( H5S_t *space, const hsize_t *size ) HGOTO_ERROR(H5E_DATASPACE, H5E_CANTRESET, FAIL, "can't stop sharing dataspace") done: - FUNC_LEAVE_NOAPI(ret_value); + FUNC_LEAVE_NOAPI(ret_value) } /* end H5S_set_extent_real() */ diff --git a/src/H5Sprivate.h b/src/H5Sprivate.h index e78fb51..3514670 100644 --- a/src/H5Sprivate.h +++ b/src/H5Sprivate.h @@ -184,7 +184,7 @@ H5_DLL herr_t H5S_write(H5F_t *f, hid_t dxpl_id, H5O_t *oh, unsigned update_flag H5S_t *ds); H5_DLL herr_t H5S_append(H5F_t *f, hid_t dxpl_id, struct H5O_t *oh, H5S_t *ds); H5_DLL H5S_t *H5S_read(const struct H5O_loc_t *loc, hid_t dxpl_id); -H5_DLL int H5S_set_extent(H5S_t *space, const hsize_t *size); +H5_DLL htri_t H5S_set_extent(H5S_t *space, const hsize_t *size); H5_DLL herr_t H5S_set_extent_real(H5S_t *space, const hsize_t *size); H5_DLL H5S_t *H5S_create(H5S_class_t type); H5_DLL H5S_t *H5S_create_simple(unsigned rank, const hsize_t dims[/*rank*/], diff --git a/src/H5private.h b/src/H5private.h index 43b8a95..cb776de 100644 --- a/src/H5private.h +++ b/src/H5private.h @@ -1156,8 +1156,11 @@ H5_DLL int HDfprintf (FILE *stream, const char *fmt, ...); #define HDstrchr(S,C) strchr(S,C) #endif /* HDstrchr */ #ifndef HDstrcmp - #define HDstrcmp(X,Y) strcmp(X,Y) + #define HDstrcmp(X,Y) strcmp(X,Y) #endif /* HDstrcmp */ +#ifndef HDstrcasecmp + #define HDstrcasecmp(X,Y) strcasecmp(X,Y) +#endif /* HDstrcasecmp */ #ifndef HDstrcoll #define HDstrcoll(X,Y) strcoll(X,Y) #endif /* HDstrcoll */ diff --git a/src/H5public.h b/src/H5public.h index 4f81141..f138a16 100644 --- a/src/H5public.h +++ b/src/H5public.h @@ -71,10 +71,10 @@ extern "C" { /* Version numbers */ #define H5_VERS_MAJOR 1 /* For major interface/format changes */ #define H5_VERS_MINOR 9 /* For minor interface/format changes */ -#define H5_VERS_RELEASE 39 /* For tweaks, bug-fixes, or development */ +#define H5_VERS_RELEASE 41 /* For tweaks, bug-fixes, or development */ #define H5_VERS_SUBRELEASE "" /* For pre-releases like snap0 */ /* Empty string for real releases. */ -#define H5_VERS_INFO "HDF5 library version: 1.9.39" /* Full version string */ +#define H5_VERS_INFO "HDF5 library version: 1.9.41" /* Full version string */ #define H5check() H5check_version(H5_VERS_MAJOR,H5_VERS_MINOR, \ H5_VERS_RELEASE) diff --git a/src/H5system.c b/src/H5system.c index 8956e9b..36ec1c1 100644 --- a/src/H5system.c +++ b/src/H5system.c @@ -580,6 +580,52 @@ HDremove_all(const char *fname) } #endif +/*------------------------------------------------------------------------- + * Function: HDgettimeofday + * + * Purpose: Wrapper function for gettimeofday on Windows systems + * + * This function can get the time as well as a timezone + * + * Return: 0 + * + * This implementation is taken from the Cygwin source distribution at + * src/winsup/mingw/mingwex/gettimeofday.c + * + * The original source code was contributed by + * Danny Smith + * and released in the public domain. + * + * Programmer: Scott Wegner + * May 19, 2009 + * + *------------------------------------------------------------------------- + */ +#if !defined(H5_HAVE_GETTIMEOFDAY) && defined(_WIN32) + +/* Offset between 1/1/1601 and 1/1/1970 in 100 nanosec units */ +#define _W32_FT_OFFSET (116444736000000000ULL) + +int +HDgettimeofday(struct timeval *tv, void *tz) + { + union { + unsigned long long ns100; /*time since 1 Jan 1601 in 100ns units */ + FILETIME ft; + } _now; + + if(tv) + { + GetSystemTimeAsFileTime (&_now.ft); + tv->tv_usec=(long)((_now.ns100 / 10ULL) % 1000000ULL ); + tv->tv_sec= (long)((_now.ns100 - _W32_FT_OFFSET) / 10000000ULL); + } + /* Always return 0 as per Open Group Base Specifications Issue 6. + Do not set errno on error. */ + return 0; +} +#endif + /* *------------------------------------------------------------------------- diff --git a/src/H5win32defs.h b/src/H5win32defs.h index 0cf7172..93695fb 100644 --- a/src/H5win32defs.h +++ b/src/H5win32defs.h @@ -33,18 +33,26 @@ typedef __int64 h5_stat_size_t; #define HDdup(F) _dup(F) #define HDfdopen(N,S) _fdopen(N,S) #define HDfileno(F) _fileno(F) - -#if _MSC_VER > 1200 +#if _MSC_VER > 1310 /* Newer than VS.NET 2003 */ #define HDftruncate(F,L) _chsize_s(F,L) #else #define HDftruncate(F,L) chsize(F,L) #endif - #define HDfstat(F,B) _fstati64(F,B) #define HDisatty(F) _isatty(F) #define HDstat(S,B) _stati64(S,B) #define HDgetcwd(S,Z) _getcwd(S,Z) #define HDgetdcwd(D,S,Z) _getdcwd(D,S,Z) +#ifndef H5_HAVE_GETTIMEOFDAY + #ifdef __cplusplus + extern "C" { + #endif /* __cplusplus */ + int HDgettimeofday(struct timeval *tv, void *tz); + #ifdef __cplusplus + } + #endif /* __cplusplus */ + #define HDgettimeofday(V,Z) HDgettimeofday(V,Z) +#endif /* H5_HAVE_GETTIMEOFDAY */ #define HDgetdrive() _getdrive() #define HDlseek(F,O,W) _lseeki64(F,O,W) #define HDmemset(X,C,Z) memset((void*)(X),C,Z) @@ -52,13 +60,14 @@ typedef __int64 h5_stat_size_t; #define HDopen(S,F,M) _open(S,F|_O_BINARY,M) #define HDread(F,M,Z) _read(F,M,Z) #define HDsetvbuf(F,S,M,Z) setvbuf(F,S,M,(Z>1?Z:2)) +#define HDstrcasecmp(A,B) _stricmp(A,B) +#define HDstrtoull(S,R,N) _strtoui64(S,R,N) #define HDstrdup(S) _strdup(S) #define HDsnprintf _snprintf /*varargs*/ #define HDtzset() _tzset() #define HDunlink(S) _unlink(S) #define HDvsnprintf(S,N,FMT,A) _vsnprintf(S,N,FMT,A) #define HDwrite(F,M,Z) _write(F,M,Z) -#define HDstrtoull(S,R,N) _strtoui64(S,R,N) /* Non-POSIX functions */ diff --git a/src/Makefile.in b/src/Makefile.in index 0faf5fd..7fe58fc 100644 --- a/src/Makefile.in +++ b/src/Makefile.in @@ -409,7 +409,7 @@ CHECK_CLEANFILES = *.chkexe *.chklog *.clog # Add libtool shared library version numbers to the HDF5 library # See libtool versioning documentation online. LT_VERS_INTERFACE = 6 -LT_VERS_REVISION = 29 +LT_VERS_REVISION = 31 LT_VERS_AGE = 0 H5detect_CFLAGS = -g diff --git a/test/Makefile.in b/test/Makefile.in index 69e5c08..fa06734 100644 --- a/test/Makefile.in +++ b/test/Makefile.in @@ -631,10 +631,10 @@ TRACE = perl $(top_srcdir)/bin/trace CHECK_CLEANFILES = *.chkexe *.chklog *.clog cmpd_dset.h5 \ compact_dataset.h5 dataset.h5 dset_offset.h5 \ max_compact_dataset.h5 simple.h5 set_local.h5 random_chunks.h5 \ - huge_chunks.h5 chunk_cache.h5 big_chunk.h5 \ - chunk_expand.h5 extend.h5 istore.h5 extlinks*.h5 frspace.h5 \ - links*.h5 tfile[1-4].h5 th5s[1-3].h5 lheap.h5 fheap.h5 ohdr.h5 \ - stab.h5 extern_[1-3].h5 extern_[1-4][ab].raw gheap[0-4].h5 \ + huge_chunks.h5 chunk_cache.h5 big_chunk.h5 chunk_expand.h5 \ + extend.h5 istore.h5 extlinks*.h5 frspace.h5 links*.h5 \ + tfile[1-4].h5 th5s[1-3].h5 lheap.h5 fheap.h5 ohdr.h5 stab.h5 \ + extern_[1-3].h5 extern_[1-4][ab].raw gheap[0-4].h5 \ dt_arith[1-2] links.h5 links[0-6]*.h5 extlinks[0-15].h5 tmp \ big.data big[0-9][0-9][0-9][0-9][0-9].h5 stdio.h5 sec2.h5 \ dtypes[1-8].h5 dt_arith[1-2].h5 tattr.h5 tselect.h5 mtime.h5 \ diff --git a/test/cache.c b/test/cache.c index a5b5f3a..2149e3b 100644 --- a/test/cache.c +++ b/test/cache.c @@ -9798,59 +9798,59 @@ check_flush_cache__flush_op_eviction_test(H5C_t * cache_ptr) */ /* entry entry in at main flush dep flush dep child flush flush flush */ /* type: index: size: cache: addr: dirty: prot: pinned: loaded: clrd: flshd: dest: par type: par idx: dep ref.count: dep height: order: */ - { VARIABLE_ENTRY_TYPE, 0, VARIABLE_ENTRY_SIZE/2, TRUE, TRUE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { VARIABLE_ENTRY_TYPE, 1, VARIABLE_ENTRY_SIZE, TRUE, TRUE, FALSE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { VARIABLE_ENTRY_TYPE, 2, VARIABLE_ENTRY_SIZE, TRUE, TRUE, FALSE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { VARIABLE_ENTRY_TYPE, 3, VARIABLE_ENTRY_SIZE/2, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { VARIABLE_ENTRY_TYPE, 4, VARIABLE_ENTRY_SIZE/2, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { VARIABLE_ENTRY_TYPE, 5, VARIABLE_ENTRY_SIZE/2, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { VARIABLE_ENTRY_TYPE, 6, VARIABLE_ENTRY_SIZE, TRUE, TRUE, FALSE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { VARIABLE_ENTRY_TYPE, 7, VARIABLE_ENTRY_SIZE, TRUE, TRUE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { MONSTER_ENTRY_TYPE, 0, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { MONSTER_ENTRY_TYPE, 1, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { MONSTER_ENTRY_TYPE, 2, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { MONSTER_ENTRY_TYPE, 3, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { MONSTER_ENTRY_TYPE, 4, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { MONSTER_ENTRY_TYPE, 5, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { MONSTER_ENTRY_TYPE, 6, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { MONSTER_ENTRY_TYPE, 7, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { MONSTER_ENTRY_TYPE, 8, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { MONSTER_ENTRY_TYPE, 9, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { MONSTER_ENTRY_TYPE, 10, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { MONSTER_ENTRY_TYPE, 11, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { MONSTER_ENTRY_TYPE, 12, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { MONSTER_ENTRY_TYPE, 13, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { MONSTER_ENTRY_TYPE, 14, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { MONSTER_ENTRY_TYPE, 15, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { MONSTER_ENTRY_TYPE, 16, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { MONSTER_ENTRY_TYPE, 17, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { MONSTER_ENTRY_TYPE, 18, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { MONSTER_ENTRY_TYPE, 19, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { MONSTER_ENTRY_TYPE, 20, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { MONSTER_ENTRY_TYPE, 21, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { MONSTER_ENTRY_TYPE, 22, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { MONSTER_ENTRY_TYPE, 23, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { MONSTER_ENTRY_TYPE, 24, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { MONSTER_ENTRY_TYPE, 25, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { MONSTER_ENTRY_TYPE, 26, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { MONSTER_ENTRY_TYPE, 27, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { MONSTER_ENTRY_TYPE, 28, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { MONSTER_ENTRY_TYPE, 29, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { MONSTER_ENTRY_TYPE, 30, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { LARGE_ENTRY_TYPE, 0, LARGE_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { LARGE_ENTRY_TYPE, 1, LARGE_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { LARGE_ENTRY_TYPE, 2, LARGE_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { LARGE_ENTRY_TYPE, 3, LARGE_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { LARGE_ENTRY_TYPE, 4, LARGE_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { LARGE_ENTRY_TYPE, 5, LARGE_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { LARGE_ENTRY_TYPE, 6, LARGE_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { LARGE_ENTRY_TYPE, 7, LARGE_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { LARGE_ENTRY_TYPE, 8, LARGE_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { LARGE_ENTRY_TYPE, 9, LARGE_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { LARGE_ENTRY_TYPE, 10, LARGE_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { LARGE_ENTRY_TYPE, 11, LARGE_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { LARGE_ENTRY_TYPE, 12, LARGE_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { LARGE_ENTRY_TYPE, 13, LARGE_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 } + { VARIABLE_ENTRY_TYPE, 0, VARIABLE_ENTRY_SIZE/2, TRUE, TRUE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { VARIABLE_ENTRY_TYPE, 1, VARIABLE_ENTRY_SIZE, TRUE, TRUE, FALSE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { VARIABLE_ENTRY_TYPE, 2, VARIABLE_ENTRY_SIZE, TRUE, TRUE, FALSE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { VARIABLE_ENTRY_TYPE, 3, VARIABLE_ENTRY_SIZE/2, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { VARIABLE_ENTRY_TYPE, 4, VARIABLE_ENTRY_SIZE/2, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { VARIABLE_ENTRY_TYPE, 5, VARIABLE_ENTRY_SIZE/2, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { VARIABLE_ENTRY_TYPE, 6, VARIABLE_ENTRY_SIZE, TRUE, TRUE, FALSE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { VARIABLE_ENTRY_TYPE, 7, VARIABLE_ENTRY_SIZE, TRUE, TRUE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { MONSTER_ENTRY_TYPE, 0, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { MONSTER_ENTRY_TYPE, 1, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { MONSTER_ENTRY_TYPE, 2, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { MONSTER_ENTRY_TYPE, 3, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { MONSTER_ENTRY_TYPE, 4, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { MONSTER_ENTRY_TYPE, 5, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { MONSTER_ENTRY_TYPE, 6, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { MONSTER_ENTRY_TYPE, 7, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { MONSTER_ENTRY_TYPE, 8, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { MONSTER_ENTRY_TYPE, 9, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { MONSTER_ENTRY_TYPE, 10, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { MONSTER_ENTRY_TYPE, 11, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { MONSTER_ENTRY_TYPE, 12, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { MONSTER_ENTRY_TYPE, 13, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { MONSTER_ENTRY_TYPE, 14, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { MONSTER_ENTRY_TYPE, 15, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { MONSTER_ENTRY_TYPE, 16, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { MONSTER_ENTRY_TYPE, 17, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { MONSTER_ENTRY_TYPE, 18, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { MONSTER_ENTRY_TYPE, 19, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { MONSTER_ENTRY_TYPE, 20, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { MONSTER_ENTRY_TYPE, 21, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { MONSTER_ENTRY_TYPE, 22, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { MONSTER_ENTRY_TYPE, 23, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { MONSTER_ENTRY_TYPE, 24, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { MONSTER_ENTRY_TYPE, 25, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { MONSTER_ENTRY_TYPE, 26, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { MONSTER_ENTRY_TYPE, 27, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { MONSTER_ENTRY_TYPE, 28, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { MONSTER_ENTRY_TYPE, 29, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { MONSTER_ENTRY_TYPE, 30, MONSTER_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { LARGE_ENTRY_TYPE, 0, LARGE_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { LARGE_ENTRY_TYPE, 1, LARGE_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { LARGE_ENTRY_TYPE, 2, LARGE_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { LARGE_ENTRY_TYPE, 3, LARGE_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { LARGE_ENTRY_TYPE, 4, LARGE_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { LARGE_ENTRY_TYPE, 5, LARGE_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { LARGE_ENTRY_TYPE, 6, LARGE_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { LARGE_ENTRY_TYPE, 7, LARGE_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { LARGE_ENTRY_TYPE, 8, LARGE_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { LARGE_ENTRY_TYPE, 9, LARGE_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { LARGE_ENTRY_TYPE, 10, LARGE_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { LARGE_ENTRY_TYPE, 11, LARGE_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { LARGE_ENTRY_TYPE, 12, LARGE_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { LARGE_ENTRY_TYPE, 13, LARGE_ENTRY_SIZE, TRUE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 } }; if ( pass ) { @@ -28890,156 +28890,156 @@ check_metadata_blizzard_absence(hbool_t fill_via_insertion) { /* entry entry in at main flush dep flush dep child flush flush flush */ /* type: index: size: cache: addr: dirty: prot: pinned: loaded: clrd: flshd: dest: par type: par idx: dep ref.count: dep height: order: */ - { entry_type, 0, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 1, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 2, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 3, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 4, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 5, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 6, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 7, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 8, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 9, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 10, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 11, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 12, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 13, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 14, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 15, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 16, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 17, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 18, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 19, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 20, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 21, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 22, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 23, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 24, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 25, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 26, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 27, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 28, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 29, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 30, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 31, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 32, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 33, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 34, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 35, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 36, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 37, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 38, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 39, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 40, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 41, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 42, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 43, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 44, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 45, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 46, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 47, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 48, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 49, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 50, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 51, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 52, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 53, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 54, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 55, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 56, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 57, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 58, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 59, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 60, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 61, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 62, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 63, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 64, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 65, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 66, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 67, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 68, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 69, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 70, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 71, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 72, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 73, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 74, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 75, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 76, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 77, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 78, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 79, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 80, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 81, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 82, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 83, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 84, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 85, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 86, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 87, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 88, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 89, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 90, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 91, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 92, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 93, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 94, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 95, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 96, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 97, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 98, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 99, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 100, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 101, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 102, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 103, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 104, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 105, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 106, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 107, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 108, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 109, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 110, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 111, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 112, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 113, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 114, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 115, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 116, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 117, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 118, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 119, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 120, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 121, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 122, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 123, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 124, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 125, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 126, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 127, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 128, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 129, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 130, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 131, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 132, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 133, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 134, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 135, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 136, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 137, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 138, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 139, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 140, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 141, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 142, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 143, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 144, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 145, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 146, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 147, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 148, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 149, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 } + { entry_type, 0, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 1, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 2, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 3, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 4, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 5, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 6, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 7, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 8, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 9, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 10, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 11, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 12, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 13, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 14, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 15, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 16, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 17, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 18, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 19, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 20, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 21, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 22, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 23, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 24, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 25, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 26, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 27, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 28, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 29, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 30, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 31, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 32, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 33, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 34, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 35, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 36, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 37, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 38, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 39, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 40, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 41, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 42, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 43, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 44, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 45, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 46, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 47, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 48, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 49, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 50, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 51, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 52, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 53, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 54, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 55, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 56, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 57, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 58, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 59, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 60, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 61, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 62, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 63, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 64, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 65, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 66, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 67, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 68, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 69, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 70, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 71, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 72, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 73, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 74, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 75, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 76, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 77, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 78, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 79, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 80, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 81, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 82, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 83, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 84, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 85, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 86, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 87, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 88, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 89, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 90, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 91, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 92, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 93, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 94, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 95, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 96, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 97, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 98, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 99, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 100, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 101, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 102, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 103, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 104, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 105, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 106, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 107, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 108, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 109, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 110, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 111, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 112, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 113, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 114, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 115, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 116, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 117, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 118, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 119, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 120, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 121, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 122, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 123, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 124, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 125, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 126, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 127, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 128, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 129, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 130, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 131, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 132, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 133, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 134, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 135, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 136, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 137, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 138, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 139, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 140, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 141, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 142, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 143, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 144, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 145, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 146, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 147, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 148, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 149, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 } }; pass = TRUE; @@ -29735,11 +29735,11 @@ check_flush_deps(void) { /* entry entry in at main flush dep flush dep child flush flush flush */ /* type: index: size: cache: addr: dirty: prot: pinned: loaded: clrd: flshd: dest: par type: par idx: dep ref.count: dep height: order: */ - { entry_type, 0, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 1, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 2, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 3, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 4, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 } + { entry_type, 0, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 1, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 2, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 3, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 4, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 } }; TESTING("flush dependencies"); @@ -31534,25 +31534,37 @@ check_flush_deps_err(void) protect_entry(cache_ptr, entry_type, 4); if ( !pass ) CACHE_ERROR("protect_entry failed") - result = H5C_create_flush_dependency(cache_ptr, &((entries[entry_type])[4]), &((entries[entry_type])[5])); - if( result != FAIL ) CACHE_ERROR("Creating second flush dependency for child") + create_flush_dependency(cache_ptr, entry_type, 4, entry_type, 5); + if ( !pass ) CACHE_ERROR("create_flush_dependency failed") + + protect_entry(cache_ptr, entry_type, 5); + if ( !pass ) CACHE_ERROR("protect_entry failed") + + create_flush_dependency(cache_ptr, entry_type, 5, entry_type, 6); + if ( !pass ) CACHE_ERROR("create_flush_dependency failed") + + protect_entry(cache_ptr, entry_type, 6); + if ( !pass ) CACHE_ERROR("protect_entry failed") + + result = H5C_create_flush_dependency(cache_ptr, &((entries[entry_type])[6]), &((entries[entry_type])[7])); + if( result != FAIL ) CACHE_ERROR("Creating flush dependency that's too tall") unprotect_entry(cache_ptr, /* H5C_t * cache_ptr */ entry_type, /* int32_t type */ - 4, /* int32_t idx */ + 6, /* int32_t idx */ FALSE, /* int32_t dirty */ H5C__NO_FLAGS_SET); /* unsigned int flags */ if ( !pass ) CACHE_ERROR("unprotect_entry failed") - protect_entry(cache_ptr, entry_type, 5); + protect_entry(cache_ptr, entry_type, 7); if ( !pass ) CACHE_ERROR("protect_entry failed") - result = H5C_create_flush_dependency(cache_ptr, &((entries[entry_type])[5]), &((entries[entry_type])[0])); - if( result != FAIL ) CACHE_ERROR("Creating second flush dependency for child") + result = H5C_create_flush_dependency(cache_ptr, &((entries[entry_type])[7]), &((entries[entry_type])[0])); + if( result != FAIL ) CACHE_ERROR("Creating flush dependency that's too tall") unprotect_entry(cache_ptr, /* H5C_t * cache_ptr */ entry_type, /* int32_t type */ - 5, /* int32_t idx */ + 7, /* int32_t idx */ FALSE, /* int32_t dirty */ H5C__NO_FLAGS_SET); /* unsigned int flags */ if ( !pass ) CACHE_ERROR("unprotect_entry failed") @@ -31596,6 +31608,26 @@ check_flush_deps_err(void) FALSE, /* int32_t dirty */ H5C__NO_FLAGS_SET); /* unsigned int flags */ if ( !pass ) CACHE_ERROR("unprotect_entry failed") + + destroy_flush_dependency(cache_ptr, entry_type, 4, entry_type, 5); + if ( !pass ) CACHE_ERROR("destroy_flush_dependency failed") + + unprotect_entry(cache_ptr, /* H5C_t * cache_ptr */ + entry_type, /* int32_t type */ + 4, /* int32_t idx */ + FALSE, /* int32_t dirty */ + H5C__NO_FLAGS_SET); /* unsigned int flags */ + if ( !pass ) CACHE_ERROR("unprotect_entry failed") + + destroy_flush_dependency(cache_ptr, entry_type, 5, entry_type, 6); + if ( !pass ) CACHE_ERROR("destroy_flush_dependency failed") + + unprotect_entry(cache_ptr, /* H5C_t * cache_ptr */ + entry_type, /* int32_t type */ + 5, /* int32_t idx */ + FALSE, /* int32_t dirty */ + H5C__NO_FLAGS_SET); /* unsigned int flags */ + if ( !pass ) CACHE_ERROR("unprotect_entry failed") break; /* Verify that parent entry must be protected */ @@ -31785,11 +31817,11 @@ check_flush_deps_order(void) { /* entry entry in at main flush dep flush dep child flush flush flush */ /* type: index: size: cache: addr: dirty: prot: pinned: loaded: clrd: flshd: dest: par type: par idx: dep ref.count: dep height: order: */ - { entry_type, 0, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 1, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 2, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 3, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 4, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 } + { entry_type, 0, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 1, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 2, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 3, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 4, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 } }; unsigned flush_order; /* Index for tracking flush order */ @@ -33815,11 +33847,11 @@ check_notify_cb(void) { /* entry entry in at main flush dep flush dep child flush flush flush */ /* type: index: size: cache: addr: dirty: prot: pinned: loaded: clrd: flshd: dest: par type: par idx: dep ref.count: dep height: order: */ - { entry_type, 0, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 1, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 2, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 3, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 }, - { entry_type, 4, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0}, 0, -1 } + { entry_type, 0, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 1, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 2, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 3, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 }, + { entry_type, 4, entry_size, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, -1, -1, {0,0,0,0,0,0}, 0, -1 } }; TESTING("'notify' callback"); diff --git a/test/earray.c b/test/earray.c index 5b8ac1a..fe5cb99 100644 --- a/test/earray.c +++ b/test/earray.c @@ -135,6 +135,38 @@ struct earray_test_param_t { H5EA_sblk_info_t *sblk_info; /* Array of information for each super block */ }; +/* Flush depend test context */ +typedef struct earray_flush_depend_ctx_t { + hbool_t base_obj; /* Flag to indicate that base object has been flushed */ + hbool_t idx0_obj; /* Flag to indicate that index 0's object has been flushed */ + hbool_t idx0_elem; /* Flag to indicate that index 0's element has been flushed */ + hbool_t idx1_obj; /* Flag to indicate that index 1's object has been flushed */ + hbool_t idx1_elem; /* Flag to indicate that index 1's element has been flushed */ + hbool_t idx10000_obj; /* Flag to indicate that index 10000's object has been flushed */ + hbool_t idx10000_elem; /* Flag to indicate that index 10000's element has been flushed */ +} earray_flush_depend_ctx_t; + +/* Extensible array test cache object */ +typedef struct earray_test_t { + /* Information for H5AC cache functions, _must_ be first field in structure */ + H5AC_info_t cache_info; + + /* Entry information */ + uint64_t idx; /* Index that entry corresponds to */ + earray_flush_depend_ctx_t *fd_info; /* Context information for flush depend test */ +} earray_test_t; + + +/* Local prototypes */ + +/* Metadata cache (H5AC) callbacks */ +static earray_test_t *earray_cache_test_load(H5F_t *f, hid_t dxpl_id, haddr_t addr, const void *udata, void *udata2); +static herr_t earray_cache_test_flush(H5F_t *f, hid_t dxpl_id, hbool_t destroy, haddr_t addr, earray_test_t *test, unsigned * flags_ptr); +static herr_t earray_cache_test_clear(H5F_t *f, earray_test_t *test, hbool_t destroy); +static herr_t earray_cache_test_size(const H5F_t *f, const earray_test_t *test, size_t *size_ptr); +static herr_t earray_cache_test_dest(H5F_t *f, earray_test_t *test); + + /* Local variables */ const char *FILENAME[] = { "earray", @@ -147,8 +179,17 @@ char filename_g[EARRAY_FILENAME_LEN]; /* Empty file size */ h5_stat_size_t empty_size_g; +/* H5EA test object inherits cache-like properties from H5AC */ +const H5AC_class_t H5AC_EARRAY_TEST[1] = {{ + H5AC_TEST_ID, + (H5AC_load_func_t)earray_cache_test_load, + (H5AC_flush_func_t)earray_cache_test_flush, + (H5AC_dest_func_t)earray_cache_test_dest, + (H5AC_clear_func_t)earray_cache_test_clear, + (H5AC_notify_func_t)NULL, + (H5AC_size_func_t)earray_cache_test_size, +}}; -/* Local prototypes */ /*------------------------------------------------------------------------- @@ -439,13 +480,13 @@ error: */ static int create_array(H5F_t *f, hid_t dxpl, const H5EA_create_t *cparam, - H5EA_t **ea, haddr_t *ea_addr) + H5EA_t **ea, haddr_t *ea_addr, H5EA__ctx_cb_t *cb) { hsize_t nelmts; /* Number of elements in array */ earray_state_t state; /* State of extensible array */ /* Create array */ - if(NULL == (*ea = H5EA_create(f, dxpl, cparam, NULL))) + if(NULL == (*ea = H5EA_create(f, dxpl, cparam, cb))) FAIL_STACK_ERROR /* Check status of array */ @@ -561,6 +602,199 @@ error: /*------------------------------------------------------------------------- + * Function: earray_cache_test_load + * + * Purpose: Loads an extensible array test object from the disk. + * + * Return: Success: Pointer to a new extensible array test object + * Failure: NULL + * + * Programmer: Quincey Koziol + * koziol@hdfgroup.org + * May 26 2009 + * + *------------------------------------------------------------------------- + */ +static earray_test_t * +earray_cache_test_load(H5F_t UNUSED *f, hid_t UNUSED dxpl_id, haddr_t UNUSED addr, const void UNUSED *udata1, void UNUSED *udata2) +{ + /* Check arguments */ + HDassert(f); + HDassert(H5F_addr_defined(addr)); + + /* Should never be called */ + HDassert(0 && "Can't be called!"); + + return(NULL); +} /* end earray_cache_test_load() */ + + +/*------------------------------------------------------------------------- + * Function: earray_cache_test_flush + * + * Purpose: Flushes a dirty extensible array test object to disk. + * + * Return: Non-negative on success/Negative on failure + * + * Programmer: Quincey Koziol + * koziol@hdfgroup.org + * May 26 2009 + * + *------------------------------------------------------------------------- + */ +static herr_t +earray_cache_test_flush(H5F_t UNUSED *f, hid_t UNUSED dxpl_id, hbool_t destroy, haddr_t UNUSED addr, earray_test_t *test, unsigned UNUSED * flags_ptr) +{ + /* check arguments */ + HDassert(f); + HDassert(H5F_addr_defined(addr)); + HDassert(test); + + if(test->cache_info.is_dirty) { + /* Check for out of order flush */ + if(test->fd_info->base_obj) + TEST_ERROR + + /* Check which index this entry corresponds to */ + if((uint64_t)0 == test->idx) { + /* Check for out of order flush */ + if(test->fd_info->idx0_obj || test->fd_info->idx0_elem) + TEST_ERROR + + /* Set flag for object flush */ + test->fd_info->idx0_obj = TRUE; + } /* end if */ + else if((uint64_t)1 == test->idx) { + /* Check for out of order flush */ + if(test->fd_info->idx1_obj || test->fd_info->idx1_elem) + TEST_ERROR + + /* Set flag for object flush */ + test->fd_info->idx1_obj = TRUE; + } /* end if */ + else if((uint64_t)10000 == test->idx) { + /* Check for out of order flush */ + if(test->fd_info->idx10000_obj || test->fd_info->idx10000_elem) + TEST_ERROR + + /* Set flag for object flush */ + test->fd_info->idx10000_obj = TRUE; + } /* end if */ + else if((uint64_t)-1 == test->idx) { + /* Set flag for object flush */ + test->fd_info->base_obj = TRUE; + } /* end if */ + + /* Mark the entry as clean */ + test->cache_info.is_dirty = FALSE; + } /* end if */ + + if(destroy) + if(earray_cache_test_dest(f, test) < 0) + TEST_ERROR + + return(SUCCEED); + +error: + return(FAIL); +} /* earray_cache_test_flush() */ + + +/*------------------------------------------------------------------------- + * Function: earray_cache_test_dest + * + * Purpose: Destroys an extensible array test object in memory. + * + * Return: Non-negative on success/Negative on failure + * + * Programmer: Quincey Koziol + * koziol@hdfgroup.org + * May 26 2009 + * + *------------------------------------------------------------------------- + */ +herr_t +earray_cache_test_dest(H5F_t UNUSED *f, earray_test_t *test) +{ + /* + * Check arguments. + */ + HDassert(test); + + /* Free the shared info itself */ + HDfree(test); + + return(SUCCEED); +} /* end earray_cache_test_dest() */ + + +/*------------------------------------------------------------------------- + * Function: earray_cache_test_clear + * + * Purpose: Mark an extensible array test object in memory as non-dirty. + * + * Return: Non-negative on success/Negative on failure + * + * Programmer: Quincey Koziol + * koziol@hdfgroup.org + * May 26 2009 + * + *------------------------------------------------------------------------- + */ +static herr_t +earray_cache_test_clear(H5F_t *f, earray_test_t *test, hbool_t destroy) +{ + /* + * Check arguments. + */ + HDassert(test); + + /* Reset the dirty flag. */ + test->cache_info.is_dirty = FALSE; + + if(destroy) + if(earray_cache_test_dest(f, test) < 0) + TEST_ERROR + + return(SUCCEED); + +error: + return(FAIL); +} /* end earray_cache_test_clear() */ + + +/*------------------------------------------------------------------------- + * Function: earray_cache_test_size + * + * Purpose: Compute the size in bytes of an extensible array test object + * on disk, and return it in *size_ptr. On failure, + * the value of *size_ptr is undefined. + * + * Return: Non-negative on success/Negative on failure + * + * Programmer: Quincey Koziol + * koziol@hdfgroup.org + * May 26 2009 + * + *------------------------------------------------------------------------- + */ +static herr_t +earray_cache_test_size(const H5F_t UNUSED *f, const earray_test_t UNUSED *test, size_t *size_ptr) +{ + /* check arguments */ + HDassert(f); + HDassert(test); + HDassert(size_ptr); + + /* Set size value */ + /* (hard-code to 1) */ + *size_ptr = 1; + + return(SUCCEED); +} /* earray_cache_test_size() */ + + +/*------------------------------------------------------------------------- * Function: test_create * * Purpose: Test creating extensible array @@ -750,7 +984,7 @@ test_create(hid_t fapl, H5EA_create_t *cparam, earray_test_param_t UNUSED *tpara TESTING("extensible array creation"); /* Create array */ - if(create_array(f, H5P_DATASET_XFER_DEFAULT, cparam, &ea, &ea_addr) < 0) + if(create_array(f, H5P_DATASET_XFER_DEFAULT, cparam, &ea, &ea_addr, NULL) < 0) TEST_ERROR PASSED() @@ -813,7 +1047,7 @@ test_reopen(hid_t fapl, H5EA_create_t *cparam, earray_test_param_t *tparam) TESTING("create, close & reopen extensible array"); /* Create array */ - if(create_array(f, H5P_DATASET_XFER_DEFAULT, cparam, &ea, &ea_addr) < 0) + if(create_array(f, H5P_DATASET_XFER_DEFAULT, cparam, &ea, &ea_addr, NULL) < 0) TEST_ERROR /* Close the extensible array */ @@ -886,7 +1120,7 @@ test_open_twice(hid_t fapl, H5EA_create_t *cparam, earray_test_param_t *tparam) TESTING("open extensible array twice"); /* Create array */ - if(create_array(f, H5P_DATASET_XFER_DEFAULT, cparam, &ea, &ea_addr) < 0) + if(create_array(f, H5P_DATASET_XFER_DEFAULT, cparam, &ea, &ea_addr, NULL) < 0) TEST_ERROR /* Open the array again, through the first file handle */ @@ -992,7 +1226,7 @@ test_delete_open(hid_t fapl, H5EA_create_t *cparam, earray_test_param_t *tparam) TESTING("deleting open extensible array"); /* Create array */ - if(create_array(f, H5P_DATASET_XFER_DEFAULT, cparam, &ea, &ea_addr) < 0) + if(create_array(f, H5P_DATASET_XFER_DEFAULT, cparam, &ea, &ea_addr, NULL) < 0) TEST_ERROR /* Open the array again */ @@ -1076,6 +1310,296 @@ error: return 1; } /* test_delete_open() */ + +/*------------------------------------------------------------------------- + * Function: test_flush_depend_cb + * + * Purpose: Callback for flush dependency 'depend'/'undepend' and + * 'support'/'unsupport' routines + * + * Return: Success: 0 + * Failure: 1 + * + * Programmer: Quincey Koziol + * Tuesday, May 26, 2009 + * + *------------------------------------------------------------------------- + */ +static herr_t +test_flush_depend_cb(const void *_elmt, size_t nelmts, void *udata) +{ + earray_flush_depend_ctx_t *ctx = (earray_flush_depend_ctx_t *)udata; + const uint64_t *elmt = (const uint64_t *)_elmt; /* Convenience pointer to native elements */ + + /* Check for out of order flush */ + if(ctx->base_obj) + return(FAIL); + + /* Look for magic values */ + while(nelmts > 0) { + /* Check for elements of interest */ + if((uint64_t)0 == *elmt) { + /* Check for out-of-order flush */ + if(!ctx->idx0_obj) + return(FAIL); + + /* Indicate that the element was flushed */ + ctx->idx0_elem = TRUE; + } /* end if */ + else if((uint64_t)1 == *elmt) { + /* Check for out-of-order flush */ + if(!ctx->idx1_obj) + return(FAIL); + + /* Indicate that the element was flushed */ + ctx->idx1_elem = TRUE; + } /* end if */ + else if((uint64_t)10000 == *elmt) { + /* Check for out-of-order flush */ + if(!ctx->idx10000_obj) + return(FAIL); + + /* Indicate that the element was flushed */ + ctx->idx10000_elem = TRUE; + } /* end if */ + + /* Decrement elements left to inspect */ + nelmts--; + elmt++; + } /* end while */ + + return(SUCCEED); +} /* end test_flush_depend_cb() */ + + +/*------------------------------------------------------------------------- + * Function: test_flush_depend + * + * Purpose: Exercise flush dependency 'depend'/'undepend' routines + * + * Return: Success: 0 + * Failure: 1 + * + * Programmer: Quincey Koziol + * Thursday, May 21, 2009 + * + *------------------------------------------------------------------------- + */ +static unsigned +test_flush_depend(hid_t fapl, H5EA_create_t *cparam, earray_test_param_t UNUSED *tparam) +{ + hid_t file = -1; /* File ID */ + H5F_t *f = NULL; /* Internal file object pointer */ + H5EA_t *ea = NULL; /* Extensible array wrapper */ + haddr_t ea_addr = HADDR_UNDEF; /* Array address in file */ + H5EA__ctx_cb_t cb; /* Extensible array context action info */ + earray_flush_depend_ctx_t fd_info; /* Context information for flush depend test */ + haddr_t base_addr; /* Base test entry address */ + earray_test_t *base_entry; /* Pointer to base test entry */ + haddr_t addr1; /* Test entry #1 address */ + earray_test_t *entry1; /* Pointer to test entry #1 */ + haddr_t addr2; /* Test entry #2 address */ + earray_test_t *entry2; /* Pointer to test entry #2 */ + haddr_t addr3; /* Test entry #3 address */ + earray_test_t *entry3; /* Pointer to test entry #3 */ + uint64_t welmt; /* Element to write */ + hsize_t idx; /* Index value of element */ + + /* Create file & retrieve pointer to internal file object */ + if(create_file(fapl, &file, &f) < 0) + TEST_ERROR + + /* + * Display testing message + */ + TESTING("flush dependencies on array metadata"); + + /* Create array */ + cb.encode = test_flush_depend_cb; + HDmemset(&fd_info, 0, sizeof(earray_flush_depend_ctx_t)); + cb.udata = &fd_info; + if(create_array(f, H5P_DATASET_XFER_DEFAULT, cparam, &ea, &ea_addr, &cb) < 0) + TEST_ERROR + + /* Verify the creation parameters */ + if(verify_cparam(ea, cparam) < 0) + TEST_ERROR + + /* Create base entry to insert */ + if(NULL == (base_entry = (earray_test_t *)HDmalloc(sizeof(earray_test_t)))) + TEST_ERROR + HDmemset(base_entry, 0, sizeof(earray_test_t)); + base_entry->idx = (uint64_t)-1; + base_entry->fd_info = &fd_info; + + /* Insert test entry into cache */ + base_addr = HADDR_MAX; + if(H5AC_set(f, H5P_DATASET_XFER_DEFAULT, H5AC_EARRAY_TEST, base_addr, base_entry, H5AC__PIN_ENTRY_FLAG) < 0) + TEST_ERROR + + /* Set the base entry as a flush dependency for the array */ + if(H5EA_depend((H5AC_info_t *)base_entry, ea) < 0) + TEST_ERROR + + /* Create entry #1 to insert */ + if(NULL == (entry1 = (earray_test_t *)HDmalloc(sizeof(earray_test_t)))) + TEST_ERROR + HDmemset(entry1, 0, sizeof(earray_test_t)); + entry1->fd_info = &fd_info; + + /* Insert test entry into cache */ + addr1 = HADDR_MAX - 1; + if(H5AC_set(f, H5P_DATASET_XFER_DEFAULT, H5AC_EARRAY_TEST, addr1, entry1, H5AC__PIN_ENTRY_FLAG) < 0) + TEST_ERROR + + /* Set the test entry as a flush dependency for 0th index in the array */ + if(H5EA_support(ea, H5P_DATASET_XFER_DEFAULT, (hsize_t)0, (H5AC_info_t *)entry1) < 0) + TEST_ERROR + + /* Set element of array */ + welmt = (uint64_t)0; + idx = 0; + if(H5EA_set(ea, H5P_DATASET_XFER_DEFAULT, idx, &welmt) < 0) + FAIL_STACK_ERROR + + /* Create entry #2 to insert */ + if(NULL == (entry2 = (earray_test_t *)HDmalloc(sizeof(earray_test_t)))) + TEST_ERROR + HDmemset(entry2, 0, sizeof(earray_test_t)); + entry2->idx = (uint64_t)1; + entry2->fd_info = &fd_info; + + /* Insert test entry into cache */ + addr2 = HADDR_MAX - 2; + if(H5AC_set(f, H5P_DATASET_XFER_DEFAULT, H5AC_EARRAY_TEST, addr2, entry2, H5AC__PIN_ENTRY_FLAG) < 0) + TEST_ERROR + + /* Set the test entry as a flush dependency for 1st index in the array */ + if(H5EA_support(ea, H5P_DATASET_XFER_DEFAULT, (hsize_t)1, (H5AC_info_t *)entry2) < 0) + TEST_ERROR + + /* Set element of array */ + welmt = (uint64_t)1; + idx = 1; + if(H5EA_set(ea, H5P_DATASET_XFER_DEFAULT, idx, &welmt) < 0) + FAIL_STACK_ERROR + + /* Create entry #3 to insert */ + if(NULL == (entry3 = (earray_test_t *)HDmalloc(sizeof(earray_test_t)))) + TEST_ERROR + HDmemset(entry3, 0, sizeof(earray_test_t)); + entry3->idx = (uint64_t)10000; + entry3->fd_info = &fd_info; + + /* Insert test entry into cache */ + addr3 = HADDR_MAX - 3; + if(H5AC_set(f, H5P_DATASET_XFER_DEFAULT, H5AC_EARRAY_TEST, addr3, entry3, H5AC__PIN_ENTRY_FLAG) < 0) + TEST_ERROR + + /* Set the test entry as a flush dependency for 10,000th index in the array */ + if(H5EA_support(ea, H5P_DATASET_XFER_DEFAULT, (hsize_t)10000, (H5AC_info_t *)entry3) < 0) + TEST_ERROR + + /* Set element of array */ + welmt = (uint64_t)10000; + idx = 10000; + if(H5EA_set(ea, H5P_DATASET_XFER_DEFAULT, idx, &welmt) < 0) + FAIL_STACK_ERROR + + + /* Flush the cache */ + if(H5Fflush(file, H5F_SCOPE_GLOBAL) < 0) + TEST_ERROR + + /* Check that all callback flags have been set */ + if(!fd_info.base_obj) + TEST_ERROR + if(!fd_info.idx0_obj) + TEST_ERROR + if(!fd_info.idx0_elem) + TEST_ERROR + if(!fd_info.idx1_obj) + TEST_ERROR + if(!fd_info.idx1_elem) + TEST_ERROR + if(!fd_info.idx10000_obj) + TEST_ERROR + if(!fd_info.idx10000_elem) + TEST_ERROR + + + /* Remove the base entry as a flush dependency for the array */ + if(H5EA_undepend((H5AC_info_t *)base_entry, ea) < 0) + TEST_ERROR + + /* Protect the base entry */ + if(NULL == (base_entry = (earray_test_t *)H5AC_protect(f, H5P_DATASET_XFER_DEFAULT, H5AC_EARRAY_TEST, base_addr, NULL, NULL, H5AC_WRITE))) + TEST_ERROR + + /* Unprotect & unpin the base entry */ + if(H5AC_unprotect(f, H5P_DATASET_XFER_DEFAULT, H5AC_EARRAY_TEST, base_addr, base_entry, (H5AC__UNPIN_ENTRY_FLAG | H5AC__DELETED_FLAG)) < 0) + TEST_ERROR + + /* Remove the test entry as a flush dependency for 0th index in the array */ + if(H5EA_unsupport(ea, H5P_DATASET_XFER_DEFAULT, (hsize_t)0, (H5AC_info_t *)entry1) < 0) + TEST_ERROR + + /* Protect the test entry */ + if(NULL == (entry1 = (earray_test_t *)H5AC_protect(f, H5P_DATASET_XFER_DEFAULT, H5AC_EARRAY_TEST, addr1, NULL, NULL, H5AC_WRITE))) + TEST_ERROR + + /* Unprotect & unpin the test entry */ + if(H5AC_unprotect(f, H5P_DATASET_XFER_DEFAULT, H5AC_EARRAY_TEST, addr1, entry1, (H5AC__UNPIN_ENTRY_FLAG | H5AC__DELETED_FLAG)) < 0) + TEST_ERROR + + /* Remove the test entry as a flush dependency for 1st index in the array */ + if(H5EA_unsupport(ea, H5P_DATASET_XFER_DEFAULT, (hsize_t)1, (H5AC_info_t *)entry2) < 0) + TEST_ERROR + + /* Protect the test entry */ + if(NULL == (entry2 = (earray_test_t *)H5AC_protect(f, H5P_DATASET_XFER_DEFAULT, H5AC_EARRAY_TEST, addr2, NULL, NULL, H5AC_WRITE))) + TEST_ERROR + + /* Unprotect & unpin the test entry */ + if(H5AC_unprotect(f, H5P_DATASET_XFER_DEFAULT, H5AC_EARRAY_TEST, addr2, entry2, (H5AC__UNPIN_ENTRY_FLAG | H5AC__DELETED_FLAG)) < 0) + TEST_ERROR + + /* Remove the test entry as a flush dependency for 10,000th index in the array */ + if(H5EA_unsupport(ea, H5P_DATASET_XFER_DEFAULT, (hsize_t)10000, (H5AC_info_t *)entry3) < 0) + TEST_ERROR + + /* Protect the test entry */ + if(NULL == (entry3 = (earray_test_t *)H5AC_protect(f, H5P_DATASET_XFER_DEFAULT, H5AC_EARRAY_TEST, addr3, NULL, NULL, H5AC_WRITE))) + TEST_ERROR + + /* Unprotect & unpin the test entry */ + if(H5AC_unprotect(f, H5P_DATASET_XFER_DEFAULT, H5AC_EARRAY_TEST, addr3, entry3, (H5AC__UNPIN_ENTRY_FLAG | H5AC__DELETED_FLAG)) < 0) + TEST_ERROR + + /* Close the extensible array */ + if(H5EA_close(ea, H5P_DATASET_XFER_DEFAULT) < 0) + FAIL_STACK_ERROR + ea = NULL; + + /* Close the file */ + if(H5Fclose(file) < 0) + FAIL_STACK_ERROR + + /* All tests passed */ + PASSED() + + return 0; + +error: + H5E_BEGIN_TRY { + if(ea) + H5EA_close(ea, H5P_DATASET_XFER_DEFAULT); + H5Fclose(file); + } H5E_END_TRY; + + return 1; +} /* test_flush_depend() */ + /* Extensible array iterator info for forward iteration */ typedef struct eiter_fw_t { hsize_t idx; /* Index of next array location */ @@ -1822,7 +2346,7 @@ eiter_cyc_next(void *_eiter) HDassert(eiter); /* Get the next array index to test */ - ret_val = eiter->pos; + ret_val = (hssize_t)eiter->pos; eiter->pos += EA_CYC_COUNT; if(eiter->pos >= eiter->cnt) eiter->pos = ++eiter->cyc; @@ -1940,7 +2464,7 @@ test_set_elmts(hid_t fapl, H5EA_create_t *cparam, earray_test_param_t *tparam, TEST_ERROR /* Create array */ - if(create_array(f, H5P_DATASET_XFER_DEFAULT, cparam, &ea, &ea_addr) < 0) + if(create_array(f, H5P_DATASET_XFER_DEFAULT, cparam, &ea, &ea_addr, NULL) < 0) TEST_ERROR /* Verify the creation parameters */ @@ -2114,7 +2638,7 @@ test_skip_elmts(hid_t fapl, H5EA_create_t *cparam, earray_test_param_t *tparam, TEST_ERROR /* Create array */ - if(create_array(f, H5P_DATASET_XFER_DEFAULT, cparam, &ea, &ea_addr) < 0) + if(create_array(f, H5P_DATASET_XFER_DEFAULT, cparam, &ea, &ea_addr, NULL) < 0) TEST_ERROR /* Verify the creation parameters */ @@ -2322,6 +2846,7 @@ main(void) nerrors += test_reopen(fapl, &cparam, &tparam); nerrors += test_open_twice(fapl, &cparam, &tparam); nerrors += test_delete_open(fapl, &cparam, &tparam); + nerrors += test_flush_depend(fapl, &cparam, &tparam); /* Iterate over the type of capacity tests */ for(curr_iter = EARRAY_ITER_FW; curr_iter < EARRAY_ITER_NITERS; curr_iter++) { @@ -2378,7 +2903,7 @@ main(void) for(sblk = 0; sblk < 9; sblk++) { for(dblk = 0; dblk < tparam.sblk_info[sblk].ndblks; dblk ++) { /* Test first element in data block */ - nelmts = (hsize_t)(1 + cparam.idx_blk_elmts + + nelmts = (hsize_t)((hsize_t)1 + cparam.idx_blk_elmts + tparam.sblk_info[sblk].start_idx + (tparam.sblk_info[sblk].dblk_nelmts * dblk)); sprintf(test_str, "setting first element of array's data block #%llu", (unsigned long long)ndblks); diff --git a/tools/h5diff/testfiles/h5diff_201.txt b/tools/h5diff/testfiles/h5diff_201.txt index a212444..84d6766 100644 --- a/tools/h5diff/testfiles/h5diff_201.txt +++ b/tools/h5diff/testfiles/h5diff_201.txt @@ -1 +1 @@ -Not comparable: or are empty datasets +Not comparable: or is an empty dataset diff --git a/tools/h5diff/testfiles/h5diff_202.txt b/tools/h5diff/testfiles/h5diff_202.txt index ee240c2..fd4a191 100644 --- a/tools/h5diff/testfiles/h5diff_202.txt +++ b/tools/h5diff/testfiles/h5diff_202.txt @@ -1,2 +1,2 @@ - is of class H5T_FLOAT and is of class H5T_INTEGER +Not comparable: is of class H5T_FLOAT and is of class H5T_INTEGER Not comparable: has sign H5T_SGN_ERROR and has sign H5T_SGN_2 diff --git a/tools/h5diff/testfiles/h5diff_203.txt b/tools/h5diff/testfiles/h5diff_203.txt index 49ee21c..496523c 100644 --- a/tools/h5diff/testfiles/h5diff_203.txt +++ b/tools/h5diff/testfiles/h5diff_203.txt @@ -1,2 +1,2 @@ Not comparable: has rank 1, dimensions [6], max dimensions [6] - has rank 2, dimensions [3x2], max dimensions [3x2] +and has rank 2, dimensions [3x2], max dimensions [3x2] diff --git a/tools/h5diff/testfiles/h5diff_204.txt b/tools/h5diff/testfiles/h5diff_204.txt index 5a3d87f..098a203 100644 --- a/tools/h5diff/testfiles/h5diff_204.txt +++ b/tools/h5diff/testfiles/h5diff_204.txt @@ -1,2 +1,2 @@ Not comparable: has rank 2, dimensions [3x2], max dimensions [3x2] - has rank 2, dimensions [2x2], max dimensions [2x2] +and has rank 2, dimensions [2x2], max dimensions [2x2] diff --git a/tools/h5diff/testfiles/h5diff_205.txt b/tools/h5diff/testfiles/h5diff_205.txt index 81298af..3e2d1f2 100644 --- a/tools/h5diff/testfiles/h5diff_205.txt +++ b/tools/h5diff/testfiles/h5diff_205.txt @@ -1,3 +1,3 @@ Not comparable: has rank 2, dimensions [2x2], max dimensions [2x2] - has rank 2, dimensions [3x2], max dimensions [3x2] +and has rank 2, dimensions [3x2], max dimensions [3x2] Not comparable: has sign H5T_SGN_2 and has sign H5T_SGN_NONE diff --git a/tools/h5diff/testfiles/h5diff_207.txt b/tools/h5diff/testfiles/h5diff_207.txt index f8152f8..bb8e23f 100644 --- a/tools/h5diff/testfiles/h5diff_207.txt +++ b/tools/h5diff/testfiles/h5diff_207.txt @@ -1,2 +1,2 @@ -Not comparable: or are empty datasets +Not comparable: or is an empty dataset Not comparable: has 2 members has 1 members diff --git a/tools/h5diff/testfiles/h5diff_70.txt b/tools/h5diff/testfiles/h5diff_70.txt index b42cacd..30dbefe 100644 --- a/tools/h5diff/testfiles/h5diff_70.txt +++ b/tools/h5diff/testfiles/h5diff_70.txt @@ -677,7 +677,7 @@ position float3D of float3D of difference [ 3 2 1 ] 24 0 24 24 differences found dataset: and -Not comparable: or are empty datasets +Not comparable: or is an empty dataset attribute: > and > size: [2] [2] position string of string of difference diff --git a/tools/h5diff/testfiles/h5diff_80.txt b/tools/h5diff/testfiles/h5diff_80.txt index c8ec309..33090df 100644 --- a/tools/h5diff/testfiles/h5diff_80.txt +++ b/tools/h5diff/testfiles/h5diff_80.txt @@ -245,7 +245,7 @@ position array3D array3D difference [ 3 2 1 ] 72 0 72 72 differences found dataset: and -Not comparable: or are empty datasets +Not comparable: or is an empty dataset 0 differences found dataset: and size: [2] [2] @@ -380,10 +380,10 @@ position enum enum difference [ 0 ] RED GREEN 1 differences found dataset: and -Not comparable: or are empty datasets +Not comparable: or is an empty dataset 0 differences found dataset: and -Not comparable: or are empty datasets +Not comparable: or is an empty dataset 0 differences found dataset: and size: [2] [2] diff --git a/tools/h5diff/testfiles/h5diff_90.txt b/tools/h5diff/testfiles/h5diff_90.txt index a513ffa..e6bfa14 100644 --- a/tools/h5diff/testfiles/h5diff_90.txt +++ b/tools/h5diff/testfiles/h5diff_90.txt @@ -30,7 +30,7 @@ dataset: and group : and 0 differences found dataset: and -Not comparable: or are empty datasets +Not comparable: or is an empty dataset 0 differences found dataset: and 0 differences found @@ -47,7 +47,7 @@ dataset: and dataset: and 0 differences found dataset: and -Not comparable: or are empty datasets +Not comparable: or is an empty dataset 0 differences found -------------------------------- Some objects are not comparable diff --git a/tools/lib/h5diff_dset.c b/tools/lib/h5diff_dset.c index 0f53192..7f2a80a 100644 --- a/tools/lib/h5diff_dset.c +++ b/tools/lib/h5diff_dset.c @@ -267,7 +267,7 @@ hsize_t diff_datasetid( hid_t did1, if (storage_size1==0 || storage_size2==0) { if ( (options->m_verbose||options->m_list_not_cmp) && obj1_name && obj2_name) - parallel_print("Not comparable: <%s> or <%s> are empty datasets\n", obj1_name, obj2_name); + parallel_print("Not comparable: <%s> or <%s> is an empty dataset\n", obj1_name, obj2_name); can_compare=0; options->not_cmp=1; } @@ -708,7 +708,7 @@ int diff_can_type( hid_t f_tid1, /* file data type */ { - parallel_print("<%s> is of class %s and <%s> is of class %s\n", + parallel_print("Not comparable: <%s> is of class %s and <%s> is of class %s\n", obj1_name, get_class(tclass1), obj2_name, get_class(tclass2) ); @@ -788,6 +788,7 @@ int diff_can_type( hid_t f_tid1, /* file data type */ *------------------------------------------------------------------------- */ + if ( rank1 != rank2 ) { @@ -798,7 +799,7 @@ int diff_can_type( hid_t f_tid1, /* file data type */ parallel_print(", max dimensions "); print_dimensions(rank1,maxdim1); parallel_print("\n" ); - parallel_print("<%s> has rank %d, dimensions ", obj2_name, rank2); + parallel_print("and <%s> has rank %d, dimensions ", obj2_name, rank2); print_dimensions(rank2,dims2); parallel_print(", max dimensions "); print_dimensions(rank2,maxdim2); @@ -843,7 +844,7 @@ int diff_can_type( hid_t f_tid1, /* file data type */ parallel_print(", max dimensions "); print_dimensions(rank1,maxdim1); parallel_print("\n" ); - parallel_print("<%s> has rank %d, dimensions ", obj2_name, rank2); + parallel_print("and <%s> has rank %d, dimensions ", obj2_name, rank2); print_dimensions(rank2,dims2); parallel_print(", max dimensions "); print_dimensions(rank2,maxdim2); diff --git a/vms/src/h5pubconf.h b/vms/src/h5pubconf.h index 238c655..557f884 100644 --- a/vms/src/h5pubconf.h +++ b/vms/src/h5pubconf.h @@ -480,13 +480,13 @@ #define H5_PACKAGE_NAME "HDF5" /* Define to the full name and version of this package. */ -#define H5_PACKAGE_STRING "HDF5 1.9.39" +#define H5_PACKAGE_STRING "HDF5 1.9.41" /* Define to the one symbol short name of this package. */ #define H5_PACKAGE_TARNAME "hdf5" /* Define to the version of this package. */ -#define H5_PACKAGE_VERSION "1.9.39" +#define H5_PACKAGE_VERSION "1.9.41" /* Width for printf() for type `long long' or `__int64', use `ll' */ #define H5_PRINTF_LL_WIDTH "ll" @@ -639,7 +639,7 @@ /* #undef H5_USING_MEMCHECKER */ /* Version number of package */ -#define H5_VERSION "1.9.39" +#define H5_VERSION "1.9.41" /* Define if vsnprintf() returns the correct value for formatted strings that don't fit into size allowed */ diff --git a/windows/src/H5pubconf.h b/windows/src/H5pubconf.h index c02dede..f580234 100755 --- a/windows/src/H5pubconf.h +++ b/windows/src/H5pubconf.h @@ -479,13 +479,13 @@ #define H5_PACKAGE_NAME "HDF5" /* Define to the full name and version of this package. */ -#define H5_PACKAGE_STRING "HDF5 1.9.39" +#define H5_PACKAGE_STRING "HDF5 1.9.41" /* Define to the one symbol short name of this package. */ #define H5_PACKAGE_TARNAME "hdf5" /* Define to the version of this package. */ -#define H5_PACKAGE_VERSION "1.9.39" +#define H5_PACKAGE_VERSION "1.9.41" /* Width for printf() for type `long long' or `__int64', use `ll' */ #define H5_PRINTF_LL_WIDTH "I64" @@ -642,7 +642,7 @@ /* #undef H5_USING_MEMCHECKER */ /* Version number of package */ -#define H5_VERSION "1.9.39" +#define H5_VERSION "1.9.41" /* Define if vsnprintf() returns the correct value for formatted strings that don't fit into size allowed */ -- cgit v0.12