libnx/nx/include/switch/kernel/barrier.h
2018-10-16 16:44:48 -04:00

17 lines
291 B
C

#pragma once
#include "semaphore.h"
// barrier structure
typedef struct barrier{
u64 count;
u64 thread_total;
Semaphore throttle;
Semaphore lock;
Semaphore thread_wait;
} barrier;
void barrierInit(barrier *my_barrier, u64 thread_count);
void barrierWait(barrier *b);