1
0
mirror of https://github.com/doitsujin/dxvk.git synced 2025-03-13 19:29:14 +01:00

[dxbc] Scan for discard and derivative instructions

This commit is contained in:
Philip Rebohle 2018-05-26 17:08:08 +02:00
parent 667616bc39
commit ec5572aa69
No known key found for this signature in database
GPG Key ID: C8CC613427A31C99
2 changed files with 14 additions and 1 deletions

View File

@ -34,7 +34,17 @@ namespace dxvk {
m_analysis->uavInfos[registerId].accessAtomicOp = true;
}
} break;
case DxbcInstClass::TextureSample:
case DxbcInstClass::VectorDeriv: {
m_analysis->usesDerivatives = true;
} break;
case DxbcInstClass::ControlFlow: {
if (ins.op == DxbcOpcode::Discard)
m_analysis->usesKill = true;
} break;
case DxbcInstClass::TypedUavLoad: {
const uint32_t registerId = ins.src[1].idx[0].offset;
m_analysis->uavInfos[registerId].accessTypedLoad = true;

View File

@ -37,6 +37,9 @@ namespace dxvk {
DxbcClipCullInfo clipCullIn;
DxbcClipCullInfo clipCullOut;
bool usesDerivatives = false;
bool usesKill = false;
};
/**