Abstractions for operating system specific stuff.
More...
#include "global.h"
#include <pthread.h>
#include <windows.h>
#include <semaphore.h>
Go to the source code of this file.
◆ KVZ_ATOMIC_DEC
#define KVZ_ATOMIC_DEC |
( |
|
ptr | ) |
InterlockedDecrement((volatile LONG*)ptr) |
◆ KVZ_ATOMIC_INC
#define KVZ_ATOMIC_INC |
( |
|
ptr | ) |
InterlockedIncrement((volatile LONG*)ptr) |
◆ KVZ_CLOCK_T
#define KVZ_CLOCK_T struct _FILETIME |
◆ KVZ_CLOCK_T_AS_DOUBLE
#define KVZ_CLOCK_T_AS_DOUBLE |
( |
|
ts | ) |
((double)(((uint64_t)(ts).dwHighDateTime)<<32 | (uint64_t)(ts).dwLowDateTime) / 1e7) |
◆ KVZ_CLOCK_T_DIFF
#define KVZ_CLOCK_T_DIFF |
( |
|
start, |
|
|
|
stop |
|
) |
| |
Value: ((double)((((uint64_t)(stop).dwHighDateTime)<<32 | (uint64_t)(stop).dwLowDateTime) - \
(((uint64_t)(start).dwHighDateTime)<<32 | (uint64_t)(start).dwLowDateTime)) / 1e7)
◆ KVZ_GET_TIME
#define KVZ_GET_TIME |
( |
|
clock_t | ) |
{ GetSystemTimeAsFileTime(clock_t); } |
◆ kvz_sem_t
◆ kvz_sem_destroy()
static void kvz_sem_destroy |
( |
kvz_sem_t * |
sem | ) |
|
|
inlinestatic |
◆ kvz_sem_init()
static void kvz_sem_init |
( |
kvz_sem_t * |
sem, |
|
|
int |
value |
|
) |
| |
|
inlinestatic |
◆ kvz_sem_post()
◆ kvz_sem_wait()