mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2026-07-19 17:35:37 -05:00
Merge e68a464efd into d8d37fdbc4
This commit is contained in:
commit
462f356bab
|
|
@ -182,23 +182,14 @@ void Jit64::ComputeRC(preg_t preg, bool needs_test, bool needs_sext)
|
|||
|
||||
if (CheckMergedBranch(0))
|
||||
{
|
||||
// If the output operand to the cmp/rc op we're merging with the branch isn't used anymore, it'd
|
||||
// be better to flush it here so that we don't have to flush it on both sides of the branch.
|
||||
// The flush is before the TEST so that it can macro-op fusion with the conditional branch.
|
||||
gpr.Flush(~js.op->gprWillBeWritten & js.op->regsOut, RegCache::FlushMode::Undirty);
|
||||
if (needs_test)
|
||||
{
|
||||
TEST(32, arg, arg);
|
||||
arg.Unlock();
|
||||
}
|
||||
else
|
||||
{
|
||||
// If an operand to the cmp/rc op we're merging with the branch isn't used anymore, it'd be
|
||||
// better to flush it here so that we don't have to flush it on both sides of the branch.
|
||||
// We don't want to do this if a test is needed though, because it would interrupt macro-op
|
||||
// fusion.
|
||||
arg.Unlock();
|
||||
gpr.Flush(~(js.op->gprWillBeRead | js.op->gprWillBeWritten) &
|
||||
(js.op->regsIn | js.op->regsOut),
|
||||
RegCache::FlushMode::Full);
|
||||
gpr.Flush(~js.op->gprWillBeWritten & js.op->regsOut, RegCache::FlushMode::Undirty);
|
||||
}
|
||||
|
||||
arg.Unlock();
|
||||
DoMergedBranchCondition();
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -338,8 +338,8 @@ void RegCache::Flush(BitSet32 pregs, FlushMode mode,
|
|||
|
||||
for (preg_t i : pregs)
|
||||
{
|
||||
ASSERT_MSG(DYNA_REC, !m_regs[i].IsLocked(), "Someone forgot to unlock PPC reg {} (X64 reg {}).",
|
||||
i, std::to_underlying(RX(i)));
|
||||
ASSERT_MSG(DYNA_REC, mode != FlushMode::Full || !m_regs[i].IsLocked(),
|
||||
"Someone forgot to unlock PPC reg {} (X64 reg {}).", i, std::to_underlying(RX(i)));
|
||||
ASSERT_MSG(DYNA_REC, !m_regs[i].IsRevertable(), "Register transaction is in progress for {}!",
|
||||
i);
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user