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

Issue 2752573002: Add BeginFrameLatency UMA (Closed)

Created:
3 years, 9 months ago by stanisc
Modified:
3 years, 9 months ago
CC:
chromium-reviews, cc-bugs_chromium.org, scheduler-bugs_chromium.org, asvitkine+watch_chromium.org
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Add BeginFrameLatency UMA The purpose of this UMA is to estimate v-sync latency i.e. the time from hardware v-sync which is represented by BeginFrame timestamp to the time BeginFrame is handled in Scheduler. This metric will be useful to understand impact of GPU V-sync which has been recently landed behind a feature switch. BUG=701181 CQ_INCLUDE_TRYBOTS=master.tryserver.blink:linux_trusty_blink_rel Review-Url: https://codereview.chromium.org/2752573002 Cr-Commit-Position: refs/heads/master@{#457190} Committed: https://chromium.googlesource.com/chromium/src/+/2b0182bca127df14fa7f3c8becb8ff682b3f1bd6

Patch Set 1 #

Total comments: 4

Patch Set 2 : Addressed CR feedback #

Total comments: 2

Patch Set 3 : Skip frames that originate from BeginFrameArgs::MISSED args #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+41 lines, -11 lines) Patch
M cc/scheduler/compositor_timing_history.h View 1 2 2 chunks +3 lines, -1 line 0 comments Download
M cc/scheduler/compositor_timing_history.cc View 1 2 6 chunks +19 lines, -1 line 2 comments Download
M cc/scheduler/compositor_timing_history_unittest.cc View 1 2 7 chunks +8 lines, -8 lines 0 comments Download
M cc/scheduler/scheduler.cc View 1 2 1 chunk +2 lines, -1 line 0 comments Download
M tools/metrics/histograms/histograms.xml View 1 2 chunks +9 lines, -0 lines 0 comments Download

Messages

Total messages: 32 (22 generated)
stanisc
ajuma@, please review cc\scheduler\compositor_timing_history.cc asvitkine@, please review tools\metrics\histograms\histograms.xml
3 years, 9 months ago (2017-03-14 00:13:10 UTC) #5
ajuma
lgtm https://codereview.chromium.org/2752573002/diff/1/cc/scheduler/compositor_timing_history.cc File cc/scheduler/compositor_timing_history.cc (right): https://codereview.chromium.org/2752573002/diff/1/cc/scheduler/compositor_timing_history.cc#newcode204 cc/scheduler/compositor_timing_history.cc:204: "Scheduling.Renderer.BeginMainFrameLatency", delta); Bikeshed: given the number of BeginFrame ...
3 years, 9 months ago (2017-03-14 14:54:10 UTC) #10
stanisc
Addressed feedback from ajuma@. +isherman@ for histograms.xml review (asvitkine@ seems to be busy). https://codereview.chromium.org/2752573002/diff/1/cc/scheduler/compositor_timing_history.cc File ...
3 years, 9 months ago (2017-03-14 21:25:40 UTC) #12
Ilya Sherman
Metrics LGTM https://codereview.chromium.org/2752573002/diff/20001/tools/metrics/histograms/histograms.xml File tools/metrics/histograms/histograms.xml (right): https://codereview.chromium.org/2752573002/diff/20001/tools/metrics/histograms/histograms.xml#newcode60636 tools/metrics/histograms/histograms.xml:60636: +<histogram name="Scheduling.VsyncToBeginMainFrameLatency2" units="microseconds"> Hmm, is it useful ...
3 years, 9 months ago (2017-03-14 21:32:11 UTC) #13
stanisc
https://codereview.chromium.org/2752573002/diff/20001/tools/metrics/histograms/histograms.xml File tools/metrics/histograms/histograms.xml (right): https://codereview.chromium.org/2752573002/diff/20001/tools/metrics/histograms/histograms.xml#newcode60636 tools/metrics/histograms/histograms.xml:60636: +<histogram name="Scheduling.VsyncToBeginMainFrameLatency2" units="microseconds"> On 2017/03/14 21:32:11, Ilya Sherman wrote: ...
3 years, 9 months ago (2017-03-14 21:43:34 UTC) #14
stanisc
Added a change suggested by brianderson@
3 years, 9 months ago (2017-03-15 01:05:37 UTC) #20
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2752573002/40001
3 years, 9 months ago (2017-03-15 20:26:23 UTC) #27
commit-bot: I haz the power
Committed patchset #3 (id:40001) as https://chromium.googlesource.com/chromium/src/+/2b0182bca127df14fa7f3c8becb8ff682b3f1bd6
3 years, 9 months ago (2017-03-15 20:35:26 UTC) #30
brianderson
https://codereview.chromium.org/2752573002/diff/40001/cc/scheduler/compositor_timing_history.cc File cc/scheduler/compositor_timing_history.cc (right): https://codereview.chromium.org/2752573002/diff/40001/cc/scheduler/compositor_timing_history.cc#newcode469 cc/scheduler/compositor_timing_history.cc:469: void CompositorTimingHistory::WillBeginImplFrame( You may want to track the latency ...
3 years, 9 months ago (2017-03-15 21:08:05 UTC) #31
stanisc
3 years, 9 months ago (2017-03-15 21:13:45 UTC) #32
Message was sent while issue was closed.
https://codereview.chromium.org/2752573002/diff/40001/cc/scheduler/compositor...
File cc/scheduler/compositor_timing_history.cc (right):

https://codereview.chromium.org/2752573002/diff/40001/cc/scheduler/compositor...
cc/scheduler/compositor_timing_history.cc:469: void
CompositorTimingHistory::WillBeginImplFrame(
On 2017/03/15 21:08:05, brianderson wrote:
> You may want to track the latency of this entry point instead (or also). 
> 
> The BeginMainFrame can be throttled because of back pressure, which will make
> latency look worse than it otherwise would.
> 
> BeginImplFrame always runs as soon as we get the BeginFrame message, so its
> latency will better reflect OS scheduling badness.

Thanks, I'll do an additional change to implement this suggestion. So this is
called before WillBeginMainFrame, right? Should I capture Now() here and use it
in WillBeginMainFrame to report the latency?

Powered by Google App Engine
This is Rietveld 408576698