/* INCLUDES *******************************************************************/
#include "ntvdm.h"
-
-#ifndef NEW_EMULATOR
-#include <softx86.h>
-#include <softx87.h>
-#else
#include <fast486.h>
-#endif
/* DEFINES ********************************************************************/
#define EMULATOR_FLAG_ID (1 << 21)
/* Common definitions */
-#define EMULATOR_BOP 0xC4C4
-#define EMULATOR_INT_BOP 0xBEEF
-#define STACK_INT_NUM 0
-#define STACK_IP 1
-#define STACK_CS 2
-#define STACK_FLAGS 3
+#define EMULATOR_BOP 0xC4C4
+#define EMULATOR_INT_BOP 0xFF
+
+#define STACK_COUNTER 0
+#define STACK_INT_NUM 1
+#define STACK_IP 2
+#define STACK_CS 3
+#define STACK_FLAGS 4
enum
{
EMULATOR_REG_GS
};
-#ifndef NEW_EMULATOR
-
-#define NTVDMCALL __cdecl
-extern softx86_ctx EmulatorContext;
-extern softx87_ctx FpuEmulatorContext;
-
-#else
-
-#define NTVDMCALL __stdcall
extern FAST486_STATE EmulatorContext;
-#endif
-
/* FUNCTIONS ******************************************************************/
BOOLEAN EmulatorInitialize();
VOID EmulatorSetStack(WORD Segment, DWORD Offset);
VOID EmulatorExecute(WORD Segment, WORD Offset);
VOID EmulatorInterrupt(BYTE Number);
-VOID EmulatorExternalInterrupt(BYTE Number);
+VOID EmulatorInterruptSignal(VOID);
ULONG EmulatorGetRegister(ULONG Register);
ULONG EmulatorGetProgramCounter(VOID);
VOID EmulatorSetRegister(ULONG Register, ULONG Value);