SPU: remove passive lock (fixup)

This commit is contained in:
Nekotekina 2018-05-23 11:55:15 +03:00
commit 3e580afe21

View file

@ -1131,8 +1131,6 @@ void SPUThread::do_mfc(bool wait)
if (args.cmd & MFC_LIST_MASK)
{
if (!test(ch_stall_mask, mask))
{
if (g_use_rtm)
{
if (do_list_transfer(args))
{
@ -1140,18 +1138,6 @@ void SPUThread::do_mfc(bool wait)
return true;
}
}
else if (vm::passive_lock(*this, wait))
{
if (do_list_transfer(args))
{
vm::passive_unlock(*this);
removed++;
return true;
}
vm::passive_unlock(*this);
}
}
if (args.cmd & MFC_BARRIER_MASK)
{
@ -1163,27 +1149,9 @@ void SPUThread::do_mfc(bool wait)
}
if (args.size)
{
if (g_use_rtm)
{
do_dma_transfer(args);
}
else if (vm::passive_lock(*this, wait))
{
do_dma_transfer(args);
vm::passive_unlock(*this);
}
else
{
if (args.cmd & MFC_BARRIER_MASK)
{
barrier |= mask;
}
fence |= mask;
return false;
}
}
else if (args.cmd == MFC_PUTQLLUC_CMD)
{
if (fence & mask)
@ -1400,24 +1368,12 @@ bool SPUThread::process_mfc_cmd(spu_mfc_cmd args)
if (LIKELY(do_dma_check(args)))
{
if (LIKELY(args.size))
{
if (g_use_rtm)
{
do_dma_transfer(args);
}
return true;
}
else if (vm::passive_lock(*this, true))
{
do_dma_transfer(args);
vm::passive_unlock(*this);
return true;
}
}
else
{
return true;
}
}
mfc_queue[mfc_size++] = args;
mfc_fence |= 1u << args.tag;
@ -1445,25 +1401,12 @@ bool SPUThread::process_mfc_cmd(spu_mfc_cmd args)
if (LIKELY(args.size <= 0x4000))
{
if (LIKELY(do_dma_check(args) && !test(ch_stall_mask, 1u << args.tag)))
{
if (g_use_rtm)
{
if (LIKELY(do_list_transfer(args)))
{
return true;
}
}
else if (vm::passive_lock(*this, true))
{
if (LIKELY(do_list_transfer(args)))
{
vm::passive_unlock(*this);
return true;
}
vm::passive_unlock(*this);
}
}
mfc_queue[mfc_size++] = args;
mfc_fence |= 1u << args.tag;