mirror of
https://github.com/86Box/86Box.git
synced 2026-02-25 04:45:31 -07:00
Fixed several small bugs; among other things, the emulator now compiles without warnings when using DEBUG=y as well.
This commit is contained in:
@@ -70,6 +70,7 @@ uint32_t *eal_r, *eal_w;
|
||||
uint16_t *mod1add[2][8];
|
||||
uint32_t *mod1seg[8];
|
||||
|
||||
#if 0
|
||||
static __inline void fetch_ea_32_long(uint32_t rmdat)
|
||||
{
|
||||
eal_r = eal_w = NULL;
|
||||
@@ -184,6 +185,7 @@ static __inline void fetch_ea_16_long(uint32_t rmdat)
|
||||
eal_w = (uint32_t *)(writelookup2[addr >> 12] + addr);
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
#define fetch_ea_16(rmdat) cpu_state.pc++; cpu_mod=(rmdat >> 6) & 3; cpu_reg=(rmdat >> 3) & 7; cpu_rm = rmdat & 7; if (cpu_mod != 3) { fetch_ea_16_long(rmdat); if (cpu_state.abrt) return 0; }
|
||||
#define fetch_ea_32(rmdat) cpu_state.pc++; cpu_mod=(rmdat >> 6) & 3; cpu_reg=(rmdat >> 3) & 7; cpu_rm = rmdat & 7; if (cpu_mod != 3) { fetch_ea_32_long(rmdat); } if (cpu_state.abrt) return 0
|
||||
|
||||
@@ -390,12 +390,14 @@ static __inline uint16_t geteaw()
|
||||
return readmemw(easeg,cpu_state.eaaddr);
|
||||
}
|
||||
|
||||
#if 0
|
||||
static __inline uint16_t geteaw2()
|
||||
{
|
||||
if (cpu_mod == 3)
|
||||
return cpu_state.regs[cpu_rm].w;
|
||||
return readmemw(easeg,(cpu_state.eaaddr+2)&0xFFFF);
|
||||
}
|
||||
#endif
|
||||
|
||||
static __inline void seteab(uint8_t val)
|
||||
{
|
||||
|
||||
@@ -2029,7 +2029,6 @@ static inline void FP_LOAD_S()
|
||||
addbyte(0xdd); /*FSTP ST[reg][EBP]*/
|
||||
addbyte(0x5d);
|
||||
addbyte((uint8_t)cpu_state_offset(ST[(cpu_state.TOP - 1) & 7]));
|
||||
block_current = block_current;
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
@@ -64,7 +64,7 @@ static int opSETALC(uint32_t fetchdat)
|
||||
|
||||
static int opF6_a16(uint32_t fetchdat)
|
||||
{
|
||||
int tempws, tempws2;
|
||||
int tempws, tempws2 = 0;
|
||||
uint16_t tempw, src16;
|
||||
uint8_t src, dst;
|
||||
int8_t temps;
|
||||
@@ -161,7 +161,7 @@ static int opF6_a16(uint32_t fetchdat)
|
||||
}
|
||||
static int opF6_a32(uint32_t fetchdat)
|
||||
{
|
||||
int tempws, tempws2;
|
||||
int tempws, tempws2 = 0;
|
||||
uint16_t tempw, src16;
|
||||
uint8_t src, dst;
|
||||
int8_t temps;
|
||||
@@ -262,7 +262,7 @@ static int opF6_a32(uint32_t fetchdat)
|
||||
static int opF7_w_a16(uint32_t fetchdat)
|
||||
{
|
||||
uint32_t templ, templ2;
|
||||
int tempws, tempws2;
|
||||
int tempws, tempws2 = 0;
|
||||
int16_t temps16;
|
||||
uint16_t src, dst;
|
||||
|
||||
@@ -354,7 +354,7 @@ static int opF7_w_a16(uint32_t fetchdat)
|
||||
static int opF7_w_a32(uint32_t fetchdat)
|
||||
{
|
||||
uint32_t templ, templ2;
|
||||
int tempws, tempws2;
|
||||
int tempws, tempws2 = 0;
|
||||
int16_t temps16;
|
||||
uint16_t src, dst;
|
||||
|
||||
|
||||
@@ -278,7 +278,7 @@ static int opC0_a16(uint32_t fetchdat)
|
||||
{
|
||||
int c;
|
||||
int tempc;
|
||||
uint8_t temp, temp2;
|
||||
uint8_t temp, temp2 = 0;
|
||||
|
||||
fetch_ea_16(fetchdat);
|
||||
c = readmemb(cs, cpu_state.pc) & 31; cpu_state.pc++;
|
||||
@@ -291,7 +291,7 @@ static int opC0_a32(uint32_t fetchdat)
|
||||
{
|
||||
int c;
|
||||
int tempc;
|
||||
uint8_t temp, temp2;
|
||||
uint8_t temp, temp2 = 0;
|
||||
|
||||
fetch_ea_32(fetchdat);
|
||||
c = readmemb(cs, cpu_state.pc) & 31; cpu_state.pc++;
|
||||
@@ -304,7 +304,7 @@ static int opC1_w_a16(uint32_t fetchdat)
|
||||
{
|
||||
int c;
|
||||
int tempc;
|
||||
uint16_t temp, temp2;
|
||||
uint16_t temp, temp2 = 0;
|
||||
|
||||
fetch_ea_16(fetchdat);
|
||||
c = readmemb(cs, cpu_state.pc) & 31; cpu_state.pc++;
|
||||
@@ -317,7 +317,7 @@ static int opC1_w_a32(uint32_t fetchdat)
|
||||
{
|
||||
int c;
|
||||
int tempc;
|
||||
uint16_t temp, temp2;
|
||||
uint16_t temp, temp2 = 0;
|
||||
|
||||
fetch_ea_32(fetchdat);
|
||||
c = readmemb(cs, cpu_state.pc) & 31; cpu_state.pc++;
|
||||
@@ -330,7 +330,7 @@ static int opC1_l_a16(uint32_t fetchdat)
|
||||
{
|
||||
int c;
|
||||
int tempc;
|
||||
uint32_t temp, temp2;
|
||||
uint32_t temp, temp2 = 0;
|
||||
|
||||
fetch_ea_16(fetchdat);
|
||||
c = readmemb(cs, cpu_state.pc) & 31; cpu_state.pc++;
|
||||
@@ -343,7 +343,7 @@ static int opC1_l_a32(uint32_t fetchdat)
|
||||
{
|
||||
int c;
|
||||
int tempc;
|
||||
uint32_t temp, temp2;
|
||||
uint32_t temp, temp2 = 0;
|
||||
|
||||
fetch_ea_32(fetchdat);
|
||||
c = readmemb(cs, cpu_state.pc) & 31; cpu_state.pc++;
|
||||
@@ -357,7 +357,7 @@ static int opD0_a16(uint32_t fetchdat)
|
||||
{
|
||||
int c = 1;
|
||||
int tempc;
|
||||
uint8_t temp, temp2;
|
||||
uint8_t temp, temp2 = 0;
|
||||
|
||||
fetch_ea_16(fetchdat);
|
||||
temp = geteab(); if (cpu_state.abrt) return 1;
|
||||
@@ -368,7 +368,7 @@ static int opD0_a32(uint32_t fetchdat)
|
||||
{
|
||||
int c = 1;
|
||||
int tempc;
|
||||
uint8_t temp, temp2;
|
||||
uint8_t temp, temp2 = 0;
|
||||
|
||||
fetch_ea_32(fetchdat);
|
||||
temp = geteab(); if (cpu_state.abrt) return 1;
|
||||
@@ -379,7 +379,7 @@ static int opD1_w_a16(uint32_t fetchdat)
|
||||
{
|
||||
int c = 1;
|
||||
int tempc;
|
||||
uint16_t temp, temp2;
|
||||
uint16_t temp, temp2 = 0;
|
||||
|
||||
fetch_ea_16(fetchdat);
|
||||
temp = geteaw(); if (cpu_state.abrt) return 1;
|
||||
@@ -390,7 +390,7 @@ static int opD1_w_a32(uint32_t fetchdat)
|
||||
{
|
||||
int c = 1;
|
||||
int tempc;
|
||||
uint16_t temp, temp2;
|
||||
uint16_t temp, temp2 = 0;
|
||||
|
||||
fetch_ea_32(fetchdat);
|
||||
temp = geteaw(); if (cpu_state.abrt) return 1;
|
||||
@@ -401,7 +401,7 @@ static int opD1_l_a16(uint32_t fetchdat)
|
||||
{
|
||||
int c = 1;
|
||||
int tempc;
|
||||
uint32_t temp, temp2;
|
||||
uint32_t temp, temp2 = 0;
|
||||
|
||||
fetch_ea_16(fetchdat);
|
||||
temp = geteal(); if (cpu_state.abrt) return 1;
|
||||
@@ -412,7 +412,7 @@ static int opD1_l_a32(uint32_t fetchdat)
|
||||
{
|
||||
int c = 1;
|
||||
int tempc;
|
||||
uint32_t temp, temp2;
|
||||
uint32_t temp, temp2 = 0;
|
||||
|
||||
fetch_ea_32(fetchdat);
|
||||
temp = geteal(); if (cpu_state.abrt) return 1;
|
||||
@@ -424,7 +424,7 @@ static int opD2_a16(uint32_t fetchdat)
|
||||
{
|
||||
int c;
|
||||
int tempc;
|
||||
uint8_t temp, temp2;
|
||||
uint8_t temp, temp2 = 0;
|
||||
|
||||
fetch_ea_16(fetchdat);
|
||||
c = CL & 31;
|
||||
@@ -436,7 +436,7 @@ static int opD2_a32(uint32_t fetchdat)
|
||||
{
|
||||
int c;
|
||||
int tempc;
|
||||
uint8_t temp, temp2;
|
||||
uint8_t temp, temp2 = 0;
|
||||
|
||||
fetch_ea_32(fetchdat);
|
||||
c = CL & 31;
|
||||
@@ -448,7 +448,7 @@ static int opD3_w_a16(uint32_t fetchdat)
|
||||
{
|
||||
int c;
|
||||
int tempc;
|
||||
uint16_t temp, temp2;
|
||||
uint16_t temp, temp2 = 0;
|
||||
|
||||
fetch_ea_16(fetchdat);
|
||||
c = CL & 31;
|
||||
@@ -460,7 +460,7 @@ static int opD3_w_a32(uint32_t fetchdat)
|
||||
{
|
||||
int c;
|
||||
int tempc;
|
||||
uint16_t temp, temp2;
|
||||
uint16_t temp, temp2 = 0;
|
||||
|
||||
fetch_ea_32(fetchdat);
|
||||
c = CL & 31;
|
||||
@@ -472,7 +472,7 @@ static int opD3_l_a16(uint32_t fetchdat)
|
||||
{
|
||||
int c;
|
||||
int tempc;
|
||||
uint32_t temp, temp2;
|
||||
uint32_t temp, temp2 = 0;
|
||||
|
||||
fetch_ea_16(fetchdat);
|
||||
c = CL & 31;
|
||||
@@ -484,7 +484,7 @@ static int opD3_l_a32(uint32_t fetchdat)
|
||||
{
|
||||
int c;
|
||||
int tempc;
|
||||
uint32_t temp, temp2;
|
||||
uint32_t temp, temp2 = 0;
|
||||
|
||||
fetch_ea_32(fetchdat);
|
||||
c = CL & 31;
|
||||
|
||||
Reference in New Issue
Block a user