33 #ifndef _CTHREAD_BARRIER_H_
34 #define _CTHREAD_BARRIER_H_
36 #include "cthread_mutex.h"
37 #include "cthread_cond.h"
43 #define MAX_BARRIER_NAME_SIZE 32
45 struct cthread_barrier {
47 struct cthread_mutex *mutex;
48 struct cthread_cond *cv;
50 CNE_ATOMIC(uint_fast32_t) count;
51 CNE_ATOMIC(uint_fast32_t) waiters;
52 CNE_ATOMIC(uint_fast32_t) refcount;
53 CNE_ATOMIC(uint_fast32_t) destroying;
54 char name[MAX_BARRIER_NAME_SIZE];
#define __cne_cache_aligned