diff options
Diffstat (limited to 'linuxthreads/internals.h')
-rw-r--r-- | linuxthreads/internals.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/linuxthreads/internals.h b/linuxthreads/internals.h index 6b115be..17c8e4d 100644 --- a/linuxthreads/internals.h +++ b/linuxthreads/internals.h @@ -358,11 +358,15 @@ static inline pthread_descr thread_self (void) } /* If MEMORY_BARRIER isn't defined in pt-machine.h, assume the architecture - doesn't need a memory barrier instruction (e.g. Intel x86) */ + doesn't need a memory barrier instruction (e.g. Intel x86). Some + architectures distinguish between normal/read and write barriers. */ #ifndef MEMORY_BARRIER #define MEMORY_BARRIER() #endif +#ifndef WRITE_MEMORY_BARRIER +#define WRITE_MEMORY_BARRIER() MEMORY_BARRIER() +#endif /* Max number of times we must spin on a spinlock calling sched_yield(). After MAX_SPIN_COUNT iterations, we put the calling thread to sleep. */ |