Moved FPU register stack into cpu_state structure.
Fixed a couple of FPU bugs in x86-64 recompiler that were introduced in rev 543, fixes lightmap issues in Half-Life.
This commit is contained in:
parent
eb126fd822
commit
5a02b518b8
17 changed files with 907 additions and 883 deletions
|
|
@ -6,7 +6,7 @@ static int opPAND_a16(uint32_t fetchdat)
|
|||
fetch_ea_16(fetchdat);
|
||||
MMX_GETSRC();
|
||||
|
||||
MM[cpu_reg].q &= src.q;
|
||||
cpu_state.MM[cpu_reg].q &= src.q;
|
||||
return 0;
|
||||
}
|
||||
static int opPAND_a32(uint32_t fetchdat)
|
||||
|
|
@ -17,7 +17,7 @@ static int opPAND_a32(uint32_t fetchdat)
|
|||
fetch_ea_32(fetchdat);
|
||||
MMX_GETSRC();
|
||||
|
||||
MM[cpu_reg].q &= src.q;
|
||||
cpu_state.MM[cpu_reg].q &= src.q;
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
@ -29,7 +29,7 @@ static int opPANDN_a16(uint32_t fetchdat)
|
|||
fetch_ea_16(fetchdat);
|
||||
MMX_GETSRC();
|
||||
|
||||
MM[cpu_reg].q = ~MM[cpu_reg].q & src.q;
|
||||
cpu_state.MM[cpu_reg].q = ~cpu_state.MM[cpu_reg].q & src.q;
|
||||
return 0;
|
||||
}
|
||||
static int opPANDN_a32(uint32_t fetchdat)
|
||||
|
|
@ -40,7 +40,7 @@ static int opPANDN_a32(uint32_t fetchdat)
|
|||
fetch_ea_32(fetchdat);
|
||||
MMX_GETSRC();
|
||||
|
||||
MM[cpu_reg].q = ~MM[cpu_reg].q & src.q;
|
||||
cpu_state.MM[cpu_reg].q = ~cpu_state.MM[cpu_reg].q & src.q;
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
@ -52,7 +52,7 @@ static int opPOR_a16(uint32_t fetchdat)
|
|||
fetch_ea_16(fetchdat);
|
||||
MMX_GETSRC();
|
||||
|
||||
MM[cpu_reg].q |= src.q;
|
||||
cpu_state.MM[cpu_reg].q |= src.q;
|
||||
return 0;
|
||||
}
|
||||
static int opPOR_a32(uint32_t fetchdat)
|
||||
|
|
@ -63,7 +63,7 @@ static int opPOR_a32(uint32_t fetchdat)
|
|||
fetch_ea_32(fetchdat);
|
||||
MMX_GETSRC();
|
||||
|
||||
MM[cpu_reg].q |= src.q;
|
||||
cpu_state.MM[cpu_reg].q |= src.q;
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
@ -75,7 +75,7 @@ static int opPXOR_a16(uint32_t fetchdat)
|
|||
fetch_ea_16(fetchdat);
|
||||
MMX_GETSRC();
|
||||
|
||||
MM[cpu_reg].q ^= src.q;
|
||||
cpu_state.MM[cpu_reg].q ^= src.q;
|
||||
return 0;
|
||||
}
|
||||
static int opPXOR_a32(uint32_t fetchdat)
|
||||
|
|
@ -86,6 +86,6 @@ static int opPXOR_a32(uint32_t fetchdat)
|
|||
fetch_ea_32(fetchdat);
|
||||
MMX_GETSRC();
|
||||
|
||||
MM[cpu_reg].q ^= src.q;
|
||||
cpu_state.MM[cpu_reg].q ^= src.q;
|
||||
return 0;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue