Backed out changeset ec184d1877cf (bug 822096) for causing the same B2G failures as occurred in the Try run; CLOSED TREE

This commit is contained in:
Ed Morley 2013-08-22 16:16:16 +01:00
parent e4c10c125f
commit 89069fe47e

View File

@ -181,11 +181,11 @@ nsBaseAppShell::FavorPerformanceHint(bool favorPerfOverStarvation,
uint32_t starvationDelay)
{
mStarvationDelay = PR_MillisecondsToInterval(starvationDelay);
mSwitchTime = PR_IntervalNow();
if (favorPerfOverStarvation) {
++mFavorPerf;
} else {
--mFavorPerf;
mSwitchTime = PR_IntervalNow();
}
return NS_OK;
}
@ -268,8 +268,7 @@ nsBaseAppShell::OnProcessNextEvent(nsIThreadInternal *thr, bool mayWait,
// NativeEventCallback to process gecko events.
mProcessedGeckoEvents = false;
if (mFavorPerf <= 0 ||
start > mSwitchTime + std::max(mStarvationDelay, limit)) {
if (mFavorPerf <= 0 && start > mSwitchTime + mStarvationDelay) {
// Favor pending native events
PRIntervalTime now = start;
bool keepGoing;