set_backtracking(curr);
/* Assign reads_from values */
- /* TODO: perform release/acquire synchronization here; include
- * reads_from as ModelAction member? */
Thread *th = get_thread(curr->get_tid());
uint64_t value = VALUE_NONE;
if (curr->is_read()) {
/** Process a RMW by converting previous read into a RMW. */
void ModelChecker::process_rmw(ModelAction * act) {
int tid = id_to_int(act->get_tid());
- std::vector<action_list_t> *vec = &(*obj_thrd_map)[act->get_location()];
- ASSERT(tid < (int) vec->size());
- ModelAction *lastread=(*vec)[tid].back();
+ ModelAction *lastread=get_last_action(tid);
lastread->upgrade_rmw(act);
+ cyclegraph->addRMWEdge(lastread->get_reads_from(),lastread);
}
/**