From c37870ae664caa15790612860c6227e6a64436f6 Mon Sep 17 00:00:00 2001 From: bebbo Date: Thu, 25 Nov 2021 18:35:48 +0100 Subject: [PATCH] implement fmod --- musashi/m68kfpu.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/musashi/m68kfpu.c b/musashi/m68kfpu.c index e656f3ba..ae744b29 100644 --- a/musashi/m68kfpu.c +++ b/musashi/m68kfpu.c @@ -1465,6 +1465,13 @@ static void fpgen_rm_reg(uint16 w2) USE_CYCLES(43); break; } + case 0x21: // FMOD + { + REG_FP[dst] = floatx80_rem(REG_FP[dst], source); + SET_CONDITION_CODES(REG_FP[dst]); + USE_CYCLES(43); + break; + } case 0x24: // FSGLDIV { REG_FP[dst] = double_to_fx80((float)fx80_to_double(floatx80_div(REG_FP[dst], source)));