--- uae/src/gencpu.c 2018/04/24 16:39:48 1.1.1.3 +++ uae/src/gencpu.c 2018/04/24 16:40:46 1.1.1.4 @@ -1170,7 +1170,7 @@ static void gen_opcode(unsigned long int * weird things... */ case i_MVPRM: genamode (table68k[opcode].smode, "srcreg", table68k[opcode].size, "src", 1, 0); - printf ("\tuaecptr memp = m68k_areg(regs, dstreg) + %s;\n", gen_nextiword()); + printf ("\tuaecptr memp = m68k_areg(regs, dstreg) + (uae_s32)(uae_s16)%s;\n", gen_nextiword()); if (table68k[opcode].size == sz_word) { printf ("\tput_byte(memp, src >> 8); put_byte(memp + 2, src);\n"); } else { @@ -1179,7 +1179,7 @@ static void gen_opcode(unsigned long int } break; case i_MVPMR: - printf ("\tuaecptr memp = m68k_areg(regs, srcreg) + %s;\n", gen_nextiword()); + printf ("\tuaecptr memp = m68k_areg(regs, srcreg) + (uae_s32)(uae_s16)%s;\n", gen_nextiword()); genamode (table68k[opcode].dmode, "dstreg", table68k[opcode].size, "dst", 2, 0); if (table68k[opcode].size == sz_word) { printf ("\tuae_u16 val = (get_byte(memp) << 8) + get_byte(memp + 2);\n");