Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
[mc] OOPify/C++ify ObjectInformation
[simgrid.git] / src / mc / mc_diff.cpp
index 35e8779..6ea1d01 100644 (file)
@@ -419,9 +419,9 @@ void reset_heap_information()
 static inline
 mc_mem_region_t MC_get_heap_region(mc_snapshot_t snapshot)
 {
-  size_t n = snapshot->snapshot_regions_count;
+  size_t n = snapshot->snapshot_regions.size();
   for (size_t i=0; i!=n; ++i) {
-    mc_mem_region_t region = snapshot->snapshot_regions[i];
+    mc_mem_region_t region = snapshot->snapshot_regions[i].get();
     if (region->region_type() == simgrid::mc::RegionType::Heap)
       return region;
   }
@@ -1573,27 +1573,6 @@ static int get_pointed_area_size(void *area, int heap)
   }
 }
 
-// Not used:
-char *get_type_description(mc_object_info_t info, char *type_name)
-{
-
-  xbt_dict_cursor_t dict_cursor;
-  char *type_origin;
-  dw_type_t type;
-
-  xbt_dict_foreach(info->types, dict_cursor, type_origin, type) {
-    if (type->name && (strcmp(type->name, type_name) == 0)
-        && type->byte_size > 0) {
-      xbt_dict_cursor_free(&dict_cursor);
-      return type_origin;
-    }
-  }
-
-  xbt_dict_cursor_free(&dict_cursor);
-  return NULL;
-}
-
-
 #ifndef max
 #define max( a, b ) ( ((a) > (b)) ? (a) : (b) )
 #endif