mirror of
https://gitlab.winehq.org/wine/vkd3d.git
synced 2025-04-13 05:43:18 -07:00
vkd3d: Avoid holding mutex while waiting for fences.
We maintain separate arrays for enqueued fences and fences owned by the fence worker thread. Signed-off-by: Józef Kucia <jkucia@codeweavers.com> Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
committed by
Alexandre Julliard
parent
18442763f1
commit
0baf0302d1
@@ -118,7 +118,7 @@ static inline LONG InterlockedIncrement(LONG volatile *x)
|
||||
return __sync_add_and_fetch(x, 1);
|
||||
}
|
||||
# else
|
||||
# error "InterlockedIncrement not implemented for this platform"
|
||||
# error "InterlockedIncrement() not implemented for this platform"
|
||||
# endif /* HAVE_SYNC_ADD_AND_FETCH */
|
||||
|
||||
# if HAVE_SYNC_SUB_AND_FETCH
|
||||
@@ -127,8 +127,14 @@ static inline LONG InterlockedDecrement(LONG volatile *x)
|
||||
return __sync_sub_and_fetch(x, 1);
|
||||
}
|
||||
# else
|
||||
# error "InterlockedDecrement not implemented for this platform"
|
||||
# error "InterlockedDecrement() not implemented for this platform"
|
||||
# endif
|
||||
#endif /* _WIN32 */
|
||||
|
||||
#if HAVE_SYNC_ADD_AND_FETCH
|
||||
# define atomic_add_fetch(ptr, val) __sync_add_and_fetch(ptr, val)
|
||||
#else
|
||||
# error "atomic_add_fetch() not implemented for this platform"
|
||||
#endif /* HAVE_SYNC_ADD_AND_FETCH */
|
||||
|
||||
#endif /* __VKD3D_COMMON_H */
|
||||
|
Reference in New Issue
Block a user