From 4b108460089056475504e7cd007155c774bc1128 Mon Sep 17 00:00:00 2001 From: Robin Kertels Date: Fri, 26 May 2023 00:41:07 +0200 Subject: [PATCH] [dxso] Fix RT mask for SM1 --- src/dxso/dxso_module.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/dxso/dxso_module.cpp b/src/dxso/dxso_module.cpp index 4cc6eb3e7..d3ed812f2 100644 --- a/src/dxso/dxso_module.cpp +++ b/src/dxso/dxso_module.cpp @@ -38,10 +38,14 @@ namespace dxvk { m_constants = compiler->constants(); m_maxDefinedConst = compiler->maxDefinedConstant(); m_usedSamplers = compiler->usedSamplers(); - m_usedRTs = compiler->usedRTs(); compiler->finalize(); + // SM 1 doesn't have explicit output registers and uses R0 instead. + // The shader compiler emits the C0 write in finalize, so we have to get the rt mask + // after that. + m_usedRTs = compiler->usedRTs(); + return compiler->compile(); }