projects
/
c11tester.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
datarace: use variable-argument bug-printing
[c11tester.git]
/
action.cc
diff --git
a/action.cc
b/action.cc
index 4de6f354bfbccfbedc9061538ecb48be8e69e3e2..34bc09f0be567c3ff4b30e084e52d911b12fd8cc 100644
(file)
--- a/
action.cc
+++ b/
action.cc
@@
-77,6
+77,11
@@
bool ModelAction::is_thread_start() const
return type == THREAD_START;
}
return type == THREAD_START;
}
+bool ModelAction::is_thread_join() const
+{
+ return type == THREAD_JOIN;
+}
+
bool ModelAction::is_relseq_fixup() const
{
return type == MODEL_FIXUP_RELSEQ;
bool ModelAction::is_relseq_fixup() const
{
return type == MODEL_FIXUP_RELSEQ;
@@
-625,8
+630,13
@@
unsigned int ModelAction::hash() const
hash ^= seq_number << 5;
hash ^= id_to_int(tid) << 6;
hash ^= seq_number << 5;
hash ^= id_to_int(tid) << 6;
- if (is_read() && reads_from)
- hash ^= reads_from->get_seq_number();
+ if (is_read()) {
+ if (reads_from)
+ hash ^= reads_from->get_seq_number();
+ else if (reads_from_promise)
+ hash ^= model->get_promise_number(reads_from_promise);
+ hash ^= get_reads_from_value();
+ }
return hash;
}
return hash;
}