mirror of
https://github.com/doitsujin/dxvk.git
synced 2025-01-19 05:52:11 +01:00
[d3d11] Submit stalling event queries before flushing
Otherwise, instead of preventing syncs, this would actually have the opposite effect.
This commit is contained in:
parent
3457e312b0
commit
a6483e02fe
@ -104,12 +104,12 @@ namespace dxvk {
|
||||
if (unlikely(!pAsync))
|
||||
return;
|
||||
|
||||
Com<D3D11Query, false> query(static_cast<D3D11Query*>(pAsync));
|
||||
auto query = static_cast<D3D11Query*>(pAsync);
|
||||
|
||||
if (unlikely(!query->DoBegin()))
|
||||
return;
|
||||
|
||||
EmitCs([cQuery = std::move(query)]
|
||||
EmitCs([cQuery = Com<D3D11Query, false>(query)]
|
||||
(DxvkContext* ctx) {
|
||||
cQuery->Begin(ctx);
|
||||
});
|
||||
@ -122,22 +122,22 @@ namespace dxvk {
|
||||
if (unlikely(!pAsync))
|
||||
return;
|
||||
|
||||
Com<D3D11Query, false> query(static_cast<D3D11Query*>(pAsync));
|
||||
auto query = static_cast<D3D11Query*>(pAsync);
|
||||
|
||||
if (unlikely(!query->DoEnd()))
|
||||
return;
|
||||
|
||||
EmitCs([cQuery = Com<D3D11Query, false>(query)]
|
||||
(DxvkContext* ctx) {
|
||||
cQuery->End(ctx);
|
||||
});
|
||||
|
||||
if (unlikely(query->IsEvent())) {
|
||||
query->NotifyEnd();
|
||||
query->IsStalling()
|
||||
? Flush()
|
||||
: FlushImplicit(TRUE);
|
||||
}
|
||||
|
||||
EmitCs([cQuery = std::move(query)]
|
||||
(DxvkContext* ctx) {
|
||||
cQuery->End(ctx);
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user