gc: Fix wasDrainNecessary condition
We want to drain when we potentially don't have enough space, not when there's plenty of space. Change-Id: I939b3c69764b8b466fa045d0c9ba212722de1329 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
This commit is contained in:
parent
4b4bca359b
commit
fa69a45b38
|
@ -707,7 +707,7 @@ static constexpr int markLoopIterationCount = 1024;
|
||||||
|
|
||||||
bool wasDrainNecessary(MarkStack *ms, QDeadlineTimer deadline)
|
bool wasDrainNecessary(MarkStack *ms, QDeadlineTimer deadline)
|
||||||
{
|
{
|
||||||
if (ms->remainingBeforeSoftLimit() < markLoopIterationCount)
|
if (ms->remainingBeforeSoftLimit() > markLoopIterationCount)
|
||||||
return false;
|
return false;
|
||||||
// drain
|
// drain
|
||||||
ms->drain(deadline);
|
ms->drain(deadline);
|
||||||
|
|
Loading…
Reference in New Issue