From 3d294a9a6ccf5c620e328bfd87a8cf354b6af227 Mon Sep 17 00:00:00 2001 From: gdkchan Date: Tue, 1 Sep 2020 15:07:20 -0300 Subject: [PATCH] Fix PSL and MRG flags on XMAD cbuf-reg shader instruction (#1520) --- Ryujinx.Graphics.Shader/Instructions/InstEmitAlu.cs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/Ryujinx.Graphics.Shader/Instructions/InstEmitAlu.cs b/Ryujinx.Graphics.Shader/Instructions/InstEmitAlu.cs index e55f1f322..b883edc13 100644 --- a/Ryujinx.Graphics.Shader/Instructions/InstEmitAlu.cs +++ b/Ryujinx.Graphics.Shader/Instructions/InstEmitAlu.cs @@ -674,7 +674,12 @@ namespace Ryujinx.Graphics.Shader.Instructions bool productShiftLeft = false; bool merge = false; - if (!(op is OpCodeAluRegCbuf)) + if (op is OpCodeAluCbuf) + { + productShiftLeft = context.CurrOp.RawOpCode.Extract(55); + merge = context.CurrOp.RawOpCode.Extract(56); + } + else if (!(op is OpCodeAluRegCbuf)) { productShiftLeft = context.CurrOp.RawOpCode.Extract(36); merge = context.CurrOp.RawOpCode.Extract(37);