From 907dddeafccdd9427d8bbc99c04463b1cfde1e71 Mon Sep 17 00:00:00 2001 From: Lionel Landwerlin Date: Fri, 5 Dec 2025 21:58:06 +0200 Subject: [PATCH] anv: add missing device_memory_report for shaders Signed-off-by: Lionel Landwerlin Fixes: d39e443ef8 ("anv: add infrastructure for common vk_pipeline") Acked-by: Michael Cheng Part-of: (cherry picked from commit 567c1b3af4ef8e95a3fd1163c95b4b77e25a5046) --- .pick_status.json | 2 +- src/intel/vulkan/anv_shader.c | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/.pick_status.json b/.pick_status.json index 4690d359958..f9248b25fbf 100644 --- a/.pick_status.json +++ b/.pick_status.json @@ -1614,7 +1614,7 @@ "description": "anv: add missing device_memory_report for shaders", "nominated": true, "nomination_type": 2, - "resolution": 0, + "resolution": 1, "main_sha": null, "because_sha": "d39e443ef888ffd9c3385ed4c40e727868626b6b", "notes": null diff --git a/src/intel/vulkan/anv_shader.c b/src/intel/vulkan/anv_shader.c index 891a4cf9696..f2b0e06f0fc 100644 --- a/src/intel/vulkan/anv_shader.c +++ b/src/intel/vulkan/anv_shader.c @@ -630,6 +630,7 @@ anv_shader_create(struct anv_device *device, shader->kernel = anv_state_pool_alloc(&device->instruction_state_pool, shader_data->prog_data.base.program_size, 64); + ANV_DMR_SP_ALLOC(&device->vk.base, &device->instruction_state_pool, shader->kernel); if (shader->kernel.alloc_size == 0) { result = vk_error(device, VK_ERROR_OUT_OF_DEVICE_MEMORY); goto error_embedded_samplers; @@ -716,6 +717,7 @@ anv_shader_create(struct anv_device *device, error_embedded_samplers: for (uint32_t s = 0; s < shader->bind_map.embedded_sampler_count; s++) anv_embedded_sampler_unref(device, shader->embedded_samplers[s]); + ANV_DMR_SP_FREE(&device->vk.base, &device->instruction_state_pool, shader->kernel); anv_state_pool_free(&device->instruction_state_pool, shader->kernel); error_shader: anv_state_pool_free(&device->instruction_state_pool, shader->kernel);