mirror of https://github.com/PCSX2/pcsx2.git
major code clean-up for FPUs, removed alot of old/useless code, and organized stuff better. trying to clean-up pcsx2 a bit..
*note: FPU reg caching is always on now; which means you need a SSE processor to run the FPU recs, if not it will just run the interpreter code instead (not really a bad thing, the int-code isn't much slower) git-svn-id: http://pcsx2-playground.googlecode.com/svn/trunk@153 a6443dda-0b58-4228-96e9-037be469359c
This commit is contained in:
parent
e961ab6591
commit
42ce99eb21
2083
pcsx2/x86/iFPU.c
2083
pcsx2/x86/iFPU.c
File diff suppressed because it is too large
Load Diff
|
@ -41,7 +41,7 @@
|
|||
#define CP2_RECOMPILE
|
||||
|
||||
#define EE_CONST_PROP // rec2 - enables constant propagation (faster)
|
||||
#define EE_FPU_REGCACHING 1
|
||||
//#define EE_FPU_REGCACHING 1 // Not used anymore, its always on!
|
||||
|
||||
#define PC_GETBLOCK(x) PC_GETBLOCK_(x, recLUT)
|
||||
|
||||
|
@ -243,12 +243,12 @@ void rec##fn(void) \
|
|||
#define FPURECOMPILE_CONSTCODE(fn, xmminfo) \
|
||||
void rec##fn(void) \
|
||||
{ \
|
||||
eeFPURecompileCode(rec##fn##_xmm, rec##fn##_, xmminfo); \
|
||||
eeFPURecompileCode(rec##fn##_xmm, fn, xmminfo); \
|
||||
}
|
||||
#endif
|
||||
|
||||
// rd = rs op rt (all regs need to be in xmm)
|
||||
int eeRecompileCodeXMM(int xmminfo);
|
||||
void eeFPURecompileCode(R5900FNPTR_INFO xmmcode, R5900FNPTR_INFO fpucode, int xmminfo);
|
||||
void eeFPURecompileCode(R5900FNPTR_INFO xmmcode, R5900FNPTR fpucode, int xmminfo);
|
||||
|
||||
#endif // __IR5900_H__
|
||||
|
|
|
@ -1290,11 +1290,11 @@ int eeRecompileCodeXMM(int xmminfo)
|
|||
#define PROCESS_EE_SETMODET_XMM(mmreg) ((xmmregs[mmreg].mode&MODE_WRITE)?PROCESS_EE_MODEWRITET:0)
|
||||
|
||||
// rd = rs op rt
|
||||
void eeFPURecompileCode(R5900FNPTR_INFO xmmcode, R5900FNPTR_INFO fpucode, int xmminfo)
|
||||
void eeFPURecompileCode(R5900FNPTR_INFO xmmcode, R5900FNPTR fpucode, int xmminfo)
|
||||
{
|
||||
int mmregs=-1, mmregt=-1, mmregd=-1, mmregacc=-1;
|
||||
|
||||
if( EE_FPU_REGCACHING && cpucaps.hasStreamingSIMDExtensions ) {
|
||||
if( cpucaps.hasStreamingSIMDExtensions ) {
|
||||
int info = PROCESS_EE_XMM;
|
||||
|
||||
if( xmminfo & XMMINFO_READS ) _addNeededFPtoXMMreg(_Fs_);
|
||||
|
@ -1436,11 +1436,10 @@ void eeFPURecompileCode(R5900FNPTR_INFO xmmcode, R5900FNPTR_INFO fpucode, int xm
|
|||
return;
|
||||
}
|
||||
|
||||
if( xmminfo & XMMINFO_READS ) _deleteFPtoXMMreg(_Fs_, 0);
|
||||
if( xmminfo & XMMINFO_READT ) _deleteFPtoXMMreg(_Ft_, 0);
|
||||
if( xmminfo & (XMMINFO_READD|XMMINFO_WRITED) ) _deleteFPtoXMMreg(_Fd_, 0);
|
||||
if( xmminfo & (XMMINFO_READACC|XMMINFO_WRITEACC) ) _deleteFPtoXMMreg(XMMFPU_ACC, 0);
|
||||
fpucode(0);
|
||||
MOV32ItoM((uptr)&cpuRegs.code, cpuRegs.code);
|
||||
MOV32ItoM((uptr)&cpuRegs.pc, pc);
|
||||
iFlushCall(FLUSH_EVERYTHING);
|
||||
CALLFunc((uptr)fpucode);
|
||||
}
|
||||
|
||||
#undef _Ft_
|
||||
|
|
Loading…
Reference in New Issue