mirror of
https://github.com/doitsujin/dxvk.git
synced 2024-12-11 19:24:11 +01:00
[d3d11] Add option to disable write-after-write barriers
This commit is contained in:
parent
023cf01c3c
commit
e56710e64f
@ -13,8 +13,14 @@ namespace dxvk {
|
|||||||
const Rc<DxvkDevice>& Device)
|
const Rc<DxvkDevice>& Device)
|
||||||
: D3D11DeviceContext(pParent, Device, DxvkCsChunkFlag::SingleUse),
|
: D3D11DeviceContext(pParent, Device, DxvkCsChunkFlag::SingleUse),
|
||||||
m_csThread(Device->createContext()) {
|
m_csThread(Device->createContext()) {
|
||||||
EmitCs([cDevice = m_device] (DxvkContext* ctx) {
|
EmitCs([
|
||||||
|
cDevice = m_device,
|
||||||
|
cRelaxedBarriers = pParent->GetOptions()->relaxedBarriers
|
||||||
|
] (DxvkContext* ctx) {
|
||||||
ctx->beginRecording(cDevice->createCommandList());
|
ctx->beginRecording(cDevice->createCommandList());
|
||||||
|
|
||||||
|
if (cRelaxedBarriers)
|
||||||
|
ctx->setBarrierControl(DxvkBarrierControl::IgnoreWriteAfterWrite);
|
||||||
});
|
});
|
||||||
|
|
||||||
ClearState();
|
ClearState();
|
||||||
|
@ -9,6 +9,7 @@ namespace dxvk {
|
|||||||
this->dcSingleUseMode = config.getOption<bool>("d3d11.dcSingleUseMode", true);
|
this->dcSingleUseMode = config.getOption<bool>("d3d11.dcSingleUseMode", true);
|
||||||
this->strictDivision = config.getOption<bool>("d3d11.strictDivision", false);
|
this->strictDivision = config.getOption<bool>("d3d11.strictDivision", false);
|
||||||
this->zeroInitWorkgroupMemory = config.getOption<bool>("d3d11.zeroInitWorkgroupMemory", false);
|
this->zeroInitWorkgroupMemory = config.getOption<bool>("d3d11.zeroInitWorkgroupMemory", false);
|
||||||
|
this->relaxedBarriers = config.getOption<bool>("d3d11.relaxedBarriers", false);
|
||||||
this->maxTessFactor = config.getOption<int32_t>("d3d11.maxTessFactor", 0);
|
this->maxTessFactor = config.getOption<int32_t>("d3d11.maxTessFactor", 0);
|
||||||
this->samplerAnisotropy = config.getOption<int32_t>("d3d11.samplerAnisotropy", -1);
|
this->samplerAnisotropy = config.getOption<int32_t>("d3d11.samplerAnisotropy", -1);
|
||||||
this->deferSurfaceCreation = config.getOption<bool>("dxgi.deferSurfaceCreation", false);
|
this->deferSurfaceCreation = config.getOption<bool>("dxgi.deferSurfaceCreation", false);
|
||||||
|
@ -36,6 +36,12 @@ namespace dxvk {
|
|||||||
/// TGSM in compute shaders before reading it.
|
/// TGSM in compute shaders before reading it.
|
||||||
bool zeroInitWorkgroupMemory;
|
bool zeroInitWorkgroupMemory;
|
||||||
|
|
||||||
|
/// Use relaxed memory barriers
|
||||||
|
///
|
||||||
|
/// May improve performance in some games,
|
||||||
|
/// but might also cause rendering issues.
|
||||||
|
bool relaxedBarriers;
|
||||||
|
|
||||||
/// Maximum tessellation factor.
|
/// Maximum tessellation factor.
|
||||||
///
|
///
|
||||||
/// Limits tessellation factors in tessellation
|
/// Limits tessellation factors in tessellation
|
||||||
|
Loading…
Reference in New Issue
Block a user