diff options
author | Robb Matzke <matzke@llnl.gov> | 1997-10-20 23:14:35 (GMT) |
---|---|---|
committer | Robb Matzke <matzke@llnl.gov> | 1997-10-20 23:14:35 (GMT) |
commit | 56ad55117a89a423a9341d2f0c3912d4ad57ec6f (patch) | |
tree | dff0bada659180ac324d81a4d97f7bfb884f0ed6 /src/H5Gshad.c | |
parent | dc4961d072249ddf39a7db7a945ea627c276d025 (diff) | |
download | hdf5-56ad55117a89a423a9341d2f0c3912d4ad57ec6f.zip hdf5-56ad55117a89a423a9341d2f0c3912d4ad57ec6f.tar.gz hdf5-56ad55117a89a423a9341d2f0c3912d4ad57ec6f.tar.bz2 |
[svn-r129] Changes since 19970916
----------------------
./config/depend.in
Fixed backslashes in sed script because the H5Gnode.c
dependency info was disappearing. You'll have to rerun
config.status to rebuild the Makefiles unless you use gnu
make.
./config/conclude.in
Also removes emacs backup files, TAGS, and svf backup files.
./config/linux
Grouped gcc flags and added provisions for debugging vs. production.
./html/H5.format.html
Updated messages 0x0008, 0x0009, and 0x000A.
./html/storage.html
Documentation describing storage schemes.
./src/Makefile.in
./test/Makefile.in
New source files.
./src/H5A.c
./src/H5Apublic.h
./src/H5C.c
Changed VOIDP to void* in a couple places.
./src/H5AC.c
./src/H5ACprivate.h
./src/H5B.c
./src/H5Bprivate.h
./src/H5G.c
./src/H5Gnode.c
./src/H5Gprivate.h
./src/H5H.c
./src/H5O.c
Removed `const' from some variables because H5G_node_found() wanted
to modify it's udata argument. Removing const there caused it
to cascade to these other locations.
./src/H5AC.c
./src/H5ACprivate.h
./src/H5B.c
./src/H5Gnode.c
./src/H5Gstab.c
./src/H5H.c
./src/H5O.c
Added an extra argument to H5AC_find_f() and H5AC_protect(). This
arg gets passed to the load() method. Also added an extra
argument to the H5AC_find() macro.
./src/H5B.c
./src/H5Bprivate.h
./src/H5Gnode.c
Extra argument passed to the sizeof_rkey() method.
./src/H5Fprivate.c
./src/H5Fistore.c (new)
Added indexed I/O operations.
./src/H5G.c
./src/H5Gnode.c
./src/H5Gprivate.h
Beginning to add H5G_open/close and related bug fixes.
./src/H5Oprivate.h
./src/H5Oistore.c (new)
Added the H5O_ISTORE messsage (0x0008) for indexed storage of
objects.
./src/H5private.h
Added extra braces around both sides of the FUNC_ENTER() and
FUNC_LEAVE() macros so FUNC_ENTER() can appear before
declarations or after executable statements the second case is
used by H5G_namei() to initialize output arguments to sane
values before FUNC_ENTER() might return failure.
int f ()
{
int decl1;
printf ("This happens before FUNC_ENTER()\n");
FUNC_ENTER (...);
int another_declaration;
./src/H5B.c
./src/H5Bprivate.h
./src/H5Gnode.c
Extra arguments for key encoding and decoding.
./src/H5E.c
./src/H5Epublic.h
./src/H5Fistore.c
./src/H5Oistore.c
./src/H5Oprivate.h
Indexed, chunked, sparse storage (not ready for general consumption
yet).
./src/H5V.c (new)
./src/H5Vprivate.h (new)
./test/hyperslab.c (new)
Vector, array, and hyperslab functions.
./src/H5B.c
./src/H5Bprivate.h
./src/H5Fistore.c
./src/H5Gnode.c
./src/H5V.c
./src/H5Vprivate.h
./test/hyperslab.c
Added functionality for indexed storage.
./src/H5F.c
Fixed problems with seek optimizing. Recommend we disable it
until we can implement it in the file/address class since all
of HDF5 must be aware of it.
./src/H5O.c
Fixed comeent speling erorr :-)
./MANIFEST
Added new files.
./config/conclude.in
Added the word `Testing' to the test cases. So if a test
program is called hyperslab then the make output will contain
the line `Testing hyperslab'.
./config/linux
The default file I/O library is Posix section 2 on my linux
machine so I can do some I/O performance testing.
./src/H5C.c
./src/H5Cprivate.h
./src/H5Cpublic.h
Added ability to set size of indexed-storage B-tree.
./src/H5D.c
./src/H5E.c
./src/H5Epublic.h
./src/H5F.c
./src/H5Fprivate.h
./src/H5G.c
./src/H5Gnode.c
./src/H5Gpkg.h
./src/H5Gprivate.h
./src/H5Gpublic.h
./src/H5Gshad.c
./src/H5Gstab.c
./test/stab.c
Changed `directory' to `group' in numerous places.
./src/H5private.h
The FILELIB constant can be set on the compile command-line.
./src/istore.c NEW
Tests for indexed storage.
Diffstat (limited to 'src/H5Gshad.c')
-rw-r--r-- | src/H5Gshad.c | 86 |
1 files changed, 43 insertions, 43 deletions
diff --git a/src/H5Gshad.c b/src/H5Gshad.c index 9bf80d8..875f880 100644 --- a/src/H5Gshad.c +++ b/src/H5Gshad.c @@ -29,7 +29,7 @@ static hbool_t interface_initialize_g = FALSE; typedef struct H5G_hash_t { - haddr_t dir_addr; + haddr_t grp_addr; H5G_shadow_t *head; struct H5G_hash_t *next; struct H5G_hash_t *prev; @@ -81,15 +81,15 @@ H5G_shadow_check (H5F_t *f) shadow_error = TRUE; } - /* Valid directory addresses */ - if (shadow->dir_addr<0 || (shadow->dir_addr==0 && idx!=0)) { - fprintf (stderr, "dir_addr=%lu, ", - (unsigned long)(shadow->dir_addr)); + /* Valid group addresses */ + if (shadow->grp_addr<0 || (shadow->grp_addr==0 && idx!=0)) { + fprintf (stderr, "grp_addr=%lu, ", + (unsigned long)(shadow->grp_addr)); shadow_error = TRUE; - } else if (shadow->dir_addr!=hash->dir_addr) { - fprintf (stderr, "dir_addr=%lu (not %lu), ", - (unsigned long)(shadow->dir_addr), - (unsigned long)(hash->dir_addr)); + } else if (shadow->grp_addr!=hash->grp_addr) { + fprintf (stderr, "grp_addr=%lu (not %lu), ", + (unsigned long)(shadow->grp_addr), + (unsigned long)(hash->grp_addr)); } /* Linked to symbol table entry */ @@ -107,9 +107,9 @@ H5G_shadow_check (H5F_t *f) /* If an error occurred then print other info */ if (shadow_error) { - fprintf (stderr, "idx=%u, shadow=0x%08lx, dir_addr=%lu\n", + fprintf (stderr, "idx=%u, shadow=0x%08lx, grp_addr=%lu\n", idx, (unsigned long)shadow, - (unsigned long)(shadow->dir_addr)); + (unsigned long)(shadow->grp_addr)); nerrors++; } } @@ -247,7 +247,7 @@ H5G_shadow_sync (H5G_entry_t *ent) * Function: H5G_shadow_list * * Purpose: Returns a doubly linked list of shadows for the symbol - * table whose header address is DIR_ADDR. + * table whose header address is GRP_ADDR. * * Return: Success: Ptr shadow list or null. * @@ -261,15 +261,15 @@ H5G_shadow_sync (H5G_entry_t *ent) *------------------------------------------------------------------------- */ H5G_shadow_t * -H5G_shadow_list (H5F_t *f, haddr_t dir_addr) +H5G_shadow_list (H5F_t *f, haddr_t grp_addr) { - uintn idx = dir_addr % f->shared->nshadows; + uintn idx = grp_addr % f->shared->nshadows; H5G_hash_t *bucket = NULL; FUNC_ENTER (H5G_shadows, NULL, NULL); for (bucket=f->shared->shadow[idx]; bucket; bucket=bucket->next) { - if (bucket->dir_addr==dir_addr) { + if (bucket->grp_addr==grp_addr) { HRETURN (bucket->head); } } @@ -317,7 +317,7 @@ H5G_shadow_assoc_node (H5F_t *f, H5G_node_t *sym, H5G_ac_ud1_t *ac_udata) H5G_shadow_check (f); #endif - if ((shadow=H5G_shadow_list (f, ac_udata->dir_addr))) { + if ((shadow=H5G_shadow_list (f, ac_udata->grp_addr))) { heap_addr = ac_udata->heap_addr; while (i<sym->nsyms && shadow) { @@ -352,7 +352,7 @@ H5G_shadow_assoc_node (H5F_t *f, H5G_node_t *sym, H5G_ac_ud1_t *ac_udata) * object, open the object (again) and return a handle * to it. * - * DIR can be the null pointer if `ent' is the root entry. + * GRP can be the null pointer if `ent' is the root entry. * * Return: Success: Handle to open object * @@ -366,7 +366,7 @@ H5G_shadow_assoc_node (H5F_t *f, H5G_node_t *sym, H5G_ac_ud1_t *ac_udata) *------------------------------------------------------------------------- */ H5G_entry_t * -H5G_shadow_open (H5F_t *f, H5G_entry_t *dir, H5G_entry_t *ent) +H5G_shadow_open (H5F_t *f, H5G_entry_t *grp, H5G_entry_t *ent) { H5G_shadow_t *shadow = NULL; H5O_stab_t stab; @@ -376,15 +376,15 @@ H5G_shadow_open (H5F_t *f, H5G_entry_t *dir, H5G_entry_t *ent) uintn idx; H5O_name_t name_mesg = {NULL}; H5G_entry_t *ret_value = NULL; - haddr_t dir_addr; + haddr_t grp_addr; FUNC_ENTER (H5G_shadow_open, NULL, NULL); /* check args */ assert (f); - assert (ent==f->shared->root_sym || dir); + assert (ent==f->shared->root_sym || grp); assert (ent); - dir_addr = dir ? dir->header : 0; + grp_addr = grp ? grp->header : 0; if ((shadow = ent->shadow)) { /* @@ -396,7 +396,7 @@ H5G_shadow_open (H5F_t *f, H5G_entry_t *dir, H5G_entry_t *ent) shadow = H5MM_xcalloc (1, sizeof(H5G_shadow_t)); - if (ent==f->shared->root_sym && 0==dir_addr) { + if (ent==f->shared->root_sym && 0==grp_addr) { /* * We're opening the root entry. */ @@ -411,7 +411,7 @@ H5G_shadow_open (H5F_t *f, H5G_entry_t *dir, H5G_entry_t *ent) /* * Some entry other than the root. */ - if (NULL==H5O_read (f, NO_ADDR, dir, H5O_STAB, 0, &stab)) { + if (NULL==H5O_read (f, NO_ADDR, grp, H5O_STAB, 0, &stab)) { HGOTO_ERROR (H5E_SYM, H5E_NOTFOUND, NULL); } if (NULL==(s=H5H_peek (f, stab.heap_addr, ent->name_off))) { @@ -428,18 +428,18 @@ H5G_shadow_open (H5F_t *f, H5G_entry_t *dir, H5G_entry_t *ent) shadow->nrefs = 1; shadow->entry = *ent; shadow->entry.dirty = FALSE; - shadow->dir_addr = dir_addr; + shadow->grp_addr = grp_addr; /* * Link it into the shadow heap */ - idx = dir_addr % f->shared->nshadows; + idx = grp_addr % f->shared->nshadows; for (hash=f->shared->shadow[idx]; hash; hash=hash->next) { - if (hash->dir_addr==dir_addr) break; + if (hash->grp_addr==grp_addr) break; } if (!hash) { hash = H5MM_xcalloc (1, sizeof(H5G_hash_t)); - hash->dir_addr = dir_addr; + hash->grp_addr = grp_addr; hash->next = f->shared->shadow[idx]; f->shared->shadow[idx] = hash; if (hash->next) hash->next->prev = hash; @@ -524,7 +524,7 @@ H5G_shadow_close (H5F_t *f, H5G_entry_t *ent) /* clean the shadow */ if (1==shadow->nrefs && ent->dirty) { if (!shadow->main && - NULL==H5G_stab_find (f, shadow->dir_addr, NULL, shadow->name)) { + NULL==H5G_stab_find (f, shadow->grp_addr, NULL, shadow->name)) { HRETURN_ERROR (H5E_SYM, H5E_NOTFOUND, FAIL); } assert (shadow->main); @@ -540,9 +540,9 @@ H5G_shadow_close (H5F_t *f, H5G_entry_t *ent) H5G_shadow_dissociate (ent); /* find symtabs shadow list */ - idx = shadow->dir_addr % f->shared->nshadows; + idx = shadow->grp_addr % f->shared->nshadows; for (hash=f->shared->shadow[idx]; hash; hash=hash->next) { - if (hash->dir_addr==shadow->dir_addr) break; + if (hash->grp_addr==shadow->grp_addr) break; } assert (hash); @@ -577,7 +577,7 @@ H5G_shadow_close (H5F_t *f, H5G_entry_t *ent) * Function: H5G_shadow_move * * Purpose: Moves the SHADOW for some entry to correspond to a - * NEW_ENTRY. The DIR_ADDR is the address for the directory + * NEW_ENTRY. The GRP_ADDR is the address for the group * which contains NEW_ENTRY. * * Return: Success: SUCCEED @@ -593,7 +593,7 @@ H5G_shadow_close (H5F_t *f, H5G_entry_t *ent) */ herr_t H5G_shadow_move (H5F_t *f, H5G_shadow_t *shadow, const char *new_name, - H5G_entry_t *new_entry, haddr_t dir_addr) + H5G_entry_t *new_entry, haddr_t grp_addr) { H5G_hash_t *hash; uintn idx; @@ -602,29 +602,29 @@ H5G_shadow_move (H5F_t *f, H5G_shadow_t *shadow, const char *new_name, assert (shadow); assert (new_entry); - assert (dir_addr>0); + assert (grp_addr>0); - if (0==shadow->dir_addr) { + if (0==shadow->grp_addr) { /* * We're moving the shadow for the root object. This simplifies things * greatly since it implies that this is the only shadow currently * defined for the entire file. */ - idx = dir_addr % f->shared->nshadows; + idx = grp_addr % f->shared->nshadows; assert (NULL==f->shared->shadow[idx]); /*Nothing at new idx... */ hash = f->shared->shadow[0]; assert (hash); /*..but root idx has something. */ - assert (0==hash->dir_addr); /*..and it's the root something */ + assert (0==hash->grp_addr); /*..and it's the root something */ assert (NULL==hash->next); /*..and just that */ assert (hash->head==shadow); /*..and exactly that */ /* Move root entry to new hash bucket */ f->shared->shadow[idx] = hash; f->shared->shadow[0] = NULL; - hash->dir_addr = dir_addr; + hash->grp_addr = grp_addr; /* Associate SHADOW with NEW_ENTRY */ - shadow->dir_addr = dir_addr; + shadow->grp_addr = grp_addr; shadow->main = new_entry; new_entry->shadow = shadow; @@ -636,7 +636,7 @@ H5G_shadow_move (H5F_t *f, H5G_shadow_t *shadow, const char *new_name, /* * Other shadows never move. */ - assert (shadow->dir_addr==dir_addr); + assert (shadow->grp_addr==grp_addr); shadow->main = new_entry; new_entry->shadow = shadow; } @@ -682,7 +682,7 @@ H5G_shadow_flush (H5F_t *f, hbool_t invalidate) */ if (shadow->entry.dirty) { if (!shadow->main && - NULL==H5G_stab_find (f, shadow->dir_addr, NULL, + NULL==H5G_stab_find (f, shadow->grp_addr, NULL, shadow->name)) { HRETURN_ERROR (H5E_SYM, H5E_NOTFOUND, FAIL); } @@ -698,12 +698,12 @@ H5G_shadow_flush (H5F_t *f, hbool_t invalidate) * some object before closing the file. Since this is hard to * debug, we'll be nice and print the names here. We don't know * the full name, but we'll print the file address (relative to - * the boot block) of the object header for the directory that + * the boot block) of the object header for the group that * contains the open object. */ if (invalidate) { - fprintf (stderr, "Open object <%lu>/%s", - (unsigned long)(shadow->dir_addr), + fprintf (stderr, "Warning: open object <%lu>/%s", + (unsigned long)(shadow->grp_addr), shadow->name); if (shadow->nrefs>1) { fprintf (stderr, " (%d times)", shadow->nrefs); |