[d3d9] Request high-priority shader compiles as necessary

This commit is contained in:
Philip Rebohle 2022-08-11 02:44:05 +02:00
parent d3ab905621
commit 9bd0040a90
No known key found for this signature in database
GPG Key ID: C8CC613427A31C99
1 changed files with 6 additions and 1 deletions

View File

@ -6215,8 +6215,13 @@ namespace dxvk {
template <DxsoProgramType ShaderStage>
void D3D9DeviceEx::BindShader(
const D3D9CommonShader* pShaderModule) {
auto shader = pShaderModule->GetShader();
if (unlikely(shader->needsLibraryCompile()))
m_dxvkDevice->requestCompileShader(shader);
EmitCs([
cShader = pShaderModule->GetShader()
cShader = std::move(shader)
] (DxvkContext* ctx) mutable {
constexpr VkShaderStageFlagBits stage = GetShaderStage(ShaderStage);
ctx->bindShader<stage>(std::move(cShader));