diff --git a/pcsx2/x86/microVU.cpp b/pcsx2/x86/microVU.cpp index cc836a3a70..bcf478c048 100644 --- a/pcsx2/x86/microVU.cpp +++ b/pcsx2/x86/microVU.cpp @@ -163,7 +163,7 @@ microVUt(int) mVUfindLeastUsedProg() { }*/ mVUclearProg(j); // Clear old data if overwriting old program mVUcacheProg(j); // Cache Micro Program - Console::Notice("microVU%d: MicroProgram Cache Full!", params vuIndex); + //Console::Notice("microVU%d: MicroProgram Cache Full!", params vuIndex); return j; } } diff --git a/pcsx2/x86/microVU.h b/pcsx2/x86/microVU.h index 2137e9518c..f29f200b25 100644 --- a/pcsx2/x86/microVU.h +++ b/pcsx2/x86/microVU.h @@ -88,7 +88,7 @@ struct microProgManager { microRegInfo lpState; // Pipeline state from where program left off (useful for continuing execution) }; -#define mVUcacheSize (0x1f00000 / ((vuIndex) ? 1 : 4)) +#define mVUcacheSize (0x2000000 / ((vuIndex) ? 1 : 4)) struct microVU { u32 index; // VU Index (VU0 or VU1) u32 microSize; // VU Micro Memory Size diff --git a/pcsx2/x86/microVU_Analyze.inl b/pcsx2/x86/microVU_Analyze.inl index 5c8bbd117f..cc6d0d4cd7 100644 --- a/pcsx2/x86/microVU_Analyze.inl +++ b/pcsx2/x86/microVU_Analyze.inl @@ -234,6 +234,7 @@ microVUt(void) mVUanalyzeSQ(int Fs, int It, bool writeIt) { analyzeReg1(Fs); analyzeVIreg1(It); if (writeIt) { analyzeVIreg2(It, 1); } + if (mVUregsTemp.VFreg[0] == Fs) { mVUinfo |= _swapOps; } } //------------------------------------------------------------------ diff --git a/pcsx2/x86/microVU_Execute.inl b/pcsx2/x86/microVU_Execute.inl index a4ab238cd3..85285c3c6b 100644 --- a/pcsx2/x86/microVU_Execute.inl +++ b/pcsx2/x86/microVU_Execute.inl @@ -53,11 +53,11 @@ microVUt(void) mVUdispatcherA() { SSE_MOVAPS_M128_to_XMM(xmmT1, (uptr)&mVU->regs->VI[REG_MAC_FLAG].UL); SSE_SHUFPS_XMM_to_XMM (xmmT1, xmmT1, 0); - SSE_MOVAPS_XMM_to_M128((uptr)&mVU->regs->VI[REG_MAC_FLAG].UL, xmmT1); + SSE_MOVAPS_XMM_to_M128((uptr)mVU->macFlag, xmmT1); SSE_MOVAPS_M128_to_XMM(xmmT1, (uptr)&mVU->regs->VI[REG_CLIP_FLAG].UL); SSE_SHUFPS_XMM_to_XMM (xmmT1, xmmT1, 0); - SSE_MOVAPS_XMM_to_M128((uptr)&mVU->regs->VI[REG_CLIP_FLAG].UL, xmmT1); + SSE_MOVAPS_XMM_to_M128((uptr)mVU->clipFlag, xmmT1); SSE_MOVAPS_M128_to_XMM(xmmACC, (uptr)&mVU->regs->ACC.UL[0]); SSE_MOVAPS_M128_to_XMM(xmmMax, (uptr)mVU_maxvals); diff --git a/pcsx2/x86/microVU_Flags.inl b/pcsx2/x86/microVU_Flags.inl index 37a469a272..8a1a228059 100644 --- a/pcsx2/x86/microVU_Flags.inl +++ b/pcsx2/x86/microVU_Flags.inl @@ -53,6 +53,7 @@ microVUt(void) mVUstatusFlagOp() { } } iPC = curPC; + Console::Status("microVU%d: FSSET Optimization", params vuIndex); } int findFlagInst(int* fFlag, int cycles) { @@ -172,14 +173,15 @@ microVUt(void) mVUsetupFlags(int* xStatus, int* xMac, int* xClip, int cycles) { SSE_SHUFPS_XMM_to_XMM (xmmT1, xmmT1, shuffleMac); SSE_MOVAPS_XMM_to_M128((uptr)mVU->macFlag, xmmT1); } - +/* if (__Clip) { int bClip[4]; - sortFlag(xClip, bClip, cycles); + //sortFlag(xClip, bClip, cycles); + SysPrintf("__Clip\n"); SSE_MOVAPS_M128_to_XMM(xmmT1, (uptr)mVU->clipFlag); SSE_SHUFPS_XMM_to_XMM (xmmT1, xmmT1, shuffleClip); SSE_MOVAPS_XMM_to_M128((uptr)mVU->clipFlag, xmmT1); - } + }*/ } microVUt(void) mVUpass4(int startPC) { diff --git a/pcsx2/x86/microVU_Misc.h b/pcsx2/x86/microVU_Misc.h index 42f39247ee..c02f4a675c 100644 --- a/pcsx2/x86/microVU_Misc.h +++ b/pcsx2/x86/microVU_Misc.h @@ -222,11 +222,11 @@ declareAllVariables #define fmInstance ((mVUinfo >> 10) & 3) #define fsInstance ((mVUinfo >> 12) & 3) #define fpsInstance ((((mVUinfo>>12) & 3) - 1) & 0x3) -#define fcInstance ((mVUinfo >> 14) & 3) -#define fpcInstance ((((mVUinfo>>14) & 3) - 1) & 0x3) +#define fcInstance 0//((mVUinfo >> 14) & 3) +#define fpcInstance 0//((((mVUinfo>>14) & 3) - 1) & 0x3) #define fvmInstance ((mVUinfo >> 16) & 3) #define fvsInstance ((mVUinfo >> 18) & 3) -#define fvcInstance ((mVUinfo >> 20) & 3) +#define fvcInstance 0//((mVUinfo >> 20) & 3) #define backupVI (mVUinfo & (1<<22)) #define memReadIs (mVUinfo & (1<<23)) #define memReadIt (mVUinfo & (1<<24)) diff --git a/pcsx2/x86/microVU_Misc.inl b/pcsx2/x86/microVU_Misc.inl index 8f0e53850e..0299609bd6 100644 --- a/pcsx2/x86/microVU_Misc.inl +++ b/pcsx2/x86/microVU_Misc.inl @@ -299,7 +299,7 @@ microVUt(void) mVUrestoreRegs() { POP32R(gprR); // Restore EDX } - +// Reads entire microProgram and finds out if Status Flag is Used microVUt(void) mVUcheckSflag(int progIndex) { if (CHECK_VU_FLAGHACK) {