+/* MC interface: definitions that non-MC modules must see, but not the user */
+
+/* Copyright (c) 2014-2015. The SimGrid Team. All rights reserved. */
+
+/* This program is free software; you can redistribute it and/or modify it
+ * under the terms of the license (GNU LGPL) which comes with this package. */
+
#include <unistd.h> // pread, pwrite
#include "mc_page_store.h"
- move the segments in shared memory (this will break `fork` however).
*/
page_data = temp;
- MC_process_read(process, temp, page, xbt_pagesize);
+ MC_process_read(process, MC_ADDRESS_SPACE_READ_FLAGS_NONE,
+ temp, page, xbt_pagesize, MC_PROCESS_INDEX_DISABLED);
}
pagenos[i] = mc_model_checker->pages->store_page(page_data);
}
uint64_t* pagemap = NULL;
if (_sg_mc_soft_dirty && mc_model_checker->parent_snapshot &&
MC_process_is_self(process)) {
- pagemap = (uint64_t*) mmalloc_no_memset(mc_heap, sizeof(uint64_t) * page_count);
+ pagemap = (uint64_t*) malloc_no_memset(sizeof(uint64_t) * page_count);
mc_read_pagemap(pagemap, mc_page_number(NULL, permanent_addr), page_count);
}
// Read soft-dirty bits if necessary in order to know which pages have changed:
if (_sg_mc_soft_dirty && mc_model_checker->parent_snapshot
&& MC_process_is_self(process)) {
- pagemap = (uint64_t*) mmalloc_no_memset(mc_heap, sizeof(uint64_t) * page_count);
+ pagemap = (uint64_t*) malloc_no_memset(sizeof(uint64_t) * page_count);
mc_read_pagemap(pagemap, mc_page_number(NULL, reg->permanent_addr), page_count);
}