vkd3d: Use vkd3d_atomic_increment_u32() in d3d12_pipeline_state_AddRef().

This commit is contained in:
Henri Verbeet 2024-01-23 18:19:52 +01:00 committed by Alexandre Julliard
parent 9e135f6143
commit c71fa87522
Notes: Alexandre Julliard 2024-02-01 23:08:25 +01:00
Approved-by: Giovanni Mascellani (@giomasce)
Approved-by: Alexandre Julliard (@julliard)
Merge-Request: https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/623
2 changed files with 3 additions and 3 deletions

View File

@ -1984,7 +1984,7 @@ static HRESULT STDMETHODCALLTYPE d3d12_pipeline_state_QueryInterface(ID3D12Pipel
static ULONG STDMETHODCALLTYPE d3d12_pipeline_state_AddRef(ID3D12PipelineState *iface)
{
struct d3d12_pipeline_state *state = impl_from_ID3D12PipelineState(iface);
ULONG refcount = InterlockedIncrement(&state->refcount);
unsigned int refcount = vkd3d_atomic_increment_u32(&state->refcount);
TRACE("%p increasing refcount to %u.\n", state, refcount);
@ -2027,7 +2027,7 @@ static void d3d12_pipeline_uav_counter_state_cleanup(struct d3d12_pipeline_uav_c
static ULONG STDMETHODCALLTYPE d3d12_pipeline_state_Release(ID3D12PipelineState *iface)
{
struct d3d12_pipeline_state *state = impl_from_ID3D12PipelineState(iface);
ULONG refcount = InterlockedDecrement(&state->refcount);
unsigned int refcount = InterlockedDecrement((LONG *)&state->refcount);
TRACE("%p decreasing refcount to %u.\n", state, refcount);

View File

@ -1288,7 +1288,7 @@ struct d3d12_pipeline_uav_counter_state
struct d3d12_pipeline_state
{
ID3D12PipelineState ID3D12PipelineState_iface;
LONG refcount;
unsigned int refcount;
union
{