aboutsummaryrefslogtreecommitdiff
path: root/Ryujinx.Graphics.Shader/Instructions/InstEmitAluHelper.cs
diff options
context:
space:
mode:
authorgdkchan <gab.dark.100@gmail.com>2019-12-16 02:42:01 -0300
committerThog <thog@protonmail.com>2020-01-09 02:13:00 +0100
commit82957fa96b1657d72290d721da370bf133dc7a8d (patch)
treeabfcfbc434e93c2947ead11727d77baa457e6c57 /Ryujinx.Graphics.Shader/Instructions/InstEmitAluHelper.cs
parent9d7a142a48a5f804127fcae2265bb6ec5495d178 (diff)
Support CC on FSET shader instruction, fix CC on ISET.BF shader instruction
Diffstat (limited to 'Ryujinx.Graphics.Shader/Instructions/InstEmitAluHelper.cs')
-rw-r--r--Ryujinx.Graphics.Shader/Instructions/InstEmitAluHelper.cs9
1 files changed, 9 insertions, 0 deletions
diff --git a/Ryujinx.Graphics.Shader/Instructions/InstEmitAluHelper.cs b/Ryujinx.Graphics.Shader/Instructions/InstEmitAluHelper.cs
index e283c3b7..da5c7fed 100644
--- a/Ryujinx.Graphics.Shader/Instructions/InstEmitAluHelper.cs
+++ b/Ryujinx.Graphics.Shader/Instructions/InstEmitAluHelper.cs
@@ -84,5 +84,14 @@ namespace Ryujinx.Graphics.Shader.Instructions
context.Copy(GetNF(context), context.ICompareLess(dest, Const(0)));
}
+
+ public static void SetFPZnFlags(EmitterContext context, Operand dest, bool setCC)
+ {
+ if (setCC)
+ {
+ context.Copy(GetZF(context), context.FPCompareEqual(dest, ConstF(0)));
+ context.Copy(GetNF(context), context.FPCompareLess (dest, ConstF(0)));
+ }
+ }
}
} \ No newline at end of file