summaryrefslogtreecommitdiffstats
path: root/src/H5trace.c
diff options
context:
space:
mode:
authorLarry Knox <lrknox@hdfgroup.org>2019-10-09 20:45:26 (GMT)
committerLarry Knox <lrknox@hdfgroup.org>2019-10-09 20:45:26 (GMT)
commit984c1bacd93c2f782c75c02d88d6e5c0362c74d0 (patch)
tree97bf7d8b15caee53eb8fdfd84eb09316b54903f1 /src/H5trace.c
parent19c2eb2800a48d0bd5a8af7757e21cc5cd22fa3c (diff)
parent5d2545ee26d4b7013ed363545705f16a67087549 (diff)
downloadhdf5-984c1bacd93c2f782c75c02d88d6e5c0362c74d0.zip
hdf5-984c1bacd93c2f782c75c02d88d6e5c0362c74d0.tar.gz
hdf5-984c1bacd93c2f782c75c02d88d6e5c0362c74d0.tar.bz2
Merge pull request #1990 in HDFFV/hdf5 from ~JSOUMAGNE/hdf5:references_1_12 to hdf5_1_12
* commit '5d2545ee26d4b7013ed363545705f16a67087549': Fix func enter macro in H5T_ref_reclaim() Update RELEASE.txt for reference changes Fix reference type comparison in h5dump Make wrappers, tests and tools use H5Treclaim() instead of H5Dvlen_reclaim() Add new H5R API that abstracts object, region and attribute reference types Remove ability to loc by ref from H5VL layer Add support for retrieving object name by token Add H5VL_OBJECT_GET_TYPE to get object type Add H5VL_MAX_TOKEN_SIZE and H5VL_token_t Adapt Jerome's "file info" H5VL 'get' query to retrieve container token info. Fix H5VL_blob_get to return size of blob Add 'blob' callbacks to VOL, along with a native implementation to store them in the global heap, and changed the VL datatype conversion code to use blobs.
Diffstat (limited to 'src/H5trace.c')
-rw-r--r--src/H5trace.c134
1 files changed, 101 insertions, 33 deletions
diff --git a/src/H5trace.c b/src/H5trace.c
index 2e905a5..2f40686 100644
--- a/src/H5trace.c
+++ b/src/H5trace.c
@@ -34,6 +34,7 @@
#include "H5Dprivate.h" /* Datasets */
#include "H5Eprivate.h" /* Error handling */
#include "H5FDprivate.h" /* File drivers */
+#include "H5Rprivate.h" /* References */
#include "H5Ipkg.h" /* IDs */
#include "H5MMprivate.h" /* Memory management */
#include "H5VLprivate.h" /* Virtual Object Layer */
@@ -1852,22 +1853,51 @@ H5_trace(const double *returning, const char *func, const char *type, ...)
} /* end else */
break;
- case 'r':
- if(ptr) {
- if(vp)
- HDfprintf(out, "0x%lx", (unsigned long)vp);
- else
- HDfprintf(out, "NULL");
- } /* end if */
- else {
- hobj_ref_t ref = HDva_arg(ap, hobj_ref_t);
-
- HDfprintf(out, "Reference Object=%a", ref);
- } /* end else */
- break;
-
case 'R':
switch(type[1]) {
+
+ case 'o':
+ if(ptr) {
+ if(vp)
+ HDfprintf(out, "0x%lx", (unsigned long)vp);
+ else
+ HDfprintf(out, "NULL");
+ } /* end if */
+ else {
+ hobj_ref_t ref = HDva_arg(ap, hobj_ref_t);
+
+ HDfprintf(out, "Reference Object=%a", ref);
+ } /* end else */
+ break;
+
+ case 'd':
+ if(ptr) {
+ if(vp)
+ HDfprintf(out, "0x%lx", (unsigned long)vp);
+ else
+ HDfprintf(out, "NULL");
+ } /* end if */
+ else {
+ /* Note! region references are array types */
+ HDfprintf(out, "Reference Region");
+ goto error;
+ } /* end else */
+ break;
+
+ case 'r':
+ if(ptr) {
+ if(vp)
+ HDfprintf(out, "0x%lx", (unsigned long)vp);
+ else
+ HDfprintf(out, "NULL");
+ } /* end if */
+ else {
+ /* Note! reference types are opaque types */
+ HDfprintf(out, "Reference Opaque");
+ goto error;
+ } /* end else */
+ break;
+
case 't':
if(ptr) {
if(vp)
@@ -1883,12 +1913,24 @@ H5_trace(const double *returning, const char *func, const char *type, ...)
HDfprintf(out, "H5R_BADTYPE");
break;
- case H5R_OBJECT:
- HDfprintf(out, "H5R_OBJECT");
+ case H5R_OBJECT1:
+ HDfprintf(out, "H5R_OBJECT1");
+ break;
+
+ case H5R_DATASET_REGION1:
+ HDfprintf(out, "H5R_DATASET_REGION1");
break;
- case H5R_DATASET_REGION:
- HDfprintf(out, "H5R_DATASET_REGION");
+ case H5R_OBJECT2:
+ HDfprintf(out, "H5R_OBJECT2");
+ break;
+
+ case H5R_DATASET_REGION2:
+ HDfprintf(out, "H5R_DATASET_REGION2");
+ break;
+
+ case H5R_ATTR:
+ HDfprintf(out, "H5R_ATTR");
break;
case H5R_MAXTYPE:
@@ -2588,6 +2630,35 @@ H5_trace(const double *returning, const char *func, const char *type, ...)
} /* end switch */
} /* end else */
break;
+ case 'B':
+ if(ptr) {
+ if(vp)
+ HDfprintf (out, "0x%lx", (unsigned long)vp);
+ else
+ HDfprintf(out, "NULL");
+ } /* end if */
+ else {
+ H5VL_blob_specific_t specific = (H5VL_blob_specific_t)HDva_arg(ap, int);
+
+ switch(specific) {
+ case H5VL_BLOB_DELETE:
+ HDfprintf(out, "H5VL_BLOB_DELETE");
+ break;
+ case H5VL_BLOB_GETSIZE:
+ HDfprintf(out, "H5VL_BLOB_GETSIZE");
+ break;
+ case H5VL_BLOB_ISNULL:
+ HDfprintf(out, "H5VL_BLOB_ISNULL");
+ break;
+ case H5VL_BLOB_SETNULL:
+ HDfprintf(out, "H5VL_BLOB_SETNULL");
+ break;
+ default:
+ HDfprintf(out, "%ld", (long)specific);
+ break;
+ } /* end switch */
+ } /* end else */
+ break;
case 'C':
if(ptr) {
if(vp)
@@ -2725,18 +2796,21 @@ H5_trace(const double *returning, const char *func, const char *type, ...)
H5VL_file_get_t get = (H5VL_file_get_t)HDva_arg(ap, int);
switch(get) {
+ case H5VL_FILE_GET_CONT_INFO:
+ HDfprintf(out, "H5VL_FILE_GET_CONT_INFO");
+ break;
case H5VL_FILE_GET_FAPL:
HDfprintf(out, "H5VL_FILE_GET_FAPL");
break;
case H5VL_FILE_GET_FCPL:
HDfprintf(out, "H5VL_FILE_GET_FCPL");
break;
- case H5VL_FILE_GET_INTENT:
- HDfprintf(out, "H5VL_FILE_GET_INTENT");
- break;
case H5VL_FILE_GET_FILENO:
HDfprintf(out, "H5VL_FILE_GET_FILENO");
break;
+ case H5VL_FILE_GET_INTENT:
+ HDfprintf(out, "H5VL_FILE_GET_INTENT");
+ break;
case H5VL_FILE_GET_NAME:
HDfprintf(out, "H5VL_FILE_GET_NAME");
break;
@@ -2922,18 +2996,12 @@ H5_trace(const double *returning, const char *func, const char *type, ...)
H5VL_object_get_t get = (H5VL_object_get_t)HDva_arg(ap, int);
switch(get) {
- case H5VL_REF_GET_REGION:
- HDfprintf(out, "H5VL_REF_GET_REGION");
- break;
- case H5VL_REF_GET_TYPE:
- HDfprintf(out, "H5VL_REF_GET_TYPE");
- break;
- case H5VL_REF_GET_NAME:
- HDfprintf(out, "H5VL_REF_GET_NAME");
- break;
case H5VL_OBJECT_GET_NAME:
HDfprintf(out, "H5VL_OBJECT_GET_NAME");
break;
+ case H5VL_OBJECT_GET_TYPE:
+ HDfprintf(out, "H5VL_OBJECT_GET_TYPE");
+ break;
default:
HDfprintf(out, "%ld", (long)get);
break;
@@ -2957,12 +3025,12 @@ H5_trace(const double *returning, const char *func, const char *type, ...)
case H5VL_OBJECT_EXISTS:
HDfprintf(out, "H5VL_OBJECT_EXISTS");
break;
+ case H5VL_OBJECT_LOOKUP:
+ HDfprintf(out, "H5VL_OBJECT_LOOKUP");
+ break;
case H5VL_OBJECT_VISIT:
HDfprintf(out, "H5VL_OBJECT_VISIT");
break;
- case H5VL_REF_CREATE:
- HDfprintf(out, "H5VL_REF_CREATE");
- break;
case H5VL_OBJECT_FLUSH:
HDfprintf(out, "H5VL_OBJECT_FLUSH");
break;