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

Issue 572763003: Fix logic on high Windows resolution timer and have two possible period values for timeBeginPeriod … (Closed)

Created:
6 years, 3 months ago by cpu_(ooo_6.6-7.5)
Modified:
6 years, 3 months ago
Reviewers:
CC:
chromium-reviews, erikwright+watch_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@2125
Project:
chromium
Visibility:
Public.

Description

Fix logic on high Windows resolution timer and have two possible period values for timeBeginPeriod and timeEndPeriod. (merging to branch) Currently while on battery we disable calls to timeBeginPeriod which make the windows timers have 15ms resolution. This change makes it so when EnableHighResolutionTimer(true) which is on AC power the timer is 1ms and EnableHighResolutionTimer(false) is 4ms. This should provide significant power savings while meeting some timer resolution requirements needed by the GPU compositor. But also this CL fixes the following: EnableHighResolutionTimer() and ActivateHighResolutionTimer() are pretty broken. This CL fixes most issues: 1- The existing logic fails to account that EnableHighResolutionTimer can be called while the browser is running 2- All related functions need to be thread safe. 3- ActivateHighResolutionTimer was buggy. BUG=153139 Review URL: https://codereview.chromium.org/489793003 Cr-Commit-Position: refs/heads/master@{#292094} (cherry picked from commit be8f40e67f300e9452cfabb3ad594d907cfaa947) Committed: https://chromium.googlesource.com/chromium/src/+/08b216ce0ab5e000d2425e472ee009dbb9c7d79a

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+59 lines, -64 lines) Patch
M base/time/time.h View 2 chunks +1 line, -17 lines 0 comments Download
M base/time/time_win.cc View 4 chunks +46 lines, -32 lines 0 comments Download
M base/timer/hi_res_timer_manager_unittest.cc View 2 chunks +12 lines, -15 lines 0 comments Download

Messages

Total messages: 1 (0 generated)
cpu_(ooo_6.6-7.5)
6 years, 3 months ago (2014-09-16 01:30:54 UTC) #1
Message was sent while issue was closed.
Committed patchset #1 (id:1) manually as 08b216c.

Powered by Google App Engine
This is Rietveld 408576698