Граф коммитов

98 Коммитов

Автор SHA1 Сообщение Дата
Nika Layzell f1ac9bf744 Bug 1419597 - Part 18: Remove IsInnerWindow and IsOuterWindow methods, r=smaug
MozReview-Commit-ID: DAAm6tLubhJ
2017-11-23 13:12:13 -05:00
Nika Layzell 920ec9caac Bug 1419144 - Part 15: Move PopupControlState into nsContentUtils, r=smaug
MozReview-Commit-ID: Kt2moF5nsDg
2017-11-23 13:11:34 -05:00
Nika Layzell 3409141758 Bug 1414974 - Part 2: Switch many consumers to nsGlobalWindow{Inner,Outer}, r=smaug
This is a large patch which tries to switch many of the external consumers of
nsGlobalWindow to instead use the new Inner or Outer variants.

MozReview-Commit-ID: 99648Lm46T5
2017-11-09 10:44:47 -05:00
Kris Maglione 60d080b412 Bug 1404198: Part 2i - Switch to NS_NewTimer* in dom. r=njn
MozReview-Commit-ID: 8Oei6TuXNbu

--HG--
extra : rebase_source : 31c583c699790cbcf302064146d313ee8126ef0c
2017-10-15 23:15:40 -07:00
Andreas Farre 2e8f0b10d0 Bug 1403586 - Don't disble budget throttling due to gUM. r=smaug,padenot 2017-09-29 15:21:45 +02:00
Andreas Farre 2a3cdfc4f6 Bug 1393359 - Register active user media on top level window. r=smaug,jib 2017-09-04 14:40:30 +02:00
Andreas Farre dc0ff1e255 Bug 1393056 - Make it possible to count open WebSockets on the main thread. r=smaug 2017-09-01 10:36:49 +02:00
Andreas Farre 4409a06dbb Bug 1393764 - Reset execution budget if BudgetThrottlingEnabled returns false. r=bkelly
When BudgetThrottlingEnabled transitions from true to false, the
execution budget can be negative which will have the unfortunate
effect of limiting the number of timeouts run by
TimeoutManager::RunTimeout to zero. By resetting the execution budget
in UpdateBudget, when BudgetThrottlingEnabled returns false, we
prevent this loop from happening.
2017-08-29 16:44:24 +02:00
Andreas Farre c38df01a71 Bug 1391602 - Clamp execution budget to a minimum value. r=bkelly 2017-08-24 10:35:45 +02:00
Henri Sivonen 29fb7aad8e Bug 1378123 - Make inner window track whether there is an active PeerConnection. r=jib
MozReview-Commit-ID: 98Hwhnxtt1T

--HG--
extra : rebase_source : 3d7be906acec0d4262fae15d1755cdb7cfc71eb3
2017-08-04 13:28:15 +03:00
Kestrel 91cfa95229 Bug 918780 - Add new PopupControlState for permitting file/color picker popup regardless of dom_allowed_events. r=smaug
MozReview-Commit-ID: 1GbjQ6IkMsv

--HG--
extra : rebase_source : 4ea11b78007d9ab67a932536843b3e12175732b3
2016-04-24 04:49:00 +01:00
Andreas Farre 8378e81e6d Bug 1385238 - Reset execution budget when background state changes. r=bkelly 2017-07-28 09:31:00 -04:00
Bevis Tseng 95b18d794e Bug 1382172 - Name nsITimerCallback instances in native implementation. r=billm
--HG--
extra : rebase_source : 84de1abfcc30a6964144c2e6718a508c71027b65
2017-07-27 02:18:20 +08:00
Andreas Farre 4a297f87de Bug 1382254 - Only disallow budget throttling. r=ehsan
Don't consider WebSockets, IndexedDB, etc when considering background
tabs for ordinary throttling since that makes us throttle way less
than we used to.
2017-07-26 13:37:08 +02:00
Bevis Tseng 0f4742a9bb Bug 1384037 - Label ThrottleTimeoutsCallback. r=billm
--HG--
extra : rebase_source : b6b5f38b4842b88f6c8d14fe99d762c3483306a0
2017-07-25 18:04:58 +08:00
Ben Kelly 08d429854a Bug 1378586 P5 Don't force setInterval() to a min 1ms delay. r=farre 2017-07-25 08:35:12 -07:00
Ben Kelly 90ef714043 Bug 1378586 P4 Clamp setInterval() based on nesting value instead of always. r=farre 2017-07-25 08:35:12 -07:00
Ben Kelly 50ec1a5f3e Bug 1378586 P2 Avoid Timeout mNestingLevel rollover by just limiting the value to the values we care about. r=farre 2017-07-25 08:35:12 -07:00
Ben Kelly 910b4f672b Bug 1378586 P1 Track the nesting level on interval Timeout objects. r=farre 2017-07-25 08:35:12 -07:00
Ben Kelly fd76c2a146 Bug 1378394 P1 Calculate next setInterval() time from start of previous callback. r=farre 2017-07-06 07:01:40 -07:00
Andreas Farre 132ec026c3 Bug 1362322 - Throttle background timeouts using budget. r=bkelly
Deduct timeout execution time from a continuously regenerating
execution budget. Then throttle timeouts by using that budget in
TimeoutManager::MinSchedulingDelay to adjust the minimum value if
the budget is negative. The minimum value is adjusted to be a
value where the budget would have regenerated to be +0 ms.

The execution budget is clamped by values in ms defined in prefs:

* dom.timeout.background_throttling_max_budget: 50
* dom.timeout.foreground_throttling_max_budget: -1

A value equal or less than 0 means that the budget is infinite.

The regeneration rate can be controlled by the following prefs:

* dom.timeout.background_budget_regeneration_rate
* dom.timeout.foreground_budget_regeneration_rate

one each for foreground and background throttling.

To not starve timeouts indefinitely we clamp the minimum delay using
the pref:

* dom.timeout.budget_throttling_max_delay: 15000

The feature is behind the pref:

* dom.timeout.enable_budget_timer_throttling
2017-07-02 18:02:38 +02:00
Ben Kelly 8878d13ff4 Bug 1375287 Make TimeoutManager use a pref cache variable for dom.disable_open_click_delay. r=ehsan 2017-06-23 07:03:30 -07:00
Andreas Farre 97fadb7f9e Bug 1373536 - Clean up static API of TimeoutBudgetManager. r=smaug
--HG--
extra : rebase_source : aaaf54c48d480473569bdc87c58bd1c1d88966fc
2017-06-19 10:11:47 +02:00
Andreas Farre 8d5f7ca0b5 Bug 1373536 - Move TimeoutBudgetManager to its own file. r=bkelly
--HG--
extra : rebase_source : bde692176b4cf01dd6d6aaf167a91acf6c92e504
2017-06-16 09:17:09 +02:00
Andreas Farre 4b620e2aca Bug 1373536 - Unify execution measurements. r=bkelly
Expose the utility framework for computing runnable execution time for
telemetry to be able to use it for managing budget times.

--HG--
extra : rebase_source : c7aba3d039116ed10597e7b58e2c6e7911cb493d
2017-05-30 13:08:11 +02:00
Sebastian Hengst f38c7cdfa2 Backed out changeset 10676fd9e6ad (bug 1373536) for failing asan-fuzzing at dom/base/TimeoutHandler.h:26 with unknown type name 'NS_DECL_CYCLE_COLLECTION_CLASS' and more. r=backout 2017-06-20 17:47:54 +02:00
Sebastian Hengst d569b67fe6 Backed out changeset 5bde0b2dd768 (bug 1373536) 2017-06-20 17:46:22 +02:00
Sebastian Hengst 9e2c8a5ab0 Backed out changeset d377000dbcc9 (bug 1373536) 2017-06-20 17:46:18 +02:00
Andreas Farre 7525173e5b Bug 1373536 - Clean up static API of TimeoutBudgetManager. r=smaug 2017-06-20 00:40:00 +02:00
Andreas Farre 3739a32604 Bug 1373536 - Move TimeoutBudgetManager to its own file. r=bkelly 2017-06-19 01:18:00 +02:00
Andreas Farre 094c0d5ecd Bug 1373536 - Unify execution measurements. r=bkelly
Expose the utility framework for computing runnable execution time for
telemetry to be able to use it for managing budget times.
2017-06-16 07:40:00 +02:00
Ben Kelly 4deac3f186 Bug 1371787 P8 Change Timeout::mInterval member to a TimeDuration. r=ehsan 2017-06-15 17:30:48 -07:00
Ben Kelly 310e665654 Bug 1371787 P7 Make CalculateDelay() return a TimeDuration. r=ehsan 2017-06-15 17:30:48 -07:00
Ben Kelly 36211ea11b Bug 1371787 P6 Move the std::max() calculation into DOMMinTimeoutValue() and rename the method to CalculateDelay(). r=ehsan 2017-06-15 17:30:47 -07:00
Ben Kelly a0d3a469e4 Bug 1371787 P5 Move the Timeout conditional checking into DOMMinTimeoutValue(). r=ehsan 2017-06-15 17:30:47 -07:00
Ben Kelly a720c757a3 Bug 1371787 P4 Pass Timeout to DOMMinTimeoutValue(). r=ehsan 2017-06-15 17:30:47 -07:00
Ben Kelly 9e7089aee3 Bug 1371787 P3 Move some Timeout initialization earlier. r=ehsan 2017-06-15 17:30:47 -07:00
Ben Kelly 36f2e5562d Bug 1371787 P2 Don't adjust Timeout::When() values in TimeoutManager::Resume(). r=ehsan 2017-06-15 17:30:47 -07:00
Ben Kelly f4263c76a4 Bug 1371787 P1 Rename TimeoutManager "min timeout" values to "min clamp timeout" for clarity. r=ehsan 2017-06-15 17:30:47 -07:00
Ben Kelly a3c8156b38 Bug 1371664 P4 Remove old TimeoutManager code that adjusted Timeout::When() while in background. r=ehsan 2017-06-13 18:08:28 -07:00
Ben Kelly 2771b377cb Bug 1371664 P3 Pass a minimum delay to TimeoutExecutor::MaybeSchedule() based on TimeoutManager::IsBackground(). r=ehsan 2017-06-13 18:08:27 -07:00
Ben Kelly d959a50dfa Bug 1371664 P2 Make nsGlobalWindow::SetIsBackground() call new TimeoutManager::UpdateBackgroundState(). r=ehsan 2017-06-13 18:08:27 -07:00
Ben Kelly b0069d1478 Bug 1371020 P3 Cleanup some IsFrozen()/IsSuspended() checking in TimeoutManager. r=ehsan 2017-06-08 19:13:37 -07:00
Ben Kelly f120eee48f Bug 1371020 P2 Avoid scheduling TimeoutExecutor if the window becomes suspended in RunTimeout. r=ehsan 2017-06-08 19:13:37 -07:00
Ben Kelly cef34aad9d Bug 1371020 P1 Avoid rescheduling the TimeoutExecutor in ClearTimeout() in some cases. r=ehsan 2017-06-08 19:13:36 -07:00
Ben Kelly 89441f5ad6 Bug 1370537 P2 Remove TimeoutManager::RunTimeout()'s last expired timeout reference. r=ehsan 2017-06-08 05:51:59 -07:00
Ben Kelly f323cc363c Bug 1370537 P1 Stop iterating in TimeoutManager::RunTimeout() when we see an invalid firing ID. r=ehsan 2017-06-08 05:51:58 -07:00
Ben Kelly cf2f97c065 Bug 1370025 P5 Remove the old TimeoutManager insertion point logic. r=ehsan 2017-06-05 12:42:33 -07:00
Ben Kelly c2b540895d Bug 1370025 P4 Use FiringId validity in TimeoutManager::Timeouts::Insert() and ::ResetTimersForThrottleReduction(). r=ehsan 2017-06-05 12:42:33 -07:00
Ben Kelly 1cacde3284 Bug 1370025 P3 Give the Timeouts structure a reference back to its owning TimeoutManager. r=ehsan 2017-06-05 12:42:33 -07:00