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

Side by Side Diff: webrtc/base/messagequeue.cc

Issue 1932753002: Add tracing to MessageQueue::Dispatch. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2004 The WebRTC Project Authors. All rights reserved. 2 * Copyright 2004 The WebRTC Project Authors. All rights reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 #include <algorithm> 10 #include <algorithm>
11 11
12 #include "webrtc/base/checks.h" 12 #include "webrtc/base/checks.h"
13 #include "webrtc/base/common.h" 13 #include "webrtc/base/common.h"
14 #include "webrtc/base/logging.h" 14 #include "webrtc/base/logging.h"
15 #include "webrtc/base/messagequeue.h" 15 #include "webrtc/base/messagequeue.h"
16 #include "webrtc/base/trace_event.h"
16 17
17 namespace rtc { 18 namespace rtc {
18 19
19 const uint32_t kMaxMsgLatency = 150; // 150 ms 20 const uint32_t kMaxMsgLatency = 150; // 150 ms
20 21
21 //------------------------------------------------------------------ 22 //------------------------------------------------------------------
22 // MessageQueueManager 23 // MessageQueueManager
23 24
24 MessageQueueManager* MessageQueueManager::instance_ = NULL; 25 MessageQueueManager* MessageQueueManager::instance_ = NULL;
25 26
(...skipping 408 matching lines...) Expand 10 before | Expand all | Expand 10 after
434 } 435 }
435 } else { 436 } else {
436 *new_end++ = *it; 437 *new_end++ = *it;
437 } 438 }
438 } 439 }
439 dmsgq_.container().erase(new_end, dmsgq_.container().end()); 440 dmsgq_.container().erase(new_end, dmsgq_.container().end());
440 dmsgq_.reheap(); 441 dmsgq_.reheap();
441 } 442 }
442 443
443 void MessageQueue::Dispatch(Message *pmsg) { 444 void MessageQueue::Dispatch(Message *pmsg) {
445 TRACE_EVENT0("webrtc", "MessageQueue::Dispatch");
444 pmsg->phandler->OnMessage(pmsg); 446 pmsg->phandler->OnMessage(pmsg);
445 } 447 }
446 448
447 } // namespace rtc 449 } // namespace rtc
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698