Skip to content
Snippets Groups Projects
Commit f160966c authored by Lionel Landwerlin's avatar Lionel Landwerlin Committed by Eric Engestrom
Browse files

anv: garbage collect timeline semaphore when querying value


If we don't garbage collect the timeline, the value never progresses
even though work completed.

Signed-off-by: default avatarLionel Landwerlin <lionel.g.landwerlin@intel.com>
Closes: mesa/mesa#3226


Fixes: 34f32a6d ("anv: implement VK_KHR_timeline_semaphore")
Reviewed-by: default avatarBas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Reviewed-by: default avatarJason Ekstrand <jason@jlekstrand.net>
Part-of: <mesa/mesa!5774>
(cherry picked from commit edc8119d)
parent 7220acf5
No related branches found
No related tags found
No related merge requests found
......@@ -1093,7 +1093,7 @@
"description": "anv: garbage collect timeline semaphore when querying value",
"nominated": true,
"nomination_type": 1,
"resolution": 0,
"resolution": 1,
"master_sha": null,
"because_sha": "34f32a6d6648073e2fda3fb78377124fb32bb288"
},
......
......@@ -2167,6 +2167,7 @@ VkResult anv_GetSemaphoreCounterValue(
switch (impl->type) {
case ANV_SEMAPHORE_TYPE_TIMELINE: {
pthread_mutex_lock(&device->mutex);
anv_timeline_gc_locked(device, &impl->timeline);
*pValue = impl->timeline.highest_past;
pthread_mutex_unlock(&device->mutex);
return VK_SUCCESS;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment