#include <xbt/probes.h>
+using simgrid::mc::remote;
+
typedef struct s_pointers_pair {
void *p1;
void *p2;
}
size_t process_count = MC_smpi_process_count();
- xbt_assert(process_count == r1->privatized.regions_count
- && process_count == r2->privatized.regions_count);
+ xbt_assert(process_count == r1->privatized_data().size()
+ && process_count == r2->privatized_data().size());
// Compare the global variables separately for each simulates process:
for (size_t process_index = 0; process_index < process_count; process_index++) {
int is_diff = compare_global_variables(object_info, process_index,
- r1->privatized.regions[process_index], r2->privatized.regions[process_index],
+ r1->privatized_data()[process_index].get(),
+ r2->privatized_data()[process_index].get(),
snapshot1, snapshot2);
if (is_diff) return 1;
}
#endif
/* Init heap information used in heap comparison algorithm */
- xbt_mheap_t heap1 = (xbt_mheap_t) MC_snapshot_read(
- s1, MC_ADDRESS_SPACE_READ_FLAGS_LAZY,
- alloca(sizeof(struct mdesc)), process->heap_address, sizeof(struct mdesc),
- MC_PROCESS_INDEX_MISSING);
- xbt_mheap_t heap2 = (xbt_mheap_t) MC_snapshot_read(
- s2, MC_ADDRESS_SPACE_READ_FLAGS_LAZY,
- alloca(sizeof(struct mdesc)), process->heap_address, sizeof(struct mdesc),
- MC_PROCESS_INDEX_MISSING);
+ xbt_mheap_t heap1 = (xbt_mheap_t)s1->read_bytes(
+ alloca(sizeof(struct mdesc)), sizeof(struct mdesc),
+ remote(process->heap_address),
+ simgrid::mc::ProcessIndexMissing, simgrid::mc::AddressSpace::Lazy);
+ xbt_mheap_t heap2 = (xbt_mheap_t)s2->read_bytes(
+ alloca(sizeof(struct mdesc)), sizeof(struct mdesc),
+ remote(process->heap_address),
+ simgrid::mc::ProcessIndexMissing, simgrid::mc::AddressSpace::Lazy);
res_init = init_heap_information(heap1, heap2, s1->to_ignore, s2->to_ignore);
if (res_init == -1) {
#ifdef MC_DEBUG
/* Compare global variables */
is_diff =
- compare_global_variables(region1->object_info, MC_ADDRESS_SPACE_READ_FLAGS_NONE,
+ compare_global_variables(region1->object_info, simgrid::mc::AddressSpace::Normal,
region1, region2,
s1, s2);