diff options
author | Agustina Arzille <avarzille@riseup.net> | 2017-05-05 04:01:13 -1000 |
---|---|---|
committer | Richard Braun <rbraun@sceen.net> | 2017-05-09 21:17:58 +0200 |
commit | bcbe8dc991a9ec63f30d50ed4cca89fd9e6b7ff7 (patch) | |
tree | 389517510b8d19082d02f36453dbf68356b548fb /kern/thread_i.h | |
parent | b5864f82b9c0d8ea2e825e7d86bd8cdeb825f870 (diff) |
Replace sequential consistency with more efficient orders
Diffstat (limited to 'kern/thread_i.h')
-rw-r--r-- | kern/thread_i.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/kern/thread_i.h b/kern/thread_i.h index 34761e56..2e1b88aa 100644 --- a/kern/thread_i.h +++ b/kern/thread_i.h @@ -195,13 +195,13 @@ void thread_destroy(struct thread *thread); static inline void thread_set_flag(struct thread *thread, unsigned long flag) { - atomic_or(&thread->flags, flag, ATOMIC_SEQ_CST); + atomic_or_acq_rel(&thread->flags, flag); } static inline void thread_clear_flag(struct thread *thread, unsigned long flag) { - atomic_and(&thread->flags, ~flag, ATOMIC_SEQ_CST); + atomic_and_acq_rel(&thread->flags, ~flag); } static inline int |