forked from mirrors/gecko-dev
Bug 1785162 - [3/3] stall for half time in non-main processes r=gsvelto
Retain the full stall period in the main process; stall for only half as long in all other processes. Differential Revision: https://phabricator.services.mozilla.com/D157140
This commit is contained in:
parent
adac61618a
commit
310ef2663b
1 changed files with 12 additions and 2 deletions
|
|
@ -1404,8 +1404,18 @@ static inline StallSpecs GetStallSpecs() {
|
||||||
// though, so it's probably not going to matter whether we stall here or not.)
|
// though, so it's probably not going to matter whether we stall here or not.)
|
||||||
return maxStall;
|
return maxStall;
|
||||||
# elif defined(NIGHTLY_BUILD)
|
# elif defined(NIGHTLY_BUILD)
|
||||||
// On Nightly, always stall, for experiment's sake (bug 1785162).
|
// On Nightly, partly for experiment's sake (bug 1785162):
|
||||||
return maxStall;
|
//
|
||||||
|
switch (GetGeckoProcessType()) {
|
||||||
|
// For the main process, stall for the maximum permissible time period. (The
|
||||||
|
// main process is the most important one to keep alive.)
|
||||||
|
case GeckoProcessType::GeckoProcessType_Default:
|
||||||
|
return maxStall;
|
||||||
|
|
||||||
|
// For all other process types, stall for at most half as long.
|
||||||
|
default:
|
||||||
|
return {.maxAttempts = kMaxAttempts / 2, .delayMs = kDelayMs};
|
||||||
|
}
|
||||||
# else
|
# else
|
||||||
// In the main process, always stall.
|
// In the main process, always stall.
|
||||||
if (GetGeckoProcessType() == GeckoProcessType::GeckoProcessType_Default) {
|
if (GetGeckoProcessType() == GeckoProcessType::GeckoProcessType_Default) {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue