unrealizedraces.push_back(race);
/* If the race is realized, bail out now. */
- if (checkDataRaces()) {
- model->set_assert();
- model->switch_to_master(NULL);
- }
+ if (checkDataRaces())
+ model->assert_bug("Data race", true);
}
/** This function goes through the list of unrealized data races,
void printRace(struct DataRace *race)
{
- printf("Datarace detected @ address %p:\n", race->address);
+ printf("Data race detected @ address %p:\n", race->address);
printf(" Access 1: %5s in thread %2d @ clock %3u\n",
race->isoldwrite ? "write" : "read",
id_to_int(race->oldthread), race->oldclock);