The emulator can now be compiled without the recompiler by using the DYNAREC=n parameter with make;

The BIOS address is now selectable for the BusLogic ISA SCSI controllers.
This commit is contained in:
OBattler
2017-10-15 02:43:13 +02:00
parent c1abfe2362
commit 1cfa8e2c4d
18 changed files with 267 additions and 54 deletions

View File

@@ -278,12 +278,14 @@ BEGIN
12,12
LTEXT "MB",IDT_1705,123,64,10,10
LTEXT "Memory:",IDT_1706,7,64,30,10
CONTROL "Dynamic Recompiler",IDC_CHECK_DYNAREC,"Button",
BS_AUTOCHECKBOX | WS_TABSTOP,7,100,94,10
CONTROL "Enable time sync",IDC_CHECK_SYNC,"Button",
BS_AUTOCHECKBOX | WS_TABSTOP,7,100,102,10
CONTROL "Enable FPU",IDC_CHECK_FPU,"Button",BS_AUTOCHECKBOX |
WS_TABSTOP,147,100,113,10
CONTROL "Enable time sync",IDC_CHECK_SYNC,"Button",
BS_AUTOCHECKBOX | WS_TABSTOP,7,115,102,10
#ifdef USE_DYNAREC
CONTROL "Dynamic Recompiler",IDC_CHECK_DYNAREC,"Button",
BS_AUTOCHECKBOX | WS_TABSTOP,7,115,94,10
#endif
END
DLG_CFG_VIDEO DIALOG DISCARDABLE 97, 0, 267, 63

View File

@@ -8,7 +8,7 @@
#
# Makefile for Win32 (MinGW32) environment.
#
# Version: @(#)Makefile.mingw 1.0.62 2017/10/14
# Version: @(#)Makefile.mingw 1.0.63 2017/10/14
#
# Authors: Miran Grca, <mgrca8@gmail.com>
# Fred N. van Kempen, <decwiz@yahoo.com>
@@ -89,6 +89,9 @@ endif
ifndef PAS16
PAS16 = n
endif
ifndef DYNAREC
DYNAREC := y
endif
ifndef X64
X64 := n
endif
@@ -187,6 +190,17 @@ endif
# Optional modules.
ifeq ($(DYNAREC), y)
CFLAGS += -DUSE_DYNAREC
RFLAGS += -DUSE_DYNAREC
DYNARECOBJ := 386_dynarec_ops.o \
codegen.o \
codegen_ops.o \
codegen_timing_common.o codegen_timing_486.o \
codegen_timing_686.o codegen_timing_pentium.o \
codegen_timing_winchip.o $(PLATCG)
endif
ifeq ($(FLUIDSYNTH), y)
CFLAGS += -DUSE_FLUIDSYNTH
FSYNTHOBJ := midi_fluidsynth.o
@@ -265,13 +279,9 @@ MAINOBJ := pc.o config.o random.o timer.o io.o dma.o nmi.o pic.o \
device.o nvr.o nvr_at.o nvr_ps2.o \
intel.o intel_flash.o intel_sio.o
CPUOBJ := cpu.o 386.o 386_dynarec.o 386_dynarec_ops.o 808x.o \
codegen.o \
codegen_ops.o \
codegen_timing_common.o codegen_timing_486.o \
codegen_timing_686.o codegen_timing_pentium.o \
codegen_timing_winchip.o $(PLATCG) \
x86seg.o x87.o
CPUOBJ := cpu.o 386.o 386_dynarec.o 808x.o \
x86seg.o x87.o \
$(DYNARECOBJ)
MCHOBJ := machine.o \
machine_common.o \

View File

@@ -100,7 +100,9 @@
#define IDC_COMBO_CPU 1013
#define IDC_CHECK_FPU 1014
#define IDC_COMBO_WS 1015
#ifdef USE_DYNAREC
#define IDC_CHECK_DYNAREC 1016
#endif
#define IDC_MEMTEXT 1017
#define IDC_MEMSPIN 1018
#define IDC_TEXT_MB IDT_1705

View File

@@ -57,7 +57,10 @@
/* Machine category */
static int temp_machine, temp_cpu_m, temp_cpu, temp_wait_states, temp_mem_size, temp_dynarec, temp_fpu, temp_sync;
static int temp_machine, temp_cpu_m, temp_cpu, temp_wait_states, temp_mem_size, temp_fpu, temp_sync;
#ifdef USE_DYNAREC
static int temp_dynarec;
#endif
/* Video category */
static int temp_gfxcard, temp_video_speed, temp_voodoo;
@@ -135,7 +138,9 @@ static void win_settings_init(void)
temp_wait_states = cpu_waitstates;
temp_cpu = cpu;
temp_mem_size = mem_size;
#ifdef USE_DYNAREC
temp_dynarec = cpu_use_dynarec;
#endif
temp_fpu = enable_external_fpu;
temp_sync = enable_sync;
@@ -205,7 +210,9 @@ static int win_settings_changed(void)
i = i || (cpu_waitstates != temp_wait_states);
i = i || (cpu != temp_cpu);
i = i || (mem_size != temp_mem_size);
#ifdef USE_DYNAREC
i = i || (temp_dynarec != cpu_use_dynarec);
#endif
i = i || (temp_fpu != enable_external_fpu);
i = i || (temp_sync != enable_sync);
@@ -300,7 +307,9 @@ static void win_settings_save(void)
cpu_waitstates = temp_wait_states;
cpu = temp_cpu;
mem_size = temp_mem_size;
#ifdef USE_DYNAREC
cpu_use_dynarec = temp_dynarec;
#endif
enable_external_fpu = temp_fpu;
enable_sync = temp_sync;
@@ -382,7 +391,9 @@ static void win_settings_machine_recalc_cpu(HWND hdlg)
{
HWND h;
int temp_romset = 0;
#ifdef USE_DYNAREC
int cpu_flags;
#endif
int cpu_type;
temp_romset = machine_getromset_ex(temp_machine);
@@ -398,6 +409,7 @@ static void win_settings_machine_recalc_cpu(HWND hdlg)
EnableWindow(h, FALSE);
}
#ifdef USE_DYNAREC
h=GetDlgItem(hdlg, IDC_CHECK_DYNAREC);
cpu_flags = machines[romstomachine[temp_romset]].cpu[temp_cpu_m].cpus[temp_cpu].cpu_flags;
if (!(cpu_flags & CPU_SUPPORTS_DYNAREC) && (cpu_flags & CPU_REQUIRES_DYNAREC))
@@ -421,6 +433,7 @@ static void win_settings_machine_recalc_cpu(HWND hdlg)
{
EnableWindow(h, TRUE);
}
#endif
h = GetDlgItem(hdlg, IDC_CHECK_FPU);
cpu_type = machines[romstomachine[temp_romset]].cpu[temp_cpu_m].cpus[temp_cpu].cpu_type;
@@ -594,8 +607,10 @@ static BOOL CALLBACK win_settings_machine_proc(HWND hdlg, UINT message, WPARAM w
SendMessage(h, CB_SETCURSEL, temp_wait_states, 0);
#ifdef USE_DYNAREC
h=GetDlgItem(hdlg, IDC_CHECK_DYNAREC);
SendMessage(h, BM_SETCHECK, temp_dynarec, 0);
#endif
h = GetDlgItem(hdlg, IDC_MEMSPIN);
SendMessage(h, UDM_SETBUDDY, (WPARAM)GetDlgItem(hdlg, IDC_MEMTEXT), 0);
@@ -654,8 +669,10 @@ static BOOL CALLBACK win_settings_machine_proc(HWND hdlg, UINT message, WPARAM w
lptsTemp = (LPTSTR) malloc(512);
stransi = (char *) malloc(512);
#ifdef USE_DYNAREC
h=GetDlgItem(hdlg, IDC_CHECK_DYNAREC);
temp_dynarec = SendMessage(h, BM_GETCHECK, 0, 0);
#endif
h=GetDlgItem(hdlg, IDC_CHECK_SYNC);
temp_sync = SendMessage(h, BM_GETCHECK, 0, 0);

View File

@@ -12,7 +12,9 @@
#include "../ibm.h"
#include "../mem.h"
#include "../cpu/x86_ops.h"
#ifdef USE_DYNAREC
#include "../cpu/codegen.h"
#endif
#include "../device.h"
#include "win.h"
@@ -52,8 +54,10 @@ StatusWindowProcedure(HWND hdlg, UINT message, WPARAM wParam, LPARAM lParam)
"Timer 0 frequency : %fHz\n\n"
"CPU time : %f%% (%f%%)\n"
#ifdef USE_DYNAREC
"New blocks : %i\nOld blocks : %i\nRecompiled speed : %f MIPS\nAverage size : %f\n"
"Flushes : %i\nEvicted : %i\nReused : %i\nRemoved : %i\nReal speed : %f MIPS"
"Flushes : %i\nEvicted : %i\nReused : %i\nRemoved : %i"
#endif
,mips,
flops,
segareads,
@@ -61,13 +65,13 @@ StatusWindowProcedure(HWND hdlg, UINT message, WPARAM wParam, LPARAM lParam)
clockrate - scycles_lost,
pit_timer0_freq(),
((double)main_time * 100.0) / status_diff,
((double)main_time * 100.0) / timer_freq
((double)main_time * 100.0) / timer_freq
#ifdef USE_DYNAREC
, cpu_new_blocks_latched, cpu_recomp_blocks_latched, (double)cpu_recomp_ins_latched / 1000000.0, (double)cpu_recomp_ins_latched/cpu_recomp_blocks_latched,
cpu_recomp_flushes_latched, cpu_recomp_evicted_latched,
cpu_recomp_reuse_latched, cpu_recomp_removed_latched,
((double)cpu_recomp_ins_latched / 1000000.0) / ((double)main_time / timer_freq)
cpu_recomp_reuse_latched, cpu_recomp_removed_latched
#endif
);
main_time = 0;
SendDlgItemMessage(hdlg, IDT_SDEVICE, WM_SETTEXT,