Lines Matching refs:pool
39 struct anv_query_pool *pool; in anv_CreateQueryPool() local
57 pool = vk_alloc2(&device->alloc, pAllocator, sizeof(*pool), 8, in anv_CreateQueryPool()
59 if (pool == NULL) in anv_CreateQueryPool()
62 pool->type = pCreateInfo->queryType; in anv_CreateQueryPool()
63 pool->slots = pCreateInfo->queryCount; in anv_CreateQueryPool()
66 result = anv_bo_init_new(&pool->bo, device, size); in anv_CreateQueryPool()
70 pool->bo.map = anv_gem_mmap(device, pool->bo.gem_handle, 0, size, 0); in anv_CreateQueryPool()
72 *pQueryPool = anv_query_pool_to_handle(pool); in anv_CreateQueryPool()
77 vk_free2(&device->alloc, pAllocator, pool); in anv_CreateQueryPool()
88 ANV_FROM_HANDLE(anv_query_pool, pool, _pool); in anv_DestroyQueryPool()
90 if (!pool) in anv_DestroyQueryPool()
93 anv_gem_munmap(pool->bo.map, pool->bo.size); in anv_DestroyQueryPool()
94 anv_gem_close(device, pool->bo.gem_handle); in anv_DestroyQueryPool()
95 vk_free2(&device->alloc, pAllocator, pool); in anv_DestroyQueryPool()
109 ANV_FROM_HANDLE(anv_query_pool, pool, queryPool); in anv_GetQueryPoolResults()
114 assert(pool->type == VK_QUERY_TYPE_OCCLUSION || in anv_GetQueryPoolResults()
115 pool->type == VK_QUERY_TYPE_TIMESTAMP); in anv_GetQueryPoolResults()
121 ret = anv_gem_wait(device, pool->bo.gem_handle, &timeout); in anv_GetQueryPoolResults()
130 struct anv_query_pool_slot *slot = pool->bo.map; in anv_GetQueryPoolResults()
135 anv_invalidate_range(pool->bo.map + offset, in anv_GetQueryPoolResults()
136 MIN2(size, pool->bo.size - offset)); in anv_GetQueryPoolResults()
155 switch (pool->type) { in anv_GetQueryPoolResults()