I.e., those used with wined3d_cs_init_object() and wined3d_cs_destroy_object().
Signed-off-by: Henri Verbeet hverbeet@codeweavers.com --- dlls/wined3d/adapter_gl.c | 6 ++++++ dlls/wined3d/adapter_vk.c | 6 ++++++ dlls/wined3d/buffer.c | 2 ++ dlls/wined3d/device.c | 4 ++++ dlls/wined3d/palette.c | 2 ++ dlls/wined3d/query.c | 2 ++ dlls/wined3d/resource.c | 2 ++ dlls/wined3d/sampler.c | 4 ++++ dlls/wined3d/shader.c | 4 ++++ dlls/wined3d/state.c | 6 ++++++ dlls/wined3d/swapchain.c | 2 ++ dlls/wined3d/texture.c | 2 ++ dlls/wined3d/vertexdeclaration.c | 2 ++ dlls/wined3d/view.c | 12 ++++++++++++ 14 files changed, 56 insertions(+)
diff --git a/dlls/wined3d/adapter_gl.c b/dlls/wined3d/adapter_gl.c index a9454ee38ebf..e12a1ff13b7f 100644 --- a/dlls/wined3d/adapter_gl.c +++ b/dlls/wined3d/adapter_gl.c @@ -4768,6 +4768,8 @@ static void wined3d_view_gl_destroy_object(void *object) struct wined3d_device *device; GLuint counter_id;
+ TRACE("ctx %p.\n", ctx); + device = ctx->device;
counter_id = ctx->counter_bo ? ctx->counter_bo->id : 0; @@ -4947,6 +4949,8 @@ static void wined3d_sampler_gl_destroy_object(void *object) const struct wined3d_gl_info *gl_info; struct wined3d_context *context;
+ TRACE("sampler_gl %p.\n", sampler_gl); + if (sampler_gl->name) { context = context_acquire(sampler_gl->s.device, NULL, 0); @@ -4980,6 +4984,8 @@ static void wined3d_query_gl_destroy_object(void *object) { struct wined3d_query *query = object;
+ TRACE("query %p.\n", query); + if (query->buffer_object) { struct wined3d_context *context; diff --git a/dlls/wined3d/adapter_vk.c b/dlls/wined3d/adapter_vk.c index 62032fb74c57..8c79cc050584 100644 --- a/dlls/wined3d/adapter_vk.c +++ b/dlls/wined3d/adapter_vk.c @@ -1320,6 +1320,8 @@ static void wined3d_view_vk_destroy_object(void *object) struct wined3d_device_vk *device_vk; struct wined3d_context *context;
+ TRACE("ctx %p.\n", ctx); + device_vk = ctx->device_vk; vk_info = &wined3d_adapter_vk(device_vk->d.adapter)->vk_info; context = context_acquire(&device_vk->d, NULL, 0); @@ -1550,6 +1552,8 @@ static void wined3d_sampler_vk_destroy_object(void *object) struct wined3d_sampler_vk *sampler_vk = object; struct wined3d_context_vk *context_vk;
+ TRACE("sampler_vk %p.\n", sampler_vk); + context_vk = wined3d_context_vk(context_acquire(sampler_vk->s.device, NULL, 0));
wined3d_context_vk_destroy_sampler(context_vk, sampler_vk->vk_image_info.sampler, sampler_vk->command_buffer_id); @@ -1580,6 +1584,8 @@ static void wined3d_query_vk_destroy_object(void *object) { struct wined3d_query_vk *query_vk = object;
+ TRACE("query_vk %p.\n", query_vk); + query_vk->q.query_ops->query_destroy(&query_vk->q); }
diff --git a/dlls/wined3d/buffer.c b/dlls/wined3d/buffer.c index 4ab26c050401..9ea62a81d0b5 100644 --- a/dlls/wined3d/buffer.c +++ b/dlls/wined3d/buffer.c @@ -669,6 +669,8 @@ static void wined3d_buffer_destroy_object(void *object) struct wined3d_buffer *buffer = object; struct wined3d_context *context;
+ TRACE("buffer %p.\n", buffer); + if (buffer->buffer_object) { context = context_acquire(buffer->resource.device, NULL, 0); diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c index f61708219ac3..1fd5f4b012e5 100644 --- a/dlls/wined3d/device.c +++ b/dlls/wined3d/device.c @@ -1005,6 +1005,8 @@ void wined3d_device_delete_opengl_contexts_cs(void *object) struct wined3d_context *context; struct wined3d_shader *shader;
+ TRACE("device %p.\n", device); + device_gl = wined3d_device_gl(device);
LIST_FOR_EACH_ENTRY(shader, &device->shaders, struct wined3d_shader, shader_list_entry) @@ -1038,6 +1040,8 @@ void wined3d_device_create_primary_opengl_context_cs(void *object) struct wined3d_texture *target; HRESULT hr;
+ TRACE("device %p.\n", device); + swapchain = device->swapchains[0]; target = swapchain->back_buffers ? swapchain->back_buffers[0] : swapchain->front_buffer; if (!(context = context_acquire(device, target, 0))) diff --git a/dlls/wined3d/palette.c b/dlls/wined3d/palette.c index d78a364aaf52..615fb00905fc 100644 --- a/dlls/wined3d/palette.c +++ b/dlls/wined3d/palette.c @@ -35,6 +35,8 @@ ULONG CDECL wined3d_palette_incref(struct wined3d_palette *palette)
static void wined3d_palette_destroy_object(void *object) { + TRACE("object %p.\n", object); + heap_free(object); }
diff --git a/dlls/wined3d/query.c b/dlls/wined3d/query.c index 4670bbfddffe..b239ee895f6d 100644 --- a/dlls/wined3d/query.c +++ b/dlls/wined3d/query.c @@ -428,6 +428,8 @@ static void wined3d_query_destroy_object(void *object) { struct wined3d_query *query = object;
+ TRACE("query %p.\n", query); + if (!list_empty(&query->poll_list_entry)) list_remove(&query->poll_list_entry); } diff --git a/dlls/wined3d/resource.c b/dlls/wined3d/resource.c index d91ed26ef3f2..8f2dc9ad0958 100644 --- a/dlls/wined3d/resource.c +++ b/dlls/wined3d/resource.c @@ -233,6 +233,8 @@ static void wined3d_resource_destroy_object(void *object) { struct wined3d_resource *resource = object;
+ TRACE("resource %p.\n", resource); + heap_free(resource->sub_resource_bind_counts_device); wined3d_resource_free_sysmem(resource); context_resource_released(resource->device, resource); diff --git a/dlls/wined3d/sampler.c b/dlls/wined3d/sampler.c index 8d909627a18c..38ede905deb8 100644 --- a/dlls/wined3d/sampler.c +++ b/dlls/wined3d/sampler.c @@ -76,6 +76,8 @@ static void wined3d_sampler_gl_cs_init(void *object) struct wined3d_context *context; GLuint name;
+ TRACE("sampler_gl %p.\n", sampler_gl); + context = context_acquire(sampler_gl->s.device, NULL, 0); gl_info = wined3d_context_gl(context)->gl_info;
@@ -182,6 +184,8 @@ static void wined3d_sampler_vk_cs_init(void *object) VkSampler vk_sampler; VkResult vr;
+ TRACE("sampler_vk %p.\n", sampler_vk); + context_vk = wined3d_context_vk(context_acquire(sampler_vk->s.device, NULL, 0)); device_vk = wined3d_device_vk(context_vk->c.device); d3d_info = context_vk->c.d3d_info; diff --git a/dlls/wined3d/shader.c b/dlls/wined3d/shader.c index 9052d217148c..e11429901390 100644 --- a/dlls/wined3d/shader.c +++ b/dlls/wined3d/shader.c @@ -3404,6 +3404,8 @@ static void wined3d_shader_init_object(void *object) struct wined3d_shader *shader = object; struct wined3d_device *device = shader->device;
+ TRACE("shader %p.\n", shader); + list_add_head(&device->shaders, &shader->shader_list_entry);
device->shader_backend->shader_precompile(device->shader_priv, shader); @@ -3411,6 +3413,8 @@ static void wined3d_shader_init_object(void *object)
static void wined3d_shader_destroy_object(void *object) { + TRACE("object %p.\n", object); + shader_cleanup(object); heap_free(object); } diff --git a/dlls/wined3d/state.c b/dlls/wined3d/state.c index f454a7a38016..1194604e7dc8 100644 --- a/dlls/wined3d/state.c +++ b/dlls/wined3d/state.c @@ -48,6 +48,8 @@ ULONG CDECL wined3d_blend_state_incref(struct wined3d_blend_state *state)
static void wined3d_blend_state_destroy_object(void *object) { + TRACE("object %p.\n", object); + heap_free(object); }
@@ -120,6 +122,8 @@ ULONG CDECL wined3d_depth_stencil_state_incref(struct wined3d_depth_stencil_stat
static void wined3d_depth_stencil_state_destroy_object(void *object) { + TRACE("object %p.\n", object); + heap_free(object); }
@@ -181,6 +185,8 @@ ULONG CDECL wined3d_rasterizer_state_incref(struct wined3d_rasterizer_state *sta
static void wined3d_rasterizer_state_destroy_object(void *object) { + TRACE("object %p.\n", object); + heap_free(object); }
diff --git a/dlls/wined3d/swapchain.c b/dlls/wined3d/swapchain.c index 1671abb698df..5fae34c8af5f 100644 --- a/dlls/wined3d/swapchain.c +++ b/dlls/wined3d/swapchain.c @@ -1725,6 +1725,8 @@ void wined3d_swapchain_gl_destroy_contexts(struct wined3d_swapchain_gl *swapchai { unsigned int i;
+ TRACE("swapchain_gl %p.\n", swapchain_gl); + for (i = 0; i < swapchain_gl->context_count; ++i) { wined3d_context_gl_destroy(swapchain_gl->contexts[i]); diff --git a/dlls/wined3d/texture.c b/dlls/wined3d/texture.c index 5bb4de05d5c0..f4f929db2cab 100644 --- a/dlls/wined3d/texture.c +++ b/dlls/wined3d/texture.c @@ -1021,6 +1021,8 @@ static void wined3d_texture_destroy_dc(void *object) struct wined3d_range range; NTSTATUS status;
+ TRACE("texture %p, sub_resource_idx %u.\n", idx->texture, idx->sub_resource_idx); + texture = idx->texture; sub_resource_idx = idx->sub_resource_idx; device = texture->resource.device; diff --git a/dlls/wined3d/vertexdeclaration.c b/dlls/wined3d/vertexdeclaration.c index b17059f5e644..45a01f4bdd43 100644 --- a/dlls/wined3d/vertexdeclaration.c +++ b/dlls/wined3d/vertexdeclaration.c @@ -54,6 +54,8 @@ static void wined3d_vertex_declaration_destroy_object(void *object) { struct wined3d_vertex_declaration *declaration = object;
+ TRACE("declaration %p.\n", declaration); + heap_free(declaration->elements); heap_free(declaration); } diff --git a/dlls/wined3d/view.c b/dlls/wined3d/view.c index c3128c9ed4cd..9650f6c08e34 100644 --- a/dlls/wined3d/view.c +++ b/dlls/wined3d/view.c @@ -511,6 +511,8 @@ static void wined3d_render_target_view_gl_cs_init(void *object) struct wined3d_resource *resource = view_gl->v.resource; const struct wined3d_view_desc *desc = &view_gl->v.desc;
+ TRACE("view_gl %p.\n", view_gl); + if (resource->type == WINED3D_RTYPE_BUFFER) { FIXME("Not implemented for resources %s.\n", debug_d3dresourcetype(resource->type)); @@ -792,6 +794,8 @@ static void wined3d_render_target_view_vk_cs_init(void *object) struct wined3d_context *context; uint32_t default_flags = 0;
+ TRACE("view_vk %p.\n", view_vk); + resource = view_vk->v.resource; if (resource->type == WINED3D_RTYPE_BUFFER) { @@ -934,6 +938,8 @@ static void wined3d_shader_resource_view_gl_cs_init(void *object) const struct wined3d_view_desc *desc; GLenum view_target;
+ TRACE("view_gl %p.\n", view_gl); + view_format = view_gl->v.format; gl_info = &resource->device->adapter->gl_info; desc = &view_gl->v.desc; @@ -1055,6 +1061,8 @@ static void wined3d_shader_resource_view_vk_cs_init(void *object) uint32_t default_flags = 0; VkImageView vk_image_view;
+ TRACE("srv_vk %p.\n", srv_vk); + resource = srv_vk->v.resource; format = srv_vk->v.format;
@@ -1421,6 +1429,8 @@ static void wined3d_unordered_access_view_gl_cs_init(void *object) struct wined3d_view_desc *desc = &view_gl->v.desc; const struct wined3d_gl_info *gl_info;
+ TRACE("view_gl %p.\n", view_gl); + gl_info = &resource->device->adapter->gl_info;
if (resource->type == WINED3D_RTYPE_BUFFER) @@ -1598,6 +1608,8 @@ static void wined3d_unordered_access_view_vk_cs_init(void *object) VkImageView vk_image_view; VkResult vr;
+ TRACE("uav_vk %p.\n", uav_vk); + resource = uav_vk->v.resource; device_vk = wined3d_device_vk(resource->device); format_vk = wined3d_format_vk(uav_vk->v.format);