[MOAB-dev] r4976 - MOAB/trunk/src/io

kraftche at cae.wisc.edu kraftche at cae.wisc.edu
Thu Jun 9 11:07:17 CDT 2011


Author: kraftche
Date: 2011-06-09 11:07:12 -0500 (Thu, 09 Jun 2011)
New Revision: 4976

Modified:
   MOAB/trunk/src/io/ReadHDF5.cpp
   MOAB/trunk/src/io/ReadHDF5.hpp
   MOAB/trunk/src/io/ReadHDF5Dataset.cpp
   MOAB/trunk/src/io/ReadHDF5Dataset.hpp
Log:
ReadHDF5: read set description table once and keep a copy in memory during the read process

Modified: MOAB/trunk/src/io/ReadHDF5.cpp
===================================================================
--- MOAB/trunk/src/io/ReadHDF5.cpp	2011-06-08 20:45:46 UTC (rev 4975)
+++ MOAB/trunk/src/io/ReadHDF5.cpp	2011-06-09 16:07:12 UTC (rev 4976)
@@ -216,7 +216,8 @@
     dbgOut(stderr),
     blockedCoordinateIO(DEFAULT_BLOCKED_COORDINATE_IO),
     bcastSummary(DEFAULT_BCAST_SUMMARY),
-    bcastDuplicateReads(DEFAULT_BCAST_DUPLICATE_READS)
+    bcastDuplicateReads(DEFAULT_BCAST_DUPLICATE_READS),
+    setMeta(0)
 {
 }
 
@@ -261,6 +262,8 @@
   if (!readUtil) // init() failed.
     return;
 
+  delete [] setMeta;
+  setMeta = 0;
   iFace->release_interface( readUtil );
   H5Tclose( handleType );
 }
@@ -541,6 +544,9 @@
     H5Pclose( collIO );
   collIO = indepIO = H5P_DEFAULT;
 
+  delete [] setMeta;
+  setMeta = 0;
+
   mhdf_Status status;
   mhdf_closeFile( filePtr, &status );
   filePtr = 0;
@@ -558,8 +564,12 @@
   rval = set_up_read( filename, opts );
   if (MB_SUCCESS != rval)
     return rval;
+    
+    // We read the entire set description table regarless of partial
+    // or complete reads or serial vs parallel reads
+  rval = read_all_set_meta();
  
-  if (subset_list) 
+  if (subset_list && MB_SUCCESS == rval) 
     rval = load_file_partial( subset_list->tag_list, 
                               subset_list->tag_list_length, 
                               subset_list->num_parts,
@@ -1899,90 +1909,140 @@
   mhdf_Status status;
   ErrorCode rval;
 


More information about the moab-dev mailing list