From d0d50c48244b9d588680018a480dd81971f46205 Mon Sep 17 00:00:00 2001 From: MerryMage Date: Sun, 17 May 2020 22:40:20 +0100 Subject: [PATCH] print_info: Use VFP and ASIMD decoders to get dynarmic name for instruction --- tests/print_info.cpp | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/tests/print_info.cpp b/tests/print_info.cpp index 3e87d3db..b1cd59b2 100644 --- a/tests/print_info.cpp +++ b/tests/print_info.cpp @@ -18,6 +18,8 @@ #include "common/common_types.h" #include "common/llvm_disassemble.h" #include "frontend/A32/decoder/arm.h" +#include "frontend/A32/decoder/asimd.h" +#include "frontend/A32/decoder/vfp.h" #include "frontend/A32/location_descriptor.h" #include "frontend/A32/translate/impl/translate_arm.h" #include "frontend/A32/translate/translate.h" @@ -34,7 +36,11 @@ using namespace Dynarmic; const char* GetNameOfA32Instruction(u32 instruction) { - if (auto decoder = A32::DecodeArm(instruction)) { + if (auto vfp_decoder = A32::DecodeVFP(instruction)) { + return vfp_decoder->get().GetName(); + } else if (auto asimd_decoder = A32::DecodeASIMD(instruction)) { + return asimd_decoder->get().GetName(); + } else if (auto decoder = A32::DecodeArm(instruction)) { return decoder->get().GetName(); } return "";