continue;
}
- if (heapinfo1->type < 0) {
- fprintf(stderr, "Unkown mmalloc block type.\n");
- abort();
- }
+ xbt_assert(heapinfo1->type >= 0, "Unkown mmalloc block type: %d", heapinfo1->type);
void* addr_block1 = ((void*)(((ADDR2UINT(i1)) - 1) * BLOCKSIZE + (char*)state.std_heap_copy.heapbase));
continue;
}
- if (heapinfo2b->type < 0) {
- fprintf(stderr, "Unknown mmalloc block type.\n");
- abort();
- }
+ xbt_assert(heapinfo2b->type >= 0, "Unkown mmalloc block type: %d", heapinfo2b->type);
for (size_t j2 = 0; j2 < (size_t)(BLOCKSIZE >> heapinfo2b->type); j2++) {
1) != 0) {
int pointer_align = (i / sizeof(void *)) * sizeof(void *);
- const void* addr_pointed1 = snapshot1.read(remote((void**)((const char*)real_area1 + pointer_align)));
- const void* addr_pointed2 = snapshot2.read(remote((void**)((const char*)real_area2 + pointer_align)));
+ const void* addr_pointed1 = snapshot1.read(remote((void* const*)((const char*)real_area1 + pointer_align)));
+ const void* addr_pointed2 = snapshot2.read(remote((void* const*)((const char*)real_area2 + pointer_align)));
if (process.in_maestro_stack(remote(addr_pointed1)) && process.in_maestro_stack(remote(addr_pointed2))) {
i = pointer_align + sizeof(void *);
default:
THROW_IMPOSSIBLE;
}
- return false;
}
/** Infer the type of a part of the block from the type of the block
}
for (i = 0; i < type->element_count; i++) {
size_t off = i * elm_size;
- if (areas_differ_with_type(state, (char*)real_area1 + off, snapshot1, region1, (char*)real_area2 + off,
- snapshot2, region2, type->subtype, pointer_level))
+ if (areas_differ_with_type(state, (const char*)real_area1 + off, snapshot1, region1,
+ (const char*)real_area2 + off, snapshot2, region2, type->subtype, pointer_level))
return true;
}
break;