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

Issue 22911026: Add instrumentation to the MessagePumpMac family of classes. (Closed)

Created:
7 years, 4 months ago by Robert Sesek
Modified:
7 years, 3 months ago
CC:
chromium-reviews, erikwright+watch_chromium.org, sadrul
Visibility:
Public.

Description

Add instrumentation to the MessagePumpMac family of classes. This adds UMA-uploaded histograms of sampling intervals for key points of data: * Total time spent in a CFRunLoop * Total time waiting in CFRunLoop * Total time servicing MessagePump::Delegate (the MessageLoop) * The MessageLoop queue size and queueing delay before servicing It adds 1 second sampling for 15 seconds at startup, only for the main thread (NSApplication-based) run loops. The data will be used to determine if adding scheduling-like behavior to the MessagePump will result in more efficient processing of the MessageLoop work. An unforunate side effect of this change is exposing another method on the MessagePump::Delegate interface, but there does not appear to be a better way to do this. BUG=264886 R=jar@chromium.org, mark@chromium.org Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=221427

Patch Set 1 #

Patch Set 2 : iOS compile #

Total comments: 11

Patch Set 3 : Address comments #

Total comments: 4

Patch Set 4 : More comments from mark #

Total comments: 16

Patch Set 5 : Address some comments from jar #

Total comments: 4

Patch Set 6 : Rebase #

Patch Set 7 : Add caveat #

Unified diffs Side-by-side diffs Delta from patch set Stats (+313 lines, -15 lines) Patch
M base/message_loop/message_loop.h View 1 chunk +2 lines, -0 lines 0 comments Download
M base/message_loop/message_loop.cc View 1 2 3 4 5 1 chunk +14 lines, -0 lines 0 comments Download
M base/message_loop/message_pump.h View 1 2 3 4 5 6 2 chunks +15 lines, -0 lines 0 comments Download
M base/message_loop/message_pump_mac.h View 1 2 3 4 5 chunks +15 lines, -7 lines 0 comments Download
M base/message_loop/message_pump_mac.mm View 1 2 3 4 5 12 chunks +267 lines, -8 lines 0 comments Download

Messages

Total messages: 21 (0 generated)
Robert Sesek
mark@ for initial review. I'll probably add darin@ and jar@ for followup.
7 years, 4 months ago (2013-08-20 22:18:37 UTC) #1
Mark Mentovai
https://codereview.chromium.org/22911026/diff/6001/base/message_loop/message_pump_mac.mm File base/message_loop/message_pump_mac.mm (right): https://codereview.chromium.org/22911026/diff/6001/base/message_loop/message_pump_mac.mm#newcode161 base/message_loop/message_pump_mac.mm:161: for (HistogramEvent j = LOOP_CYCLE; j < QUEUE_SIZE; ++j) ...
7 years, 4 months ago (2013-08-20 22:44:34 UTC) #2
Robert Sesek
https://codereview.chromium.org/22911026/diff/6001/base/message_loop/message_pump_mac.mm File base/message_loop/message_pump_mac.mm (right): https://codereview.chromium.org/22911026/diff/6001/base/message_loop/message_pump_mac.mm#newcode161 base/message_loop/message_pump_mac.mm:161: for (HistogramEvent j = LOOP_CYCLE; j < QUEUE_SIZE; ++j) ...
7 years, 4 months ago (2013-08-22 17:49:15 UTC) #3
Mark Mentovai
This is pretty much LGTM now, but you still need to get at least jar’s ...
7 years, 4 months ago (2013-08-22 18:00:12 UTC) #4
Robert Sesek
+jar for my extensive use of histograms and another base/ reviwer https://codereview.chromium.org/22911026/diff/12001/base/message_loop/message_loop.cc File base/message_loop/message_loop.cc (right): ...
7 years, 4 months ago (2013-08-22 19:12:21 UTC) #5
jar (doing other things)
I'm not clear on where this whole investigation is going. Perhaps you can provide a ...
7 years, 4 months ago (2013-08-22 23:03:39 UTC) #6
Robert Sesek
On 2013/08/22 23:03:39, jar wrote: > I'm not clear on where this whole investigation is ...
7 years, 4 months ago (2013-08-23 16:58:24 UTC) #7
jar (doing other things)
On Fri, Aug 23, 2013 at 9:58 AM, <rsesek@chromium.org> wrote: > >> Have you looked ...
7 years, 4 months ago (2013-08-23 22:24:47 UTC) #8
Robert Sesek
On Fri, Aug 23, 2013 at 6:24 PM, Jim Roskind <jar@chromium.org> wrote: > On Fri, ...
7 years, 3 months ago (2013-08-26 16:21:58 UTC) #9
jar (doing other things)
https://codereview.chromium.org/22911026/diff/19001/base/message_loop/message_loop.cc File base/message_loop/message_loop.cc (right): https://codereview.chromium.org/22911026/diff/19001/base/message_loop/message_loop.cc#newcode669 base/message_loop/message_loop.cc:669: const PendingTask& next_to_run = work_queue_.front(); On 2013/08/23 16:58:24, rsesek ...
7 years, 3 months ago (2013-08-27 22:16:55 UTC) #10
jar (doing other things)
On Mon, Aug 26, 2013 at 9:21 AM, Robert Sesek <rsesek@chromium.org> wrote: > On Fri, ...
7 years, 3 months ago (2013-08-27 22:30:41 UTC) #11
Robert Sesek
On Tue, Aug 27, 2013 at 6:30 PM, Jim Roskind <jar@chromium.org> wrote: > On Mon, ...
7 years, 3 months ago (2013-08-27 23:54:53 UTC) #12
Ilya Sherman
A note from the sidelines: I think you're conflating about:profiler and about:tracing. about:tracing data is ...
7 years, 3 months ago (2013-08-27 23:57:58 UTC) #13
Robert Sesek
On Tue, Aug 27, 2013 at 7:57 PM, Ilya Sherman <isherman@chromium.org> wrote: > A note ...
7 years, 3 months ago (2013-08-28 00:00:41 UTC) #14
jar (doing other things)
Are we already placing an observer into the list just before and after each task ...
7 years, 3 months ago (2013-08-29 22:15:08 UTC) #15
Robert Sesek
https://codereview.chromium.org/22911026/diff/24001/base/message_loop/message_pump_mac.mm File base/message_loop/message_pump_mac.mm (right): https://codereview.chromium.org/22911026/diff/24001/base/message_loop/message_pump_mac.mm#newcode328 base/message_loop/message_pump_mac.mm:328: pre_wait_observer_ = CFRunLoopObserverCreate(NULL, // allocator On 2013/08/29 22:15:08, jar ...
7 years, 3 months ago (2013-08-30 16:25:07 UTC) #16
jar (doing other things)
On 2013/08/30 16:25:07, rsesek wrote: > https://codereview.chromium.org/22911026/diff/24001/base/message_loop/message_pump_mac.mm > File base/message_loop/message_pump_mac.mm (right): > > https://codereview.chromium.org/22911026/diff/24001/base/message_loop/message_pump_mac.mm#newcode328 > ...
7 years, 3 months ago (2013-08-30 16:41:57 UTC) #17
Robert Sesek
On 2013/08/30 16:41:57, jar wrote: > On 2013/08/30 16:25:07, rsesek wrote: > > > https://codereview.chromium.org/22911026/diff/24001/base/message_loop/message_pump_mac.mm ...
7 years, 3 months ago (2013-08-30 18:00:52 UTC) #18
jar (doing other things)
Please correct the comment (nit) listed below, or explain why there isn't a factor of ...
7 years, 3 months ago (2013-09-04 01:20:16 UTC) #19
Robert Sesek
On 2013/09/04 01:20:16, jar wrote: > As a general comment on the goal: IMO, when ...
7 years, 3 months ago (2013-09-05 14:40:49 UTC) #20
Robert Sesek
7 years, 3 months ago (2013-09-05 14:53:32 UTC) #21
Message was sent while issue was closed.
Committed patchset #7 manually as r221427 (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698