From 18eb75772c01718d27cbc31bf1e0330609fbaec8 Mon Sep 17 00:00:00 2001 From: LDj3SNuD <35856442+LDj3SNuD@users.noreply.github.com> Date: Mon, 1 Jul 2019 21:23:04 +0200 Subject: [PATCH] Update for Saddlv_V Inst. --- .../Instructions/InstEmitSimdHelper.cs | 22 +++++++++++++++---- 1 file changed, 18 insertions(+), 4 deletions(-) diff --git a/ChocolArm64/Instructions/InstEmitSimdHelper.cs b/ChocolArm64/Instructions/InstEmitSimdHelper.cs index f343dba8d0..ea121c0465 100644 --- a/ChocolArm64/Instructions/InstEmitSimdHelper.cs +++ b/ChocolArm64/Instructions/InstEmitSimdHelper.cs @@ -823,15 +823,29 @@ namespace ChocolArm64.Instructions public static void EmitVectorAcrossVectorOpSx(ILEmitterCtx context, Action emit) { - EmitVectorAcrossVectorOp(context, emit, true); + EmitVectorAcrossVectorOp(context, emit, signed: true, isLong: false); } public static void EmitVectorAcrossVectorOpZx(ILEmitterCtx context, Action emit) { - EmitVectorAcrossVectorOp(context, emit, false); + EmitVectorAcrossVectorOp(context, emit, signed: false, isLong: false); } - public static void EmitVectorAcrossVectorOp(ILEmitterCtx context, Action emit, bool signed) + public static void EmitVectorLongAcrossVectorOpSx(ILEmitterCtx context, Action emit) + { + EmitVectorAcrossVectorOp(context, emit, signed: true, isLong: true); + } + + public static void EmitVectorLongAcrossVectorOpZx(ILEmitterCtx context, Action emit) + { + EmitVectorAcrossVectorOp(context, emit, signed: false, isLong: true); + } + + public static void EmitVectorAcrossVectorOp( + ILEmitterCtx context, + Action emit, + bool signed, + bool isLong) { OpCodeSimd64 op = (OpCodeSimd64)context.CurrOp; @@ -847,7 +861,7 @@ namespace ChocolArm64.Instructions emit(); } - EmitScalarSet(context, op.Rd, op.Size); + EmitScalarSet(context, op.Rd, isLong ? op.Size + 1 : op.Size); } public static void EmitVectorPairwiseOpF(ILEmitterCtx context, Action emit)