Now up to date with current dev version.

Changes since v0.7 :
- Major CPU reorganisation. This has possibly broken some stuff, though I fixed all the regressions I could find
- Lazy flags. This brought 10% speed improvement at one point, but that's probably been lost now
- 430 VX chipset emulation
- IDT Winchip emulation (currently sans MMX). Timing is probably wrong
- Fixed a few FPU bugs
- Timer reorganisation
- Sound reorganisation
- Other general reorganisation
- AdLib Gold emulation
- Windows Sound System emulation
- Pro Audio Spectrum 16 emulation. This currently works with most DOS stuff, but not in Windows
- Major improvements to GUS emulation. Has the downside that it now conflicts with SB emulation, so probably best to not enable both simultaneously
- New graphics cards :
  - ATI-18800 (VGA Edge-16)
  - ATI-28800 (VGA Charger)
  - ATI Mach64GX (Graphics Pro Turbo). Quite a few features missing, but Windows doesn't seem to use half the features of this card
  - Cirrus Logic CL-GD5429. Blitter is a bit broken
  - Oak OTI-067
  - S3 Trio64 (Number Nine 9FX)
  - S3 Virge. Only framebuffer stuff at the minute, Windows won't recognise the card
  - Trident TGUI-9440
  - VGA. Doesn't work yet
- Beginnings of 3DFX emulation, however this is in extremely early stages and doesn't do anything useful
- Fixed DMA bug stopping floppy drives working in Windows 3.x
- Fixed some other stuff probably
- Broke some other stuff probably as well
This commit is contained in:
TomW 2013-05-27 17:46:42 +01:00
commit 9312de19ac
87 changed files with 4528 additions and 9373 deletions

View file

@ -1,22 +1,23 @@
#include "ibm.h"
#include "io.h"
#include "mem.h"
#include "pci.h"
#include "um8881f.h"
static uint8_t card_16[256];
static uint8_t card_18[256];
void um8881f_write(int func, int addr, uint8_t val)
void um8881f_write(int func, int addr, uint8_t val, void *priv)
{
if (addr == 0x54)
{
if ((card_16[0x54] ^ val) & 0x01)
{
if (val & 1)
mem_sethandler(0xe0000, 0x10000, mem_read_ram, mem_read_ramw, mem_read_raml, mem_write_ram, mem_write_ramw, mem_write_raml);
mem_sethandler(0xe0000, 0x10000, mem_read_ram, mem_read_ramw, mem_read_raml, mem_write_ram, mem_write_ramw, mem_write_raml, NULL);
else
mem_sethandler(0xf0000, 0x10000, mem_read_bios, mem_read_biosw, mem_read_biosl, NULL, NULL, NULL );
mem_sethandler(0xf0000, 0x10000, mem_read_bios, mem_read_biosw, mem_read_biosl, NULL, NULL, NULL , NULL);
}
flushmmucache_nopc();
}
@ -26,10 +27,10 @@ void um8881f_write(int func, int addr, uint8_t val)
{
switch (val & 0xc0)
{
case 0x00: mem_sethandler(0xf0000, 0x10000, mem_read_bios, mem_read_biosw, mem_read_biosl, mem_write_ram, mem_write_ramw, mem_write_raml); break;
case 0x40: mem_sethandler(0xf0000, 0x10000, mem_read_bios, mem_read_biosw, mem_read_biosl, NULL, NULL, NULL ); break;
case 0x80: mem_sethandler(0xf0000, 0x10000, mem_read_ram, mem_read_ramw, mem_read_raml, mem_write_ram, mem_write_ramw, mem_write_raml); break;
case 0xc0: mem_sethandler(0xf0000, 0x10000, mem_read_ram, mem_read_ramw, mem_read_raml, NULL, NULL, NULL ); break;
case 0x00: mem_sethandler(0xf0000, 0x10000, mem_read_bios, mem_read_biosw, mem_read_biosl, mem_write_ram, mem_write_ramw, mem_write_raml, NULL); break;
case 0x40: mem_sethandler(0xf0000, 0x10000, mem_read_bios, mem_read_biosw, mem_read_biosl, NULL, NULL, NULL , NULL); break;
case 0x80: mem_sethandler(0xf0000, 0x10000, mem_read_ram, mem_read_ramw, mem_read_raml, mem_write_ram, mem_write_ramw, mem_write_raml, NULL); break;
case 0xc0: mem_sethandler(0xf0000, 0x10000, mem_read_ram, mem_read_ramw, mem_read_raml, NULL, NULL, NULL , NULL); break;
}
shadowbios = val & 0x80;
shadowbios_write = !(val & 0x40);
@ -40,18 +41,18 @@ void um8881f_write(int func, int addr, uint8_t val)
card_16[addr] = val;
}
uint8_t um8881f_read(int func, int addr)
uint8_t um8881f_read(int func, int addr, void *priv)
{
return card_16[addr];
}
void um8886f_write(int func, int addr, uint8_t val)
void um8886f_write(int func, int addr, uint8_t val, void *priv)
{
if (addr >= 4)
card_18[addr] = val;
}
uint8_t um8886f_read(int func, int addr)
uint8_t um8886f_read(int func, int addr, void *priv)
{
return card_18[addr];
}
@ -60,8 +61,8 @@ uint8_t um8886f_read(int func, int addr)
void um8881f_init()
{
pci_add_specific(16, um8881f_read, um8881f_write);
pci_add_specific(18, um8886f_read, um8886f_write);
pci_add_specific(16, um8881f_read, um8881f_write, NULL);
pci_add_specific(18, um8886f_read, um8886f_write, NULL);
card_16[0] = card_18[0] = 0x60; /*UMC*/
card_16[1] = card_18[1] = 0x10;