[dxbc] Enable SPV_NV_raw_access_chains

This commit is contained in:
Philip Rebohle 2024-02-16 19:47:35 +01:00
parent c677ba9b3e
commit 94098aa97d
4 changed files with 13 additions and 0 deletions

View File

@ -1230,6 +1230,14 @@ namespace dxvk {
}
m_bindings.push_back(binding);
// If supported, we'll be using raw access chains to access this
if (!m_hasRawAccessChains && m_moduleInfo.options.supportsRawAccessChains) {
m_module.enableExtension("SPV_NV_raw_access_chains");
m_module.enableCapability(spv::CapabilityRawAccessChainsNV);
m_hasRawAccessChains = true;
}
}

View File

@ -512,6 +512,7 @@ namespace dxvk {
// Entry point description - we'll need to declare
// the function ID and all input/output variables.
uint32_t m_entryPointId = 0;
bool m_hasRawAccessChains = false;
////////////////////////////////////////////
// Inter-stage shader interface slots. Also

View File

@ -27,6 +27,7 @@ namespace dxvk {
& device->getFormatFeatures(VK_FORMAT_R32_SINT).optimal;
supportsTypedUavLoadR32 = (r32Features & VK_FORMAT_FEATURE_2_STORAGE_READ_WITHOUT_FORMAT_BIT);
supportsRawAccessChains = device->features().nvRawAccessChains.shaderRawAccessChains;
switch (device->config().useRawSsbo) {
case Tristate::Auto: minSsboAlignment = devInfo.core.properties.limits.minStorageBufferOffsetAlignment; break;

View File

@ -27,6 +27,9 @@ namespace dxvk {
/// on typed UAV loads are required
bool supportsTypedUavLoadR32 = false;
/// Determines whether raw access chains are supported
bool supportsRawAccessChains = false;
/// Use subgroup operations to reduce the number of
/// atomic operations for append/consume buffers.
bool useSubgroupOpsForAtomicCounters = false;