Support process shared condition variables

This commit is contained in:
Justine Tunney 2024-07-22 16:33:23 -07:00
parent 3de6632be6
commit 0a9a6f86bb
No known key found for this signature in database
GPG key ID: BE714B4575D6E328
14 changed files with 168 additions and 19 deletions

View file

@ -3,6 +3,7 @@
#define PTHREAD_KEYS_MAX 46
#define PTHREAD_STACK_MIN 65536
#define PTHREAD_USE_NSYNC 1
#define PTHREAD_DESTRUCTOR_ITERATIONS 4
#define PTHREAD_BARRIER_SERIAL_THREAD 31337
@ -74,7 +75,15 @@ typedef struct pthread_mutexattr_s {
} pthread_mutexattr_t;
typedef struct pthread_cond_s {
void *_nsync[2];
union {
void *_align;
struct {
uint32_t _nsync;
char _pshared;
};
};
_Atomic(uint32_t) _sequence;
_Atomic(uint32_t) _waiters;
} pthread_cond_t;
typedef struct pthread_rwlock_s {