[MOAB-dev] r4585 - MOAB/trunk/src/parallel

kraftche at cae.wisc.edu kraftche at cae.wisc.edu
Mon Mar 14 16:17:31 CDT 2011


Author: kraftche
Date: 2011-03-14 16:17:30 -0500 (Mon, 14 Mar 2011)
New Revision: 4585

Modified:
   MOAB/trunk/src/parallel/WriteHDF5Parallel.cpp
Log:
o Make parallel HDF5 write consistent with serial with regards to choosing
  which tag data is to be written in the dense format.
o Fix bug in parallel HDF5 write where space is reserved in the sparse
  dataset(s) for tag data that is written in the dense format.



Modified: MOAB/trunk/src/parallel/WriteHDF5Parallel.cpp
===================================================================
--- MOAB/trunk/src/parallel/WriteHDF5Parallel.cpp	2011-03-12 00:23:59 UTC (rev 4584)
+++ MOAB/trunk/src/parallel/WriteHDF5Parallel.cpp	2011-03-14 21:17:30 UTC (rev 4585)
@@ -464,12 +464,10 @@
   DataType type;
   int size;
   int name_len;
-  unsigned long num_sparse_ents;
-  unsigned long num_sparse_vals; // not used for fixed-length tags
   char name[sizeof(unsigned long)];
   
   static size_t len( int name_len ) {
-    return sizeof(serial_tag_data) + name_len - sizeof(size_t);
+    return sizeof(serial_tag_data) + name_len - sizeof(name);
   }
   size_t len() const { return len( name_len ); }
 };
@@ -508,15 +506,6 @@
     return error(rval);
   ptr->name_len = name_len;
   Range range;
-  rval = get_sparse_tagged_entities( tag, range );
-  if (MB_SUCCESS != rval) return error(rval);
-  ptr->num_sparse_ents = range.size();
-  ptr->num_sparse_vals = 0;
-  if (MB_VARIABLE_LENGTH == ptr->size) {
-    rval = get_tag_data_length( tag, range, ptr->num_sparse_vals );
-    assert(MB_SUCCESS == rval);
-    if (MB_SUCCESS != rval) return error(rval);
-  }
   memset( ptr->name, 0, ptr->name_len );
   memcpy( ptr->name, name.data(), name.size() );
   
@@ -544,7 +533,6 @@
   ErrorCode rval;
   int err;
   const int num_proc = myPcomm->proc_config().proc_size();
-  int num_tags = tagList.size();
 
   dbgOut.tprint(1,"communicating tag metadata\n");
   
@@ -561,9 +549,9 @@
       return error(rval);
   }
 
-  dbgOut.printf(2,"Exchanging tag data for %d tags.\n", num_tags);
+  dbgOut.printf(2,"Exchanging tag data for %d tags.\n", (int)tagList.size() ); 
 
-    // Exchange tag data between all processors
+    // Exchange tag descriptions between all processors


More information about the moab-dev mailing list