mirror of
https://github.com/libretro/ppsspp.git
synced 2025-01-29 12:52:34 +00:00
Fix bug where dispatcher would not check core state directly after Advance. Fixes #9398 properly (it was previously hidden somehow with extra backbuffer binds).
This commit is contained in:
parent
e78d85f386
commit
b4740a2bca
@ -177,7 +177,7 @@ void ArmJit::GenerateFixedCode() {
|
||||
QuickCallFunction(R0, &CoreTiming::Advance);
|
||||
ApplyRoundingMode(true);
|
||||
RestoreDowncount();
|
||||
FixupBranch skipToRealDispatch = B(); //skip the sync and compare first time
|
||||
FixupBranch skipToCoreStateCheck = B(); //skip the downcount check
|
||||
|
||||
dispatcherCheckCoreState = GetCodePtr();
|
||||
|
||||
@ -185,6 +185,8 @@ void ArmJit::GenerateFixedCode() {
|
||||
// IMPORTANT - We jump on negative, not carry!!!
|
||||
FixupBranch bailCoreState = B_CC(CC_MI);
|
||||
|
||||
SetJumpTarget(skipToCoreStateCheck);
|
||||
|
||||
MOVI2R(R0, (u32)(uintptr_t)&coreState);
|
||||
LDR(R0, R0);
|
||||
CMP(R0, 0);
|
||||
@ -202,7 +204,6 @@ void ArmJit::GenerateFixedCode() {
|
||||
// IMPORTANT - We jump on negative, not carry!!!
|
||||
FixupBranch bail = B_CC(CC_MI);
|
||||
|
||||
SetJumpTarget(skipToRealDispatch);
|
||||
SetJumpTarget(skipToRealDispatch2);
|
||||
|
||||
dispatcherNoCheck = GetCodePtr();
|
||||
|
@ -217,7 +217,7 @@ void Arm64Jit::GenerateFixedCode(const JitOptions &jo) {
|
||||
QuickCallFunction(SCRATCH1_64, &CoreTiming::Advance);
|
||||
ApplyRoundingMode(true);
|
||||
LoadStaticRegisters();
|
||||
FixupBranch skipToRealDispatch = B(); //skip the sync and compare first time
|
||||
FixupBranch skipToCoreStateCheck = B(); //skip the downcount check
|
||||
|
||||
dispatcherCheckCoreState = GetCodePtr();
|
||||
|
||||
@ -225,6 +225,8 @@ void Arm64Jit::GenerateFixedCode(const JitOptions &jo) {
|
||||
// IMPORTANT - We jump on negative, not carry!!!
|
||||
FixupBranch bailCoreState = B(CC_MI);
|
||||
|
||||
SetJumpTarget(skipToCoreStateCheck);
|
||||
|
||||
MOVP2R(SCRATCH1_64, &coreState);
|
||||
LDR(INDEX_UNSIGNED, SCRATCH1, SCRATCH1_64, 0);
|
||||
CMP(SCRATCH1, 0);
|
||||
@ -242,7 +244,6 @@ void Arm64Jit::GenerateFixedCode(const JitOptions &jo) {
|
||||
// IMPORTANT - We jump on negative, not carry!!!
|
||||
FixupBranch bail = B(CC_MI);
|
||||
|
||||
SetJumpTarget(skipToRealDispatch);
|
||||
SetJumpTarget(skipToRealDispatch2);
|
||||
|
||||
dispatcherNoCheck = GetCodePtr();
|
||||
|
@ -144,7 +144,7 @@ void Jit::GenerateFixedCode(JitOptions &jo) {
|
||||
RestoreRoundingMode(true);
|
||||
ABI_CallFunction(reinterpret_cast<void *>(&CoreTiming::Advance));
|
||||
ApplyRoundingMode(true);
|
||||
FixupBranch skipToRealDispatch = J(); //skip the sync and compare first time
|
||||
FixupBranch skipToCoreStateCheck = J(); //skip the downcount check
|
||||
|
||||
dispatcherCheckCoreState = GetCodePtr();
|
||||
|
||||
@ -152,6 +152,7 @@ void Jit::GenerateFixedCode(JitOptions &jo) {
|
||||
// IMPORTANT - We jump on negative, not carry!!!
|
||||
FixupBranch bailCoreState = J_CC(CC_S, true);
|
||||
|
||||
SetJumpTarget(skipToCoreStateCheck);
|
||||
CMP(32, M(&coreState), Imm32(0));
|
||||
FixupBranch badCoreState = J_CC(CC_NZ, true);
|
||||
FixupBranch skipToRealDispatch2 = J(); //skip the sync and compare first time
|
||||
@ -162,7 +163,6 @@ void Jit::GenerateFixedCode(JitOptions &jo) {
|
||||
// IMPORTANT - We jump on negative, not carry!!!
|
||||
FixupBranch bail = J_CC(CC_S, true);
|
||||
|
||||
SetJumpTarget(skipToRealDispatch);
|
||||
SetJumpTarget(skipToRealDispatch2);
|
||||
|
||||
dispatcherNoCheck = GetCodePtr();
|
||||
|
Loading…
x
Reference in New Issue
Block a user