mirror of
https://github.com/EduApps-CDG/OpenDX
synced 2024-12-30 09:45:37 +01:00
[d3d11] Rename some hazard tracking methods for clarity
This commit is contained in:
parent
6be124e2cd
commit
30d19cd0f2
@ -2521,7 +2521,7 @@ namespace dxvk {
|
|||||||
uavSlotId + StartSlot + i, uav,
|
uavSlotId + StartSlot + i, uav,
|
||||||
ctrSlotId + StartSlot + i, ctr);
|
ctrSlotId + StartSlot + i, ctr);
|
||||||
|
|
||||||
TestCsSrvHazards(uav);
|
ResolveCsSrvHazards(uav);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -2645,10 +2645,10 @@ namespace dxvk {
|
|||||||
if (m_state.om.renderTargetViews[i] != rtv) {
|
if (m_state.om.renderTargetViews[i] != rtv) {
|
||||||
m_state.om.renderTargetViews[i] = rtv;
|
m_state.om.renderTargetViews[i] = rtv;
|
||||||
needsUpdate = true;
|
needsUpdate = true;
|
||||||
TestOmSrvHazards(rtv);
|
ResolveOmSrvHazards(rtv);
|
||||||
|
|
||||||
if (NumUAVs == D3D11_KEEP_UNORDERED_ACCESS_VIEWS)
|
if (NumUAVs == D3D11_KEEP_UNORDERED_ACCESS_VIEWS)
|
||||||
TestOmUavHazards(rtv);
|
ResolveOmUavHazards(rtv);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2657,7 +2657,7 @@ namespace dxvk {
|
|||||||
if (m_state.om.depthStencilView != dsv) {
|
if (m_state.om.depthStencilView != dsv) {
|
||||||
m_state.om.depthStencilView = dsv;
|
m_state.om.depthStencilView = dsv;
|
||||||
needsUpdate = true;
|
needsUpdate = true;
|
||||||
TestOmSrvHazards(dsv);
|
ResolveOmSrvHazards(dsv);
|
||||||
}
|
}
|
||||||
|
|
||||||
m_state.om.maxRtv = NumRTVs;
|
m_state.om.maxRtv = NumRTVs;
|
||||||
@ -2687,10 +2687,10 @@ namespace dxvk {
|
|||||||
uavSlotId + i, uav,
|
uavSlotId + i, uav,
|
||||||
ctrSlotId + i, ctr);
|
ctrSlotId + i, ctr);
|
||||||
|
|
||||||
TestOmSrvHazards(uav);
|
ResolveOmSrvHazards(uav);
|
||||||
|
|
||||||
if (NumRTVs == D3D11_KEEP_RENDER_TARGETS_AND_DEPTH_STENCIL)
|
if (NumRTVs == D3D11_KEEP_RENDER_TARGETS_AND_DEPTH_STENCIL)
|
||||||
needsUpdate |= TestOmRtvHazards(uav);
|
needsUpdate |= ResolveOmRtvHazards(uav);
|
||||||
|
|
||||||
needsSpill = true;
|
needsSpill = true;
|
||||||
}
|
}
|
||||||
@ -3844,7 +3844,7 @@ namespace dxvk {
|
|||||||
|
|
||||||
|
|
||||||
template<DxbcProgramType ShaderStage, typename T>
|
template<DxbcProgramType ShaderStage, typename T>
|
||||||
void D3D11DeviceContext::TestSrvHazards(
|
void D3D11DeviceContext::ResolveSrvHazards(
|
||||||
T* pView,
|
T* pView,
|
||||||
D3D11ShaderResourceBindings& Bindings) {
|
D3D11ShaderResourceBindings& Bindings) {
|
||||||
uint32_t slotId = computeSrvBinding(ShaderStage, 0);
|
uint32_t slotId = computeSrvBinding(ShaderStage, 0);
|
||||||
@ -3873,18 +3873,26 @@ namespace dxvk {
|
|||||||
|
|
||||||
|
|
||||||
template<typename T>
|
template<typename T>
|
||||||
void D3D11DeviceContext::TestOmSrvHazards(
|
void D3D11DeviceContext::ResolveCsSrvHazards(
|
||||||
T* pView) {
|
T* pView) {
|
||||||
if (!pView) return;
|
if (!pView) return;
|
||||||
TestSrvHazards<DxbcProgramType::VertexShader> (pView, m_state.vs.shaderResources);
|
ResolveSrvHazards<DxbcProgramType::ComputeShader> (pView, m_state.cs.shaderResources);
|
||||||
TestSrvHazards<DxbcProgramType::HullShader> (pView, m_state.hs.shaderResources);
|
}
|
||||||
TestSrvHazards<DxbcProgramType::DomainShader> (pView, m_state.ds.shaderResources);
|
|
||||||
TestSrvHazards<DxbcProgramType::GeometryShader> (pView, m_state.gs.shaderResources);
|
|
||||||
TestSrvHazards<DxbcProgramType::PixelShader> (pView, m_state.ps.shaderResources);
|
template<typename T>
|
||||||
|
void D3D11DeviceContext::ResolveOmSrvHazards(
|
||||||
|
T* pView) {
|
||||||
|
if (!pView) return;
|
||||||
|
ResolveSrvHazards<DxbcProgramType::VertexShader> (pView, m_state.vs.shaderResources);
|
||||||
|
ResolveSrvHazards<DxbcProgramType::HullShader> (pView, m_state.hs.shaderResources);
|
||||||
|
ResolveSrvHazards<DxbcProgramType::DomainShader> (pView, m_state.ds.shaderResources);
|
||||||
|
ResolveSrvHazards<DxbcProgramType::GeometryShader> (pView, m_state.gs.shaderResources);
|
||||||
|
ResolveSrvHazards<DxbcProgramType::PixelShader> (pView, m_state.ps.shaderResources);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
bool D3D11DeviceContext::TestOmRtvHazards(
|
bool D3D11DeviceContext::ResolveOmRtvHazards(
|
||||||
D3D11UnorderedAccessView* pView) {
|
D3D11UnorderedAccessView* pView) {
|
||||||
if (!pView || !pView->HasBindFlag(D3D11_BIND_RENDER_TARGET))
|
if (!pView || !pView->HasBindFlag(D3D11_BIND_RENDER_TARGET))
|
||||||
return false;
|
return false;
|
||||||
@ -3907,7 +3915,7 @@ namespace dxvk {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void D3D11DeviceContext::TestOmUavHazards(
|
void D3D11DeviceContext::ResolveOmUavHazards(
|
||||||
D3D11RenderTargetView* pView) {
|
D3D11RenderTargetView* pView) {
|
||||||
if (!pView || !pView->HasBindFlag(D3D11_BIND_UNORDERED_ACCESS))
|
if (!pView || !pView->HasBindFlag(D3D11_BIND_UNORDERED_ACCESS))
|
||||||
return;
|
return;
|
||||||
@ -3927,14 +3935,6 @@ namespace dxvk {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
template<typename T>
|
|
||||||
void D3D11DeviceContext::TestCsSrvHazards(
|
|
||||||
T* pView) {
|
|
||||||
if (!pView) return;
|
|
||||||
TestSrvHazards<DxbcProgramType::ComputeShader> (pView, m_state.cs.shaderResources);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
bool D3D11DeviceContext::ValidateRenderTargets(
|
bool D3D11DeviceContext::ValidateRenderTargets(
|
||||||
UINT NumViews,
|
UINT NumViews,
|
||||||
ID3D11RenderTargetView* const* ppRenderTargetViews,
|
ID3D11RenderTargetView* const* ppRenderTargetViews,
|
||||||
|
@ -811,24 +811,24 @@ namespace dxvk {
|
|||||||
D3D11ShaderResourceView* pView);
|
D3D11ShaderResourceView* pView);
|
||||||
|
|
||||||
template<DxbcProgramType ShaderStage, typename T>
|
template<DxbcProgramType ShaderStage, typename T>
|
||||||
void TestSrvHazards(
|
void ResolveSrvHazards(
|
||||||
T* pView,
|
T* pView,
|
||||||
D3D11ShaderResourceBindings& Bindings);
|
D3D11ShaderResourceBindings& Bindings);
|
||||||
|
|
||||||
template<typename T>
|
template<typename T>
|
||||||
void TestOmSrvHazards(
|
void ResolveCsSrvHazards(
|
||||||
T* pView);
|
|
||||||
|
|
||||||
bool TestOmRtvHazards(
|
|
||||||
D3D11UnorderedAccessView* pView);
|
|
||||||
|
|
||||||
void TestOmUavHazards(
|
|
||||||
D3D11RenderTargetView* pView);
|
|
||||||
|
|
||||||
template<typename T>
|
|
||||||
void TestCsSrvHazards(
|
|
||||||
T* pView);
|
T* pView);
|
||||||
|
|
||||||
|
template<typename T>
|
||||||
|
void ResolveOmSrvHazards(
|
||||||
|
T* pView);
|
||||||
|
|
||||||
|
bool ResolveOmRtvHazards(
|
||||||
|
D3D11UnorderedAccessView* pView);
|
||||||
|
|
||||||
|
void ResolveOmUavHazards(
|
||||||
|
D3D11RenderTargetView* pView);
|
||||||
|
|
||||||
bool ValidateRenderTargets(
|
bool ValidateRenderTargets(
|
||||||
UINT NumViews,
|
UINT NumViews,
|
||||||
ID3D11RenderTargetView* const* ppRenderTargetViews,
|
ID3D11RenderTargetView* const* ppRenderTargetViews,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user