Applied all mainline commits; Moved all declarations to not be in the middle of code; SVGA linear reads and writes now account for linear base; Fixed a bug with the Compaq ATI 28800.

This commit is contained in:
OBattler
2016-08-01 19:14:54 +02:00
parent d50a7e9449
commit 114bbdfc6d
29 changed files with 305 additions and 171 deletions

View File

@@ -470,9 +470,11 @@ static int opD3_l_a32(uint32_t fetchdat)
#define SHLD_w() \
if (count) \
{ \
uint16_t tempw = geteaw(); if (abrt) return 1; \
int tempc = ((tempw << (count - 1)) & (1 << 15)) ? 1 : 0; \
uint32_t templ = (tempw << 16) | cpu_state.regs[reg].w; \
uint16_t tempw = geteaw(); \
int tempc; uint32_t templ; \
if (abrt) return 1; \
tempc = ((tempw << (count - 1)) & (1 << 15)) ? 1 : 0; \
templ = (tempw << 16) | cpu_state.regs[reg].w; \
if (count <= 16) tempw = templ >> (16 - count); \
else tempw = (templ << count) >> 16; \
seteaw(tempw); if (abrt) return 1; \
@@ -484,8 +486,10 @@ static int opD3_l_a32(uint32_t fetchdat)
#define SHLD_l() \
if (count) \
{ \
uint32_t templ = geteal(); if (abrt) return 1; \
int tempc = ((templ << (count - 1)) & (1 << 31)) ? 1 : 0; \
uint32_t templ = geteal(); \
int tempc; \
if (abrt) return 1; \
tempc = ((templ << (count - 1)) & (1 << 31)) ? 1 : 0; \
templ = (templ << count) | (cpu_state.regs[reg].l >> (32 - count)); \
seteal(templ); if (abrt) return 1; \
setznp32(templ); \
@@ -497,9 +501,11 @@ static int opD3_l_a32(uint32_t fetchdat)
#define SHRD_w() \
if (count) \
{ \
uint16_t tempw = geteaw(); if (abrt) return 1; \
int tempc = (tempw >> (count - 1)) & 1; \
uint32_t templ = tempw | (cpu_state.regs[reg].w << 16); \
uint16_t tempw = geteaw(); \
int tempc; uint32_t templ; \
if (abrt) return 1; \
tempc = (tempw >> (count - 1)) & 1; \
templ = tempw | (cpu_state.regs[reg].w << 16); \
tempw = templ >> count; \
seteaw(tempw); if (abrt) return 1; \
setznp16(tempw); \
@@ -510,8 +516,10 @@ static int opD3_l_a32(uint32_t fetchdat)
#define SHRD_l() \
if (count) \
{ \
uint32_t templ = geteal(); if (abrt) return 1; \
int tempc = (templ >> (count - 1)) & 1; \
uint32_t templ = geteal(); \
int tempc; \
if (abrt) return 1; \
tempc = (templ >> (count - 1)) & 1; \
templ = (templ >> count) | (cpu_state.regs[reg].l << (32 - count)); \
seteal(templ); if (abrt) return 1; \
setznp32(templ); \