Lines Matching refs:fence
115 struct drm_i915_gem_exec_fence *fence =
118 *fence = (struct drm_i915_gem_exec_fence) {
153 struct drm_i915_gem_exec_fence *fence =
156 assert(fence->flags & I915_EXEC_FENCE_WAIT);
175 memcpy(fence, nth_fence, sizeof(*fence));
192 struct pipe_fence_handle *fence)
196 for (unsigned i = 0; i < ARRAY_SIZE(fence->fine); i++)
197 iris_fine_fence_reference(screen, &fence->fine[i], NULL);
199 free(fence);
280 struct pipe_fence_handle *fence = calloc(1, sizeof(*fence));
281 if (!fence)
284 pipe_reference_init(&fence->ref, 1);
287 fence->unflushed_ctx = ctx;
295 iris_fine_fence_reference(screen, &fence->fine[b], fine);
305 iris_fine_fence_reference(screen, &fence->fine[b], batch->last_fence);
310 *out_fence = fence;
315 struct pipe_fence_handle *fence)
320 if (ctx && ctx == fence->unflushed_ctx)
330 if (fence->unflushed_ctx) {
332 "glWaitSync on unflushed fence from another context "
336 for (unsigned i = 0; i < ARRAY_SIZE(fence->fine); i++) {
337 struct iris_fine_fence *fine = fence->fine[i];
344 * fence to have gone by. But any currently queued work doesn't
386 struct pipe_fence_handle *fence,
394 /* If we created the fence with PIPE_FLUSH_DEFERRED, we may not have
399 * the context the fence was created with. It may be NULL, so we check
402 if (ctx && ctx == fence->unflushed_ctx) {
404 struct iris_fine_fence *fine = fence->fine[batch->name];
413 /* The fence is no longer deferred. */
414 fence->unflushed_ctx = NULL;
418 uint32_t handles[ARRAY_SIZE(fence->fine)];
419 for (unsigned i = 0; i < ARRAY_SIZE(fence->fine); i++) {
420 struct iris_fine_fence *fine = fence->fine[i];
438 if (fence->unflushed_ctx) {
439 /* This fence had a deferred flush from another context. We can't
462 .name = "iris fence",
464 .fence = -1,
471 return args.fence;
476 struct pipe_fence_handle *fence)
482 if (fence->unflushed_ctx)
485 for (unsigned i = 0; i < ARRAY_SIZE(fence->fine); i++) {
486 struct iris_fine_fence *fine = fence->fine[i];
502 /* Our fence has no syncobj's recorded. This means that all of the
505 * export such a fence. So export a dummy already-signalled syncobj.
565 * seqno for an imported fence. So, create a fake one which always
574 struct pipe_fence_handle *fence = calloc(1, sizeof(*fence));
575 if (!fence) {
581 pipe_reference_init(&fence->ref, 1);
582 fence->fine[0] = fine;
584 *out = fence;
589 struct pipe_fence_handle *fence)
593 if (ctx == fence->unflushed_ctx)
597 for (unsigned i = 0; i < ARRAY_SIZE(fence->fine); i++) {
598 struct iris_fine_fence *fine = fence->fine[i];
600 /* already signaled fence skipped */