Implement CSET and CSETP shader instructions (#4318)

* Implement CSET and CSETP shader instructions

* Shader cache version bump

* Fix CC.HI
This commit is contained in:
gdkchan 2023-01-21 12:18:05 -03:00 committed by GitHub
parent 2747f12591
commit 6adf15e479
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 90 additions and 42 deletions

View file

@ -11,23 +11,6 @@ namespace Ryujinx.Graphics.Shader.Instructions
{
static partial class InstEmit
{
public static void Csetp(EmitterContext context)
{
InstCsetp op = context.GetOp<InstCsetp>();
// TODO: Implement that properly.
Operand p0Res = Const(IrConsts.True);
Operand p1Res = context.BitwiseNot(p0Res);
Operand srcPred = GetPredicate(context, op.SrcPred, op.SrcPredInv);
p0Res = GetPredLogicalOp(context, op.Bop, p0Res, srcPred);
p1Res = GetPredLogicalOp(context, op.Bop, p1Res, srcPred);
context.Copy(Register(op.DestPred, RegisterType.Predicate), p0Res);
context.Copy(Register(op.DestPredInv, RegisterType.Predicate), p1Res);
}
public static void IcmpR(EmitterContext context)
{
InstIcmpR op = context.GetOp<InstIcmpR>();