*/
typedef cnd_t pipe_condvar;
-#define pipe_condvar_init(cond) \
- cnd_init(&(cond))
-
#define pipe_condvar_destroy(cond) \
cnd_destroy(&(cond))
barrier->waiters = 0;
barrier->sequence = 0;
pipe_mutex_init(barrier->mutex);
- pipe_condvar_init(barrier->condvar);
+ cnd_init(&barrier->condvar);
}
static inline void pipe_barrier_destroy(pipe_barrier *barrier)
pipe_semaphore_init(pipe_semaphore *sema, int init_val)
{
pipe_mutex_init(sema->mutex);
- pipe_condvar_init(sema->cond);
+ cnd_init(&sema->cond);
sema->counter = init_val;
}
buf->slab = slab;
buf->start = i* mgr->bufSize;
buf->mapCount = 0;
- pipe_condvar_init(buf->event);
+ cnd_init(&buf->event);
LIST_ADDTAIL(&buf->head, &slab->freeBuffers);
slab->numFree++;
buf++;
{
memset(fence, 0, sizeof(*fence));
pipe_mutex_init(fence->mutex);
- pipe_condvar_init(fence->cond);
+ cnd_init(&fence->cond);
fence->signalled = true;
}
pipe_mutex_init(queue->lock);
queue->num_queued = 0;
- pipe_condvar_init(queue->has_queued_cond);
- pipe_condvar_init(queue->has_space_cond);
+ cnd_init(&queue->has_queued_cond);
+ cnd_init(&queue->has_space_cond);
queue->threads = (pipe_thread*)CALLOC(num_threads, sizeof(pipe_thread));
if (!queue->threads)
ring->mask = dwords - 1;
- pipe_condvar_init(ring->change);
+ cnd_init(&ring->change);
pipe_mutex_init(ring->mutex);
return ring;
pipe_reference_init(&fence->reference, 1);
pipe_mutex_init(fence->mutex);
- pipe_condvar_init(fence->signalled);
+ cnd_init(&fence->signalled);
fence->id = fence_id++;
fence->rank = rank;
return NULL;
pipe_mutex_init(rb_pipe->draw_mutex);
- pipe_condvar_init(rb_pipe->draw_cond);
+ cnd_init(&rb_pipe->draw_cond);
pipe_mutex_init(rb_pipe->call_mutex);
pipe_mutex_init(rb_pipe->list_mutex);
make_empty_list(&rb_pipe->shaders);
goto failed;
}
- pipe_condvar_init(ctx->event_pop);
+ cnd_init(&ctx->event_pop);
pipe_mutex_init(ctx->mutex_pop);
- pipe_condvar_init(ctx->event_push);
+ cnd_init(&ctx->event_push);
pipe_mutex_init(ctx->mutex_push);
/* Block until first cmdbuf has been flushed. */
FREE(ctx);
return NULL;
}
- pipe_condvar_init(ctx->event_processed);
+ cnd_init(&ctx->event_processed);
pipe_mutex_init(ctx->mutex_processed);
pipe_mutex_init(ctx->thread_running);
pipe_mutex_init(ctx->thread_resume);