From b6bb94872adbe69463a05f04e823865658a0db1c Mon Sep 17 00:00:00 2001 From: Merry Date: Sat, 23 Jul 2022 00:02:45 +0100 Subject: [PATCH] backend/arm64: Implement IsZero64 --- .../backend/arm64/emit_arm64_data_processing.cpp | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/src/dynarmic/backend/arm64/emit_arm64_data_processing.cpp b/src/dynarmic/backend/arm64/emit_arm64_data_processing.cpp index a81b7336..8c40c046 100644 --- a/src/dynarmic/backend/arm64/emit_arm64_data_processing.cpp +++ b/src/dynarmic/backend/arm64/emit_arm64_data_processing.cpp @@ -142,10 +142,15 @@ void EmitIR(oaknut::CodeGenerator& code, EmitContext& ctx, template<> void EmitIR(oaknut::CodeGenerator& code, EmitContext& ctx, IR::Inst* inst) { - (void)code; - (void)ctx; - (void)inst; - ASSERT_FALSE("Unimplemented"); + // TODO: Use host flags + auto args = ctx.reg_alloc.GetArgumentInfo(inst); + + auto Wresult = ctx.reg_alloc.WriteW(inst); + auto Xoperand = ctx.reg_alloc.ReadX(args[0]); + RegAlloc::Realize(Wresult, Xoperand); + + code.CMP(Xoperand, 0); + code.CSET(Wresult, EQ); } template<>