Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(8)

Issue 1751953002: [Cherrypick try #2] Fix computation of runtime for throttled tasks (Closed)

Created:
4 years, 9 months ago by alex clarke (OOO till 29th)
Modified:
4 years, 9 months ago
Reviewers:
Sami
CC:
chromium-reviews
Base URL:
https://chromium.googlesource.com/chromium/src.git@2623
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

[Cherrypick try #2] Fix computation of runtime for throttled tasks The computation of the delayed task runtime was computing the (virtual) TimeDomain's now + delay. That doesn't take into account the skew between the real time and the virtual time, which meant timers could run sooner than expected for background tabs. Timers associated with foreground tabs are unaffected. This patch makes the computation of delayed runtime the responsibility of the TimeDomain and introduces a ThrottledTimeDomain which computes the delayed runtime as realtime + delay. This means timers will no longer run sooner than expected. Under normal circumstancs this only timers whose delay modulo 1000ms is less than 100 ms are less likely to be affected. Timers whose whose delay modulo 1000ms is greater than 900 are highly likely to be affected (there's a good chance their delay was too small before). BUG=587074 Review URL: https://codereview.chromium.org/1718233002 Cr-Commit-Position: refs/heads/master@{#376993} (cherry picked from commit b56bbe4ce3e7276a130a00d83cf00e5672cd6be1) R=skyostil@chromium.org Committed: https://chromium.googlesource.com/chromium/src/+/30d9e26c8a397e07d6b2752b1e0ebee09fd8b0fd

Patch Set 1 #

Patch Set 2 : Fix a couple of merge issues. #

Patch Set 3 : Fix formatting #

Unified diffs Side-by-side diffs Delta from patch set Stats (+134 lines, -8 lines) Patch
M components/scheduler/base/real_time_domain.h View 1 chunk +2 lines, -0 lines 0 comments Download
M components/scheduler/base/real_time_domain.cc View 2 chunks +6 lines, -1 line 0 comments Download
M components/scheduler/base/task_queue_impl.cc View 1 2 1 chunk +5 lines, -2 lines 0 comments Download
M components/scheduler/base/time_domain.h View 1 chunk +7 lines, -0 lines 0 comments Download
M components/scheduler/base/time_domain_unittest.cc View 1 chunk +5 lines, -0 lines 0 comments Download
M components/scheduler/base/virtual_time_domain.h View 1 chunk +2 lines, -0 lines 0 comments Download
M components/scheduler/base/virtual_time_domain.cc View 1 2 1 chunk +6 lines, -0 lines 0 comments Download
A components/scheduler/renderer/throttled_time_domain.h View 1 chunk +34 lines, -0 lines 0 comments Download
A components/scheduler/renderer/throttled_time_domain.cc View 1 chunk +31 lines, -0 lines 0 comments Download
M components/scheduler/renderer/throttling_helper.h View 3 chunks +3 lines, -3 lines 0 comments Download
M components/scheduler/renderer/throttling_helper.cc View 2 chunks +2 lines, -2 lines 0 comments Download
M components/scheduler/renderer/throttling_helper_unittest.cc View 1 chunk +29 lines, -0 lines 0 comments Download
M components/scheduler/scheduler.gypi View 1 chunk +2 lines, -0 lines 0 comments Download

Messages

Total messages: 6 (4 generated)
Sami
lgtm (although looks like this could use a git cl format)
4 years, 9 months ago (2016-03-01 17:13:17 UTC) #2
alex clarke (OOO till 29th)
4 years, 9 months ago (2016-03-01 18:10:38 UTC) #6
Message was sent while issue was closed.
Committed patchset #3 (id:80001) manually as
30d9e26c8a397e07d6b2752b1e0ebee09fd8b0fd (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698