Previous 15994 Revisions Next

r7018 Tuesday 12th January, 2010 at 14:09:55 UTC by Dirk Best
i386: Fixed emulation of the DIV flag bug, we are now correctly detected as Intel 486DX instead of some Cyrix or TI CPU.
[src/emu/cpu/i386]i386op16.c i386op32.c i386ops.c

src/emu/cpu/i386/i386op16.c
r7017r7018
26392639               } else {
26402640                  REG16(DX) = (UINT16)remainder;
26412641                  REG16(AX) = (UINT16)result;
2642
2643                  // this flag is actually undefined
2644                  cpustate->CF = 1;
26422645               }
26432646            } else {
26442647               /* TODO: Divide by zero */
r7017r7018
26672670               } else {
26682671                  REG16(DX) = (UINT16)remainder;
26692672                  REG16(AX) = (UINT16)result;
2673
2674                  // this flag is actually undefined
2675                  cpustate->CF = 1;
26702676               }
26712677            } else {
26722678               /* TODO: Divide by zero */
src/emu/cpu/i386/i386ops.c
r7017r7018
20232023               } else {
20242024                  REG8(AH) = (UINT8)remainder & 0xff;
20252025                  REG8(AL) = (UINT8)result & 0xff;
2026
2027                  // this flag is actually undefined
2028                  cpustate->CF = 1;
20262029               }
20272030            } else {
20282031               /* TODO: Divide by zero */
r7017r7018
20512054               } else {
20522055                  REG8(AH) = (UINT8)remainder & 0xff;
20532056                  REG8(AL) = (UINT8)result & 0xff;
2057
2058                  // this flag is actually undefined
2059                  cpustate->CF = 1;
20542060               }
20552061            } else {
20562062               /* TODO: Divide by zero */
src/emu/cpu/i386/i386op32.c
r7017r7018
24872487               } else {
24882488                  REG32(EDX) = (UINT32)remainder;
24892489                  REG32(EAX) = (UINT32)result;
2490
2491                  // this flag is actually undefined
2492                  cpustate->CF = 1;
24932490               }
24942491            } else {
24952492               /* TODO: Divide by zero */
r7017r7018
25182515               } else {
25192516                  REG32(EDX) = (UINT32)remainder;
25202517                  REG32(EAX) = (UINT32)result;
2521
2522                  // this flag is actually undefined
2523                  cpustate->CF = 1;
25242518               }
25252519            } else {
25262520               /* TODO: Divide by zero */

Previous 15994 Revisions Next


© 1998-2018 The MESS Team