Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
083710abc14e243d4959ecc941d8d239eb9f61b4
[simgrid.git] / src / mc / mc_compare.c
1 /* Copyright (c) 2012-2013 Da SimGrid Team. All rights reserved.            */
2
3 /* This program is free software; you can redistribute it and/or modify it
4  * under the terms of the license (GNU LGPL) which comes with this package. */
5
6 #include "mc_private.h"
7
8 #include "xbt/mmalloc.h"
9
10 XBT_LOG_NEW_DEFAULT_SUBCATEGORY(mc_compare, mc,
11                                 "Logging specific to mc_compare");
12
13 typedef struct s_pointers_pair{
14   void *p1;
15   void *p2;
16 }s_pointers_pair_t, *pointers_pair_t;
17
18 xbt_dynar_t compared_pointers;
19
20 static int heap_region_compare(void *d1, void *d2, size_t size);
21
22 static void stack_region_free(stack_region_t s);
23
24 static int compare_local_variables(mc_snapshot_stack_t stack1, mc_snapshot_stack_t stack2, void *heap1, void *heap2);
25 static int compare_global_variables(int region_type, mc_mem_region_t r1, mc_mem_region_t r2);
26 static int compare_pointer(char *pointer_type, void *addr_pointed1, void *addr_pointed2, int region_size, int region_type);
27 static int compare_areas_with_type(void *area1, void *area2, xbt_dict_t types, xbt_dict_t other_types, char *type_id, int region_size, int region_type, void *start_data, int pointer_level);
28
29 static int already_compared_pointers(void *p1, void *p2){
30
31   if(xbt_dynar_is_empty(compared_pointers))
32     return -1;
33
34   unsigned int cursor = 0;
35   int start = 0;
36   int end = xbt_dynar_length(compared_pointers) - 1;
37   pointers_pair_t pair;
38
39   while(start <= end){
40     cursor = (start + end) / 2;
41     pair = (pointers_pair_t)xbt_dynar_get_as(compared_pointers, cursor, pointers_pair_t);
42     if(pair->p1 == p1){
43       if(pair->p2 == p2)
44         return 0;
45       else if(pair->p2 < p2)
46         start = cursor + 1;
47       else
48         end = cursor - 1;
49     }else if(pair->p1 < p1){
50       start = cursor + 1;
51     }else{
52       end = cursor - 1 ;
53     }
54   }
55
56   return -1;
57
58 }
59
60 static void add_compared_pointers(void *p1, void *p2){
61
62   pointers_pair_t new_pair = xbt_new0(s_pointers_pair_t, 1);
63   new_pair->p1 = p1;
64   new_pair->p2 = p2;
65   
66   if(xbt_dynar_is_empty(compared_pointers)){
67     xbt_dynar_push(compared_pointers, &new_pair);
68     return;
69   }
70
71   unsigned int cursor = 0;
72   int start = 0;
73   int end = xbt_dynar_length(compared_pointers) - 1;
74   pointers_pair_t pair = NULL;
75
76   while(start <= end){
77     cursor = (start + end) / 2;
78     pair = (pointers_pair_t)xbt_dynar_get_as(compared_pointers, cursor, pointers_pair_t);
79     if(pair->p1 == p1){
80       if(pair->p2 == p2)
81         return;
82       else if(pair->p2 < p2)
83         start = cursor + 1;
84       else
85         end = cursor - 1;
86     }else if(pair->p1 < p1){
87       start = cursor + 1;
88     }else{
89       end = cursor - 1 ;
90     }
91   }
92
93   if(pair->p1 == p1){
94     if(pair->p2 < p2)
95       xbt_dynar_insert_at(compared_pointers, cursor + 1, &new_pair);
96     else
97       xbt_dynar_insert_at(compared_pointers, cursor, &new_pair); 
98   }else{
99     if(pair->p1 < p1)
100       xbt_dynar_insert_at(compared_pointers, cursor + 1, &new_pair);
101     else
102       xbt_dynar_insert_at(compared_pointers, cursor, &new_pair);   
103   }
104
105 }
106
107 static int compare_areas_with_type(void *area1, void *area2, xbt_dict_t types, xbt_dict_t other_types, char *type_id, int region_size, int region_type, void *start_data, int pointer_level){
108
109   dw_type_t type = xbt_dict_get_or_null(types, type_id);;
110   unsigned int cursor = 0;
111   dw_type_t member, subtype, subsubtype;
112   int elm_size, i, res, switch_types = 0;
113   void *addr_pointed1, *addr_pointed2;
114   int pointed_area_size1, pointed_area_size2;
115
116   switch(type->type){
117   case e_dw_base_type:
118   case e_dw_enumeration_type:
119   case e_dw_union_type:
120     return (memcmp(area1, area2, type->size) != 0);
121     break;
122   case e_dw_typedef:
123   case e_dw_volatile_type:
124     return compare_areas_with_type(area1, area2, types, other_types, type->dw_type_id, region_size, region_type, start_data, pointer_level);
125     break;
126   case e_dw_const_type: /* Const variable cannot be modified */
127     return -1;
128     break;
129   case e_dw_array_type:
130     subtype = xbt_dict_get_or_null(types, type->dw_type_id);
131     switch(subtype->type){
132     case e_dw_base_type:
133     case e_dw_enumeration_type:
134     case e_dw_pointer_type:
135     case e_dw_structure_type:
136     case e_dw_union_type:
137       if(subtype->size == 0){ /*declaration of the type, need the complete description */
138         subtype = xbt_dict_get_or_null(types, get_type_description(types, subtype->name));
139         if(subtype == NULL){
140           subtype = xbt_dict_get_or_null(other_types, get_type_description(other_types, subtype->name));
141           switch_types = 1;
142         }
143       }
144       elm_size = subtype->size;
145       break;
146     case e_dw_typedef:
147     case e_dw_volatile_type:
148       subsubtype = xbt_dict_get_or_null(types, subtype->dw_type_id);
149       if(subsubtype->size == 0){ /*declaration of the type, need the complete description */
150         subsubtype = xbt_dict_get_or_null(types, get_type_description(types, subsubtype->name));
151         if(subsubtype == NULL){
152           subsubtype = xbt_dict_get_or_null(other_types, get_type_description(other_types, subsubtype->name));
153           switch_types = 1;
154         }
155       }
156       elm_size = subsubtype->size;
157       break;
158     default : 
159       return 0;
160       break;
161     }
162     for(i=0; i<type->size; i++){
163       if(switch_types)
164         res = compare_areas_with_type((char *)area1 + (i*elm_size), (char *)area2 + (i*elm_size), other_types, types, type->dw_type_id, region_size, region_type, start_data, pointer_level);
165       else
166         res = compare_areas_with_type((char *)area1 + (i*elm_size), (char *)area2 + (i*elm_size), types, other_types, type->dw_type_id, region_size, region_type, start_data, pointer_level);
167       if(res != 0)
168         return res;
169     }
170     break;
171   case e_dw_pointer_type: 
172     if(type->dw_type_id && ((dw_type_t)xbt_dict_get_or_null(types, type->dw_type_id))->type == e_dw_subroutine_type){
173       addr_pointed1 = *((void **)(area1)); 
174       addr_pointed2 = *((void **)(area2));
175       return (addr_pointed1 != addr_pointed2);
176     }else{
177       addr_pointed1 = *((void **)(area1)); 
178       addr_pointed2 = *((void **)(area2));
179       
180       if((addr_pointed1 == addr_pointed2) && ((pointed_area_size1 = get_pointed_area_size(addr_pointed1, 1)) != (pointed_area_size2 = get_pointed_area_size(addr_pointed2, 2))))
181         return -1;
182       if(addr_pointed1 == NULL && addr_pointed2 == NULL)
183         return 0;
184       if(already_compared_pointers(addr_pointed1, addr_pointed2) != -1)
185         return 0;
186       add_compared_pointers(addr_pointed1, addr_pointed2);
187
188       pointer_level++;
189       
190       if(addr_pointed1 > std_heap && (char *)addr_pointed1 < (char*) std_heap + STD_HEAP_SIZE && addr_pointed2 > std_heap && (char *)addr_pointed2 < (char*) std_heap + STD_HEAP_SIZE){
191         return compare_heap_area(addr_pointed1, addr_pointed2, NULL, types, other_types, type->dw_type_id, pointer_level); 
192       }else if(addr_pointed1 > start_data && (char*)addr_pointed1 <= (char *)start_data + region_size && addr_pointed2 > start_data && (char*)addr_pointed2 <= (char *)start_data + region_size){
193         if(type->dw_type_id == NULL)
194           return  (addr_pointed1 != addr_pointed2);
195         else
196           return compare_areas_with_type(addr_pointed1, addr_pointed2, types, other_types, type->dw_type_id, region_size, region_type, start_data, pointer_level); 
197       }else{
198         return  (addr_pointed1 != addr_pointed2);
199       }
200     }
201     break;
202   case e_dw_structure_type:
203     xbt_dynar_foreach(type->members, cursor, member){
204       res = compare_areas_with_type((char *)area1 + member->offset, (char *)area2 + member->offset, types, other_types, member->dw_type_id, region_size, region_type, start_data, pointer_level);
205       if(res == 1)
206         return res;
207     }
208     break;
209   case e_dw_subroutine_type:
210     return -1;
211     break;
212   default:
213     XBT_VERB("Unknown case : %d", type->type);
214     break;
215   }
216   
217   return 0;
218 }
219
220 static int compare_global_variables(int region_type, mc_mem_region_t r1, mc_mem_region_t r2){
221
222   if(!compared_pointers){
223     compared_pointers = xbt_dynar_new(sizeof(pointers_pair_t), NULL);
224     MC_ignore_global_variable("compared_pointers");
225   }else{
226     xbt_dynar_reset(compared_pointers);
227   }
228
229   xbt_dynar_t variables;
230   xbt_dict_t types, other_types;
231   int res;
232   unsigned int cursor = 0;
233   dw_variable_t current_var;
234   size_t offset;
235   void *start_data;
236
237   if(region_type == 2){
238     variables = mc_global_variables_binary;
239     types = mc_variables_type_binary;
240     other_types = mc_variables_type_libsimgrid;
241     start_data = start_data_binary;
242   }else{
243     variables = mc_global_variables_libsimgrid;
244     types = mc_variables_type_libsimgrid;
245     other_types = mc_variables_type_binary;
246     start_data = start_data_libsimgrid;
247   }
248
249   xbt_dynar_foreach(variables, cursor, current_var){
250
251     if(region_type == 2)
252       offset = (char *)current_var->address.address - (char *)start_data_binary;
253     else
254       offset = (char *)current_var->address.address - (char *)start_data_libsimgrid;
255
256     res = compare_areas_with_type((char *)r1->data + offset, (char *)r2->data + offset, types, other_types, current_var->type_origin, r1->size, region_type, start_data, 0);
257     if(res == -1){
258       xbt_dynar_cursor_rm(variables, &cursor);
259     }else if(res == 1){
260       XBT_VERB("Global variable %s is different between snapshots", current_var->name);
261       return 1;
262     }
263
264   }
265   return 0;
266
267 }
268
269 static int compare_local_variables(mc_snapshot_stack_t stack1, mc_snapshot_stack_t stack2, void *heap1, void *heap2){
270
271   if(!compared_pointers){
272     compared_pointers = xbt_dynar_new(sizeof(pointers_pair_t), NULL);
273     MC_ignore_global_variable("compared_pointers");
274   }else{
275     xbt_dynar_reset(compared_pointers);
276   }
277
278   if(xbt_dynar_length(stack1->local_variables) != xbt_dynar_length(stack2->local_variables)){
279     XBT_VERB("Different number of local variables");
280     return 1;
281   }else{
282     unsigned int cursor = 0;
283     local_variable_t current_var1, current_var2;
284     int offset1, offset2, res;
285     while(cursor < xbt_dynar_length(stack1->local_variables)){
286       current_var1 = (local_variable_t)xbt_dynar_get_as(stack1->local_variables, cursor, local_variable_t);
287       current_var2 = (local_variable_t)xbt_dynar_get_as(stack2->local_variables, cursor, local_variable_t);
288       if(strcmp(current_var1->name, current_var2->name) != 0 || strcmp(current_var1->frame, current_var2->frame) != 0 || current_var1->ip != current_var2->ip)
289         return 1;
290       offset1 = (char *)current_var1->address - (char *)std_heap;
291       offset2 = (char *)current_var2->address - (char *)std_heap;
292       if(current_var1->region == 1)
293         res = compare_areas_with_type( (char *)heap1 + offset1, (char *)heap2 + offset2, mc_variables_type_libsimgrid, mc_variables_type_binary, current_var1->type, 0, 1, start_data_libsimgrid, 0l);
294       else
295         res = compare_areas_with_type( (char *)heap1 + offset1, (char *)heap2 + offset2, mc_variables_type_binary, mc_variables_type_libsimgrid, current_var1->type, 0, 2, start_data_binary, 0l);
296       if(res != 0){
297         XBT_VERB("Local variable %s in frame %s  is different between snapshots", current_var1->name, current_var1->frame);
298         return res;
299       }
300       cursor++;
301     }
302     return 0;
303   }
304 }
305
306
307 static int heap_region_compare(void *d1, void *d2, size_t size){
308   
309   size_t i = 0;
310   
311   for(i=0; i<size; i++){
312     if(memcmp(((char *)d1) + i, ((char *)d2) + i, 1) != 0){
313       if(XBT_LOG_ISENABLED(mc_compare, xbt_log_priority_verbose)){
314         XBT_VERB("Different byte (offset=%zu) (%p - %p) in heap region", i, (char *)d1 + i, (char *)d2 + i);
315       }
316       return 1;
317     }
318   }
319   
320   return 0;
321 }
322
323 static void stack_region_free(stack_region_t s){
324   if(s){
325     xbt_free(s->process_name);
326     xbt_free(s);
327   }
328 }
329
330 void stack_region_free_voidp(void *s){
331   stack_region_free((stack_region_t) * (void **) s);
332 }
333
334 int SIMIX_pre_mc_compare_snapshots(smx_simcall_t simcall,
335                                    mc_snapshot_t s1, mc_snapshot_t s2){
336   return snapshot_compare(s1, s2);
337 }
338
339 int snapshot_compare(mc_snapshot_t s1, mc_snapshot_t s2){
340
341   int raw_mem = (mmalloc_get_current_heap() == raw_heap);
342   
343   MC_SET_RAW_MEM;
344      
345   int errors = 0;
346
347   xbt_os_timer_t global_timer = xbt_os_timer_new();
348   xbt_os_timer_t timer = xbt_os_timer_new();
349
350   xbt_os_walltimer_start(global_timer);
351
352   #ifdef MC_DEBUG
353     xbt_os_walltimer_start(timer);
354   #endif
355
356   /* Compare size of stacks */
357   int i = 0;
358   size_t size_used1, size_used2;
359   int is_diff = 0;
360   while(i < xbt_dynar_length(s1->stacks)){
361     size_used1 = s1->stack_sizes[i];
362     size_used2 = s2->stack_sizes[i];
363     if(size_used1 != size_used2){
364     #ifdef MC_DEBUG
365       if(is_diff == 0){
366         xbt_os_walltimer_stop(timer);
367         mc_comp_times->stacks_sizes_comparison_time = xbt_os_timer_elapsed(timer);
368       }
369       XBT_DEBUG("Different size used in stacks : %zu - %zu", size_used1, size_used2);
370       errors++;
371       is_diff = 1;
372     #else
373       #ifdef MC_VERBOSE
374         XBT_VERB("Different size used in stacks : %zu - %zu", size_used1, size_used2);
375       #endif
376
377       xbt_os_timer_free(timer);
378       xbt_os_walltimer_stop(global_timer);
379       mc_snapshot_comparison_time = xbt_os_timer_elapsed(global_timer);
380       xbt_os_timer_free(global_timer);
381
382       if(!raw_mem)
383         MC_UNSET_RAW_MEM;
384
385       return 1;
386     #endif  
387     }
388     i++;
389   }
390
391   #ifdef MC_DEBUG
392     if(is_diff == 0)
393       xbt_os_walltimer_stop(timer);
394     xbt_os_walltimer_start(timer);
395   #endif
396
397   /* Compare hash of global variables */
398   if(s1->hash_global != NULL && s2->hash_global != NULL){
399     if(strcmp(s1->hash_global, s2->hash_global) != 0){
400       #ifdef MC_DEBUG
401         xbt_os_walltimer_stop(timer);
402         mc_comp_times->hash_global_variables_comparison_time = xbt_os_timer_elapsed(timer);
403         XBT_DEBUG("Different hash of global variables : %s - %s", s1->hash_global, s2->hash_global); 
404         errors++; 
405       #else
406         #ifdef MC_VERBOSE
407           XBT_VERB("Different hash of global variables : %s - %s", s1->hash_global, s2->hash_global); 
408         #endif
409
410         xbt_os_timer_free(timer);
411         xbt_os_walltimer_stop(global_timer);
412         mc_snapshot_comparison_time = xbt_os_timer_elapsed(global_timer);
413         xbt_os_timer_free(global_timer);
414     
415         if(!raw_mem)
416           MC_UNSET_RAW_MEM;
417
418         return 1;
419       #endif
420     }
421   }
422
423   #ifdef MC_DEBUG
424     xbt_os_walltimer_start(timer);
425   #endif
426
427   /* Compare hash of local variables */
428   if(s1->hash_local != NULL && s2->hash_local != NULL){
429     if(strcmp(s1->hash_local, s2->hash_local) != 0){
430       #ifdef MC_DEBUG
431         xbt_os_walltimer_stop(timer);
432         mc_comp_times->hash_local_variables_comparison_time = xbt_os_timer_elapsed(timer);
433         XBT_DEBUG("Different hash of local variables : %s - %s", s1->hash_local, s2->hash_local); 
434         errors++; 
435       #else
436         #ifdef MC_VERBOSE
437           XBT_VERB("Different hash of local variables : %s - %s", s1->hash_local, s2->hash_local); 
438         #endif
439
440         xbt_os_timer_free(timer);
441         xbt_os_walltimer_stop(global_timer);
442         mc_snapshot_comparison_time = xbt_os_timer_elapsed(global_timer);
443         xbt_os_timer_free(global_timer);
444         
445         if(!raw_mem)
446           MC_UNSET_RAW_MEM;
447         
448         return 1;
449       #endif
450     }
451   }
452
453   #ifdef MC_DEBUG
454     xbt_os_walltimer_start(timer);
455   #endif
456
457   /* Init heap information used in heap comparison algorithm */
458   init_heap_information((xbt_mheap_t)s1->regions[0]->data, (xbt_mheap_t)s2->regions[0]->data, s1->to_ignore, s2->to_ignore);
459
460   /* Stacks comparison */
461   unsigned int  cursor = 0;
462   int diff_local = 0;
463   is_diff = 0;
464   mc_snapshot_stack_t stack1, stack2;
465     
466   while(cursor < xbt_dynar_length(s1->stacks)){
467     stack1 = (mc_snapshot_stack_t)xbt_dynar_get_as(s1->stacks, cursor, mc_snapshot_stack_t);
468     stack2 = (mc_snapshot_stack_t)xbt_dynar_get_as(s2->stacks, cursor, mc_snapshot_stack_t);
469     diff_local = compare_local_variables(stack1, stack2, s1->regions[0]->data, s2->regions[0]->data);
470     if(diff_local > 0){
471       #ifdef MC_DEBUG
472         if(is_diff == 0){
473           xbt_os_walltimer_stop(timer);
474           mc_comp_times->stacks_comparison_time = xbt_os_timer_elapsed(timer);
475         }
476         XBT_DEBUG("Different local variables between stacks %d", cursor + 1);
477         errors++;
478         is_diff = 1;
479       #else
480         
481         #ifdef MC_VERBOSE
482           XBT_VERB("Different local variables between stacks %d", cursor + 1);
483         #endif
484           
485         reset_heap_information();
486         xbt_os_timer_free(timer);
487         xbt_os_walltimer_stop(global_timer);
488         mc_snapshot_comparison_time = xbt_os_timer_elapsed(global_timer);
489         xbt_os_timer_free(global_timer);
490         
491         if(!raw_mem)
492           MC_UNSET_RAW_MEM;
493         
494         return 1;
495       #endif
496     }
497     cursor++;
498   }
499
500   #ifdef MC_DEBUG
501     if(is_diff == 0)
502       xbt_os_walltimer_stop(timer);
503     xbt_os_walltimer_start(timer);
504   #endif
505
506   /* Compare binary global variables */
507   is_diff = compare_global_variables(2, s1->regions[2], s2->regions[2]);
508   if(is_diff != 0){
509     #ifdef MC_DEBUG
510       xbt_os_walltimer_stop(timer);
511       mc_comp_times->binary_global_variables_comparison_time = xbt_os_timer_elapsed(timer);
512       XBT_DEBUG("Different global variables in binary");
513       errors++;
514     #else
515       #ifdef MC_VERBOSE
516         XBT_VERB("Different global variables in binary");
517       #endif
518
519       reset_heap_information();
520       xbt_os_timer_free(timer);
521       xbt_os_walltimer_stop(global_timer);
522       mc_snapshot_comparison_time = xbt_os_timer_elapsed(global_timer);
523       xbt_os_timer_free(global_timer);
524     
525       if(!raw_mem)
526         MC_UNSET_RAW_MEM;
527
528       return 1;
529     #endif
530   }
531
532   #ifdef MC_DEBUG
533     if(is_diff == 0)
534       xbt_os_walltimer_stop(timer);
535     xbt_os_walltimer_start(timer);
536   #endif
537
538   /* Compare libsimgrid global variables */
539   is_diff = compare_global_variables(1, s1->regions[1], s2->regions[1]);
540   if(is_diff != 0){
541     #ifdef MC_DEBUG
542       xbt_os_walltimer_stop(timer);
543       mc_comp_times->libsimgrid_global_variables_comparison_time = xbt_os_timer_elapsed(timer);
544       XBT_DEBUG("Different global variables in libsimgrid");
545       errors++;
546     #else
547       #ifdef MC_VERBOSE
548         XBT_VERB("Different global variables in libsimgrid");
549       #endif
550         
551       reset_heap_information();
552       xbt_os_timer_free(timer);
553       xbt_os_walltimer_stop(global_timer);
554       mc_snapshot_comparison_time = xbt_os_timer_elapsed(global_timer);
555       xbt_os_timer_free(global_timer);
556     
557       if(!raw_mem)
558         MC_UNSET_RAW_MEM;
559
560       return 1;
561     #endif
562   }
563     
564   #ifdef MC_DEBUG
565     xbt_os_walltimer_start(timer);
566   #endif
567
568   /* Compare heap */
569   if(mmalloc_compare_heap((xbt_mheap_t)s1->regions[0]->data, (xbt_mheap_t)s2->regions[0]->data) > 0){
570
571     #ifdef MC_DEBUG
572       xbt_os_walltimer_stop(timer);
573       mc_comp_times->heap_comparison_time = xbt_os_timer_elapsed(timer); 
574       XBT_DEBUG("Different heap (mmalloc_compare)");
575       errors++;
576     #else
577
578       xbt_os_timer_free(timer);
579  
580       #ifdef MC_VERBOSE
581         XBT_VERB("Different heap (mmalloc_compare)");
582       #endif
583        
584       reset_heap_information();
585       xbt_os_walltimer_stop(global_timer);
586       mc_snapshot_comparison_time = xbt_os_timer_elapsed(global_timer);
587       xbt_os_timer_free(global_timer);
588
589       if(!raw_mem)
590         MC_UNSET_RAW_MEM;
591
592       return 1;
593     #endif
594   }else{
595     #ifdef MC_DEBUG
596       xbt_os_walltimer_stop(timer);
597     #endif
598   }
599
600   reset_heap_information();
601    
602   xbt_os_timer_free(timer);
603
604   #ifdef MC_VERBOSE
605     xbt_os_walltimer_stop(global_timer);
606     mc_snapshot_comparison_time = xbt_os_timer_elapsed(global_timer);
607   #endif
608
609   xbt_os_timer_free(global_timer);
610
611   #ifdef MC_DEBUG
612     print_comparison_times();
613   #endif
614
615   if(!raw_mem)
616     MC_UNSET_RAW_MEM;
617
618   return errors > 0;
619   
620 }
621
622 int MC_compare_snapshots(void *s1, void *s2){
623   
624   MC_ignore_local_variable("self", "simcall_BODY_mc_snapshot");
625  
626   return simcall_mc_compare_snapshots(s1, s2);
627
628 }
629
630 void print_comparison_times(){
631   XBT_DEBUG("*** Comparison times ***");
632   XBT_DEBUG("- Nb processes : %f", mc_comp_times->nb_processes_comparison_time);
633   XBT_DEBUG("- Nb bytes used : %f", mc_comp_times->bytes_used_comparison_time);
634   XBT_DEBUG("- Stacks sizes : %f", mc_comp_times->stacks_sizes_comparison_time);
635   XBT_DEBUG("- Binary global variables : %f", mc_comp_times->binary_global_variables_comparison_time);
636   XBT_DEBUG("- Libsimgrid global variables : %f", mc_comp_times->libsimgrid_global_variables_comparison_time);
637   XBT_DEBUG("- Heap : %f", mc_comp_times->heap_comparison_time);
638   XBT_DEBUG("- Stacks : %f", mc_comp_times->stacks_comparison_time);
639 }