bool HTMLParserScheduler::yieldIfNeeded(const SpeculationsPumpSession& session, bool startingScript)
{
    if (shouldYield(session, startingScript)) {
        scheduleForResume();
        return true;
    }

    return false;
}
Exemple #2
0
bool PlanYieldPolicy::shouldYieldOrInterrupt() {
    if (_policy == PlanExecutor::INTERRUPT_ONLY) {
        return _elapsedTracker.intervalHasElapsed();
    }
    return shouldYield();
}