mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-21 10:50:23 +01:00
anv: Make sure all previous vm binds are done before execute perf query pool
The query pool batch buffer or other bos could not be bound when
exec starts.
Cc: 24.2 <mesa-stable>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30652>
(cherry picked from commit 141e7eaca7)
This commit is contained in:
parent
5e06c9d249
commit
0eaba0ef77
2 changed files with 9 additions and 1 deletions
|
|
@ -4524,7 +4524,7 @@
|
|||
"description": "anv: Make sure all previous vm binds are done before execute perf query pool",
|
||||
"nominated": true,
|
||||
"nomination_type": 0,
|
||||
"resolution": 0,
|
||||
"resolution": 1,
|
||||
"main_sha": null,
|
||||
"because_sha": null,
|
||||
"notes": null
|
||||
|
|
|
|||
|
|
@ -315,11 +315,14 @@ xe_queue_exec_locked(struct anv_queue *queue,
|
|||
perf_query_pass, &exec);
|
||||
|
||||
if (perf_query_pool && perf_query_pass >= 0 && cmd_buffer_count) {
|
||||
struct drm_xe_sync xe_syncs[1] = {};
|
||||
struct drm_xe_exec perf_query_exec = {
|
||||
.exec_queue_id = queue->exec_queue_id,
|
||||
.num_batch_buffer = 1,
|
||||
.address = perf_query_pool->bo->offset +
|
||||
khr_perf_query_preamble_offset(perf_query_pool, perf_query_pass),
|
||||
.num_syncs = 1,
|
||||
.syncs = (uintptr_t)xe_syncs,
|
||||
};
|
||||
assert(perf_query_pass < perf_query_pool->n_passes);
|
||||
struct intel_perf_query_info *query_info = perf_query_pool->pass_query[perf_query_pass];
|
||||
|
|
@ -340,6 +343,11 @@ xe_queue_exec_locked(struct anv_queue *queue,
|
|||
}
|
||||
}
|
||||
|
||||
xe_syncs[0].type = DRM_XE_SYNC_TYPE_TIMELINE_SYNCOBJ;
|
||||
xe_syncs[0].flags = 0;/* wait */
|
||||
xe_syncs[0].handle = intel_bind_timeline_get_syncobj(&device->bind_timeline);
|
||||
xe_syncs[0].timeline_value = intel_bind_timeline_get_last_point(&device->bind_timeline);
|
||||
|
||||
if (!device->info->no_hw && result == VK_SUCCESS) {
|
||||
if (intel_ioctl(device->fd, DRM_IOCTL_XE_EXEC, &perf_query_exec))
|
||||
result = vk_device_set_lost(&device->vk, "perf_query_exec failed: %m");
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue