projects
/
c11tester.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
110873a
)
ignore futex notify if no successful futex wait was performed in the same location...
author
weiyu
<weiyuluo1232@gmail.com>
Mon, 15 Jul 2019 20:28:39 +0000
(13:28 -0700)
committer
weiyu
<weiyuluo1232@gmail.com>
Mon, 15 Jul 2019 20:28:39 +0000
(13:28 -0700)
futex.cc
patch
|
blob
|
history
diff --git
a/futex.cc
b/futex.cc
index 0647337bc725b61d0110953e8670bc01784b6a7f..11685d3826e0c117d724cb60e877f1925402f530 100644
(file)
--- a/
futex.cc
+++ b/
futex.cc
@@
-61,6
+61,10
@@
namespace std _GLIBCXX_VISIBILITY(default)
// INT_MAX wakes all the waiters at the address __addr
ModelExecution *execution = model->get_execution();
cdsc::condition_variable *v = execution->getCondMap()->get( (pthread_cond_t *) __addr);
+
+ if (v == NULL)
+ return; // do nothing
+
v->notify_all();
}