cfgfile_dwrite_bool (f, _T("cpu_no_unimplemented"), p->int_no_unimplemented);
cfgfile_write_bool (f, _T("fpu_strict"), p->fpu_strict);
cfgfile_dwrite_bool (f, _T("fpu_softfloat"), p->fpu_softfloat);
+ cfgfile_dwrite_bool (f, _T("fpu_arithmetic_exceptions"), p->fpu_exceptions);
cfgfile_write_bool (f, _T("rtg_nocustom"), p->picasso96_nocustom);
cfgfile_write (f, _T("rtg_modes"), _T("0x%x"), p->picasso96_modeflags);
return 1;
if (cfgfile_yesno(option, value, _T("magic_mouse"), &vb)) {
- p->input_mouse_untrap |= MOUSEUNTRAP_MAGIC;
+ if (vb)
+ p->input_mouse_untrap |= MOUSEUNTRAP_MAGIC;
+ else
+ p->input_mouse_untrap &= ~MOUSEUNTRAP_MAGIC;
return 1;
}
|| cfgfile_yesno (option, value, _T("serial_direct"), &p->serial_direct)
|| cfgfile_yesno (option, value, _T("fpu_strict"), &p->fpu_strict)
|| cfgfile_yesno (option, value, _T("fpu_softfloat"), &p->fpu_softfloat)
+ || cfgfile_yesno (option, value, _T("fpu_arithmetic_exceptions"), &p->fpu_exceptions)
|| cfgfile_yesno (option, value, _T("comp_nf"), &p->compnf)
|| cfgfile_yesno (option, value, _T("comp_constjump"), &p->comp_constjump)
#ifdef USE_JIT_FPU
p->int_no_unimplemented = false;
p->fpu_strict = 0;
p->fpu_softfloat = 0;
+ p->fpu_exceptions = 0;
p->m68k_speed = 0;
p->cpu_compatible = 1;
p->address_space_24 = 1;
p->input_tablet = TABLET_OFF;
p->tablet_library = false;
- p->input_mouse_untrap = MOUSEUNTRAP_NONE;
+ p->input_mouse_untrap = MOUSEUNTRAP_MIDDLEBUTTON;
p->input_magic_mouse_cursor = 0;
inputdevice_default_prefs (p);
static void record_color_change2 (int hpos, int regno, unsigned long value)
{
- int pos = hpos * 2;
- if (regno == 0x1000 + 0x10c)
- pos++; // BPLCON4 change needs 1 lores pixel delay
+ int pos = (hpos * 2) * 4;
+ if (regno == 0x1000 + 0x10c) {
+ pos += 4; // BPLCON4 change needs 1 lores pixel delay
+ }
curr_color_changes[next_color_change].linepos = pos;
curr_color_changes[next_color_change].regno = regno;
curr_color_changes[next_color_change].value = value;
}
pdip->last_color_change++;
pdip->nr_color_changes++;
- curr_color_changes[idx].linepos = (hpos + maxhpos) * 2 + extrahpos;
+ curr_color_changes[idx].linepos = ((hpos + maxhpos) * 2 + extrahpos) * 4;
curr_color_changes[idx].regno = regno;
curr_color_changes[idx].value = value;
if (lastsync) {
- curr_color_changes[idx + 1].linepos = hsyncstartpos * 2;
+ curr_color_changes[idx + 1].linepos = (hsyncstartpos * 2) * 4;
curr_color_changes[idx + 1].regno = 0xffff;
curr_color_changes[idx + 2].regno = -1;
} else {
for (idx1 = dip1->first_color_change; idx1 < dip1->last_color_change; idx1++) {
struct color_change *cs2 = &curr_color_changes[idx1];
int regno = cs2->regno;
- int hpos = cs2->linepos;
+ int hpos = cs2->linepos / 4;
if (regno < 0x1000 && hpos < HBLANK_OFFSET && !(beamcon0 & 0x80) && prev_lineno >= 0) {
struct draw_info *pdip = curr_drawinfo + next_lineno - 1;
int idx = pdip->last_color_change;
pdip->last_color_change++;
pdip->nr_color_changes++;
- curr_color_changes[idx].linepos = hpos + maxhpos + 1;
+ curr_color_changes[idx].linepos = (hpos + maxhpos + 1) * 4;
curr_color_changes[idx].regno = regno;
curr_color_changes[idx].value = cs2->value;
curr_color_changes[idx + 1].regno = -1;
#endif
blkdev_entergui();
#ifdef RETROPLATFORM
- rp_pause(pause_emulation);
+ rp_pause(1);
#endif
pausevideograb(1);
ethernet_pause(1);
{
blkdev_exitgui();
#ifdef RETROPLATFORM
- rp_pause(pause_emulation);
+ rp_pause(0);
#endif
#ifdef WITH_PPC
uae_ppc_pause(0);
if (h < 0)
h = 0;
-
- c = 0; // HACK
+
+ if (c < 8) // HACK
+ c = 0;
// c = internal cycles needed after head cycles and before tail cycles. Not total cycles.
addcycles_ce020 ("op", h, t, c - h - t, -subhead);
static void addop_ce020 (instr *curi, int subhead)
{
- if (!isce020())
- return;
- int h = curi->head;
- int t = curi->tail;
- int c = curi->clocks;
-#if 0
- if ((((curi->sduse & 2) && !isreg (curi->smode)) || (((curi->sduse >> 4) & 2) && !isreg (curi->dmode))) && using_waitstates) {
- t += using_waitstates;
- c += using_waitstates;
+ if (isce020()) {
+ int h = curi->head;
+ int t = curi->tail;
+ int c = curi->clocks;
+ #if 0
+ if ((((curi->sduse & 2) && !isreg (curi->smode)) || (((curi->sduse >> 4) & 2) && !isreg (curi->dmode))) && using_waitstates) {
+ t += using_waitstates;
+ c += using_waitstates;
+ }
+ #endif
+ addopcycles_ce20 (h, t, c, -subhead);
}
-#endif
- addopcycles_ce20 (h, t, c, -subhead);
}
static void addcycles_ea_ce020 (const char *ea, int h, int t, int c, int oph)
{
+ if (!isce020())
+ return;
+
head_cycs (h + oph);
// if (!h && !h && !c && !oph)
// we have fixup already active = this genamode call is destination mode and we can now clear previous source fixup.
clearmmufixup (0);
}
- if (isce020() && curi)
+ if (curi)
addop_ce020 (curi, subhead);
}
printf ("\t\tif (frame == 0x0) { m68k_areg (regs, 7) += offset; break; }\n");
printf ("\t\telse if (frame == 0x1) { m68k_areg (regs, 7) += offset; }\n");
printf ("\t\telse if (frame == 0x2) { m68k_areg (regs, 7) += offset + 4; break; }\n");
- if (using_mmu == 68060) {
+ if (cpu_level >= 4) {
+ printf ("\t\telse if (frame == 0x3) { m68k_areg (regs, 7) += offset + 4; break; }\n");
+ }
+ if (using_mmu == 68060) {
printf ("\t\telse if (frame == 0x4) { m68k_do_rte_mmu060 (a); m68k_areg (regs, 7) += offset + 8; break; }\n");
} else if (cpu_level >= 4) {
printf ("\t\telse if (frame == 0x4) { m68k_areg (regs, 7) += offset + 8; break; }\n");
sync_m68k_pc ();
did_prefetch = 0;
ipl_fetched = 0;
+ if (cpu_level >= 2 && !using_ce && !using_ce020) {
+ count_cycles = insn_n_cycles = curi->clocks;
+ }
}
static void generate_includes (FILE * f, int id)
STATIC_INLINE void limit_cycles_ce020(int clocks)
{
+#if 0
int cycs = clocks * cpucycleunit;
int diff = regs.ce020endcycle - regs.ce020startcycle;
if (diff <= cycs)
return;
regs.ce020startcycle = regs.ce020endcycle - cycs;
+#endif
}
STATIC_INLINE void limit_all_cycles_ce020(void)
{
+#if 0
regs.ce020startcycle = regs.ce020endcycle;
+#endif
}
// only for CPU internal cycles
extern int visible_left_border, visible_right_border;
extern int detected_screen_resolution;
+STATIC_INLINE int shres_coord_hw_to_window_x (int x)
+{
+ x -= DISPLAY_LEFT_SHIFT << 2;
+ x <<= lores_shift;
+ x >>= 2;
+ return x;
+}
+
STATIC_INLINE int coord_hw_to_window_x (int x)
{
x -= DISPLAY_LEFT_SHIFT;
bool fpu_strict;
bool fpu_softfloat;
+ bool fpu_exceptions;
int gfx_framerate, gfx_autoframerate;
struct wh gfx_size_win;
error_log (_T("JIT is not compatible with unimplemented CPU/FPU instruction emulation."));
p->fpu_no_unimplemented = p->int_no_unimplemented = false;
}
- if (p->cachesize && p->compfpu && p->fpu_softfloat) {
+ if (p->cachesize && p->compfpu && (p->fpu_softfloat || p->fpu_exceptions)) {
error_log (_T("JIT FPU emulation is not compatible with softfloat FPU emulation."));
p->fpu_softfloat = false;
+ p->fpu_exceptions = false;
}
#if 0
|| currprefs.cpu_compatible != changed_prefs.cpu_compatible
|| currprefs.cpu_cycle_exact != changed_prefs.cpu_cycle_exact
|| currprefs.cpu_memory_cycle_exact != changed_prefs.cpu_memory_cycle_exact
- || currprefs.fpu_softfloat != changed_prefs.fpu_softfloat) {
+ || currprefs.fpu_softfloat != changed_prefs.fpu_softfloat
+ || currprefs.fpu_exceptions != changed_prefs.fpu_exceptions) {
cpu_prefs_changed_flag |= 1;
}
if (changed
#define IDC_22KHZ 1233
#define IDC_SPEED_x86 1233
#define IDC_44KHZ 1234
+#define IDC_FPU_EXCEPTIONS 1234
#define IDC_48KHZ 1235
#define IDC_SOUNDSIZE 1236
#define IDC_FREQUENCY 1237
CONTROL "Indirect",IDC_TRUST1,"Button",BS_AUTORADIOBUTTON | WS_TABSTOP,221,299,72,10
CONTROL "No flags",IDC_NOFLAGS,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,299,299,68,11
CONTROL "Softfloat FPU emulation",IDC_FPU_SOFTFLOAT,"Button",BS_AUTOCHECKBOX | BS_LEFT | WS_GROUP | WS_TABSTOP,8,285,115,10
+ CONTROL "Arithmetic exceptions",IDC_FPU_EXCEPTIONS,"Button",BS_AUTOCHECKBOX | BS_LEFT | WS_GROUP | WS_TABSTOP,8,298,115,10
END
IDD_FLOPPY DIALOGEX 0, 0, 396, 261
inputdevice_uaelib(_T("JOY2_2ND_BUTTON"), 0, 1, false);
}
if (ts->axis >= 0) {
- const RECT *r = &rcontrol[ts->port];
if (ts->port == 0) {
inputdevice_uaelib(_T("MOUSE1_HORIZ"), 0, -1, false);
inputdevice_uaelib(_T("MOUSE1_VERT"), 0, -1, false);
{
RECT rgui, rcontrol[2];
int bottom;
+
+ if (currprefs.input_tablet)
+ return;
+
if (isfullscreen()) {
rgui.left = amigawin_rect.left;
rgui.top = amigawin_rect.top;
{
struct midiportinfo *midp;
- cfgfile_target_dwrite_bool (f, _T("middle_mouse"), (p->input_mouse_untrap & MOUSEUNTRAP_MIDDLEBUTTON) != 0);
+ cfgfile_target_write_bool (f, _T("middle_mouse"), (p->input_mouse_untrap & MOUSEUNTRAP_MIDDLEBUTTON) != 0);
cfgfile_target_dwrite_bool (f, _T("logfile"), p->win32_logfile);
cfgfile_target_dwrite_bool (f, _T("map_drives"), p->win32_automount_drives);
cfgfile_target_dwrite_bool (f, _T("map_drives_auto"), p->win32_automount_removable);
if (cfgfile_yesno(option, value, _T("middle_mouse"), &tbool)) {
if (tbool)
p->input_mouse_untrap |= MOUSEUNTRAP_MIDDLEBUTTON;
+ else
+ p->input_mouse_untrap &= ~MOUSEUNTRAP_MIDDLEBUTTON;
return 1;
}
#define LANG_DLL_FULL_VERSION_MATCH 1
#if WINUAEPUBLICBETA
-#define WINUAEBETA _T("1")
+#define WINUAEBETA _T("2")
#else
#define WINUAEBETA _T("")
#endif
-#define WINUAEDATE MAKEBD(2017, 2, 11)
+#define WINUAEDATE MAKEBD(2017, 2, 25)
//#define WINUAEEXTRA _T("AmiKit Preview")
//#define WINUAEEXTRA _T("Amiga Forever Edition")
ew (hDlg, IDC_COMPATIBLE_FPU, workprefs.fpu_model > 0);
ew (hDlg, IDC_FPU_UNIMPLEMENTED, workprefs.fpu_model && !workprefs.cachesize);
ew (hDlg, IDC_FPU_SOFTFLOAT, workprefs.fpu_model && (!workprefs.compfpu || !workprefs.cachesize));
+ ew (hDlg, IDC_FPU_EXCEPTIONS, workprefs.fpu_model && (!workprefs.compfpu || !workprefs.cachesize) && workprefs.fpu_softfloat);
ew (hDlg, IDC_CPU_UNIMPLEMENTED, workprefs.cpu_model == 68060 && !workprefs.cachesize);
#if 0
ew (hDlg, IDC_CPU_MULTIPLIER, workprefs.cpu_cycle_exact);
CheckDlgButton (hDlg, IDC_COMPATIBLE_FPU, workprefs.fpu_strict);
CheckDlgButton (hDlg, IDC_FPU_UNIMPLEMENTED, !workprefs.fpu_no_unimplemented || workprefs.cachesize);
CheckDlgButton (hDlg, IDC_FPU_SOFTFLOAT, workprefs.fpu_softfloat);
+ CheckDlgButton (hDlg, IDC_FPU_EXCEPTIONS, workprefs.fpu_exceptions);
CheckDlgButton (hDlg, IDC_CPU_UNIMPLEMENTED, !workprefs.int_no_unimplemented || workprefs.cachesize);
SendDlgItemMessage (hDlg, IDC_CPUIDLE, TBM_SETPOS, TRUE, workprefs.cpu_idle == 0 ? 0 : 12 - workprefs.cpu_idle / 15);
SendDlgItemMessage (hDlg, IDC_PPC_CPUIDLE, TBM_SETPOS, TRUE, workprefs.ppc_cpu_idle);
workprefs.fpu_strict = ischecked (hDlg, IDC_COMPATIBLE_FPU) ? 1 : 0;
workprefs.fpu_no_unimplemented = ischecked (hDlg, IDC_FPU_UNIMPLEMENTED) ? 0 : 1;
workprefs.fpu_softfloat = ischecked (hDlg, IDC_FPU_SOFTFLOAT) ? 1 : 0;
+ workprefs.fpu_exceptions = (ischecked (hDlg, IDC_FPU_EXCEPTIONS) ? 1 : 0) && workprefs.fpu_softfloat;
workprefs.int_no_unimplemented = ischecked (hDlg, IDC_CPU_UNIMPLEMENTED) ? 0 : 1;
workprefs.address_space_24 = ischecked (hDlg, IDC_COMPATIBLE24) ? 1 : 0;
workprefs.m68k_speed = ischecked (hDlg, IDC_CS_HOST) ? -1 : 0;
}
if (workprefs.cachesize && workprefs.compfpu && workprefs.fpu_softfloat) {
workprefs.fpu_softfloat = false;
+ workprefs.fpu_exceptions = false;
setchecked(hDlg, IDC_FPU_SOFTFLOAT, false);
}
if (oldcache == 0 && workprefs.cachesize > 0) {
- RTG VRAM is outside of reserved natmem space. Workaround: Move RTG in earlier position using Hardware info GUI panel.\r
Note that in 64-bit version RTG VRAM must be inside of reserved natmem space. (Outside = error message and return back to GUI)\r
\r
+\r
+- FM801 16-bit audio corruption fixed.\r
+- Some 68020 CE mode cycle-counting is back.\r
+- Clear button state mask when mouse capture state changes. If mouse or joystick button was kept pressed when mouse was\r
+ uncaptured, button was kept pressed when capture state was restored even if real button was already pressed.\r
+- G-REX and Cirrus Logic graphics board state was reset if autoconfig board info was re-scanned (entering RAM or HW Info panels)\r
+ and emulation was already running (3.4.0)\r
+- Middle mouse button default is back to enabled. (was changed in b1)\r
+- Magic mouse on the fly on change didn't work.\r
+- FPU exception handling rewrite, arithmetic exceptions partially implemented (Andreas Grabher), 68040 unimplemented FSAVE\r
+ exception frame compatibility improved. Arithmetic exceptions are not that useful in Amiga emulation, programs that use FPU\r
+ arithmetic exceptions are very rare. I don't know any, report if you find one :)\r
+- FPU arithmetic exceptions checkbox added to GUI for easier testing. Will be removed when exceptions are fully implemented.\r
+ Even when exceptions are disabled, they are still logged. Softfloat FPU only only.\r
+\r
Beta 1:\r
\r
- Quickstart Blizzard modes (except if JIT enabled) enabled 24-bit addressing which caused new autoconfig/fallback mode\r
- Added Lock drive option to real harddrive mount dialog. If checked, all partitions in selected drive will be locked\r
and unmounted when emulation is running, enabling full read/write access even if drive has Windows mounted FAT partition(s).\r
Lock will be ignored if drive has one or more NTFS partitions.\r
+- Add harddrive didn't accept magneto-optical devices.\r
- Lots of softfloat FPU mode and normal FPU mode fixes and updates. (Andreas Grabher and me)\r
- Softfloat FPU mode added to GUI, supports on the fly switching.\r
+- Untrap middle mouse button option was stuck.\r
- Implemented accurate 68020+ T0 trace mode emulation. (Original one has not been changed for ages..)\r
- Fixed crash when sound card audio play started and mono sound channel mode and "Include CD and FMV audio" was ticked.\r
- 271b3 "Blitter final D write don't increase "nasty" count" That is not true, I think this was only added to fix demo\r
static int get_dns_addr(struct in_addr *pdns_addr)
{
char buff[512];
- char buff2[256];
+ char buff2[256+1];
FILE *f;
int found = 0;
struct in_addr tmp_addr;