projects
/
cdsspec-compiler.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
execution: document additional mo_may_allow() optimization
[cdsspec-compiler.git]
/
impatomic.cc
diff --git
a/impatomic.cc
b/impatomic.cc
index 571789d662f154e109025e23c6d09ac89f998692..2d48989c147d051bd61d3a4d01fe0e2ba1bcf9ea 100644
(file)
--- a/
impatomic.cc
+++ b/
impatomic.cc
@@
-2,13
+2,13
@@
#include "common.h"
#include "model.h"
#include "threads-model.h"
#include "common.h"
#include "model.h"
#include "threads-model.h"
+#include "action.h"
namespace std {
bool atomic_flag_test_and_set_explicit ( volatile atomic_flag * __a__, memory_order __x__ ) {
volatile bool * __p__ = &((__a__)->__f__);
namespace std {
bool atomic_flag_test_and_set_explicit ( volatile atomic_flag * __a__, memory_order __x__ ) {
volatile bool * __p__ = &((__a__)->__f__);
- model->switch_to_master(new ModelAction(ATOMIC_RMWR, __x__, (void *) __p__));
- bool result = (bool) thread_current()->get_return_value();
+ bool result = (bool) model->switch_to_master(new ModelAction(ATOMIC_RMWR, __x__, (void *) __p__));
model->switch_to_master(new ModelAction(ATOMIC_RMW, __x__, (void *) __p__, true));
return result;
}
model->switch_to_master(new ModelAction(ATOMIC_RMW, __x__, (void *) __p__, true));
return result;
}