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

Side by Side Diff: content/browser/histogram_controller.cc

Issue 10865002: Revert 150969 - Disable getting histogram data from child processes other than the renderer process… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 4 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 | Annotate | Revision Log
« no previous file with comments | « base/metrics/histogram_snapshot_manager.cc ('k') | 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 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/browser/histogram_controller.h" 5 #include "content/browser/histogram_controller.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/metrics/histogram.h" 8 #include "base/metrics/histogram.h"
9 #include "content/browser/histogram_subscriber.h" 9 #include "content/browser/histogram_subscriber.h"
10 #include "content/common/child_process_messages.h" 10 #include "content/common/child_process_messages.h"
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
63 const HistogramSubscriber* subscriber) { 63 const HistogramSubscriber* subscriber) {
64 DCHECK_EQ(subscriber_, subscriber); 64 DCHECK_EQ(subscriber_, subscriber);
65 subscriber_ = NULL; 65 subscriber_ = NULL;
66 } 66 }
67 67
68 void HistogramController::GetHistogramDataFromChildProcesses( 68 void HistogramController::GetHistogramDataFromChildProcesses(
69 int sequence_number) { 69 int sequence_number) {
70 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); 70 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
71 71
72 int pending_processes = 0; 72 int pending_processes = 0;
73 /* TODO(rtenneti): Enable collecting histogram from child processes.
74 for (BrowserChildProcessHostIterator iter; !iter.Done(); ++iter) { 73 for (BrowserChildProcessHostIterator iter; !iter.Done(); ++iter) {
75 ++pending_processes; 74 ++pending_processes;
76 if (!iter.Send(new ChildProcessMsg_GetChildHistogramData(sequence_number))) 75 if (!iter.Send(new ChildProcessMsg_GetChildHistogramData(sequence_number)))
77 --pending_processes; 76 --pending_processes;
78 } 77 }
79 */
80 78
81 BrowserThread::PostTask( 79 BrowserThread::PostTask(
82 BrowserThread::UI, 80 BrowserThread::UI,
83 FROM_HERE, 81 FROM_HERE,
84 base::Bind( 82 base::Bind(
85 &HistogramController::OnPendingProcesses, 83 &HistogramController::OnPendingProcesses,
86 base::Unretained(this), 84 base::Unretained(this),
87 sequence_number, 85 sequence_number,
88 pending_processes, 86 pending_processes,
89 true)); 87 true));
(...skipping 15 matching lines...) Expand all
105 103
106 BrowserThread::PostTask( 104 BrowserThread::PostTask(
107 BrowserThread::IO, 105 BrowserThread::IO,
108 FROM_HERE, 106 FROM_HERE,
109 base::Bind(&HistogramController::GetHistogramDataFromChildProcesses, 107 base::Bind(&HistogramController::GetHistogramDataFromChildProcesses,
110 base::Unretained(this), 108 base::Unretained(this),
111 sequence_number)); 109 sequence_number));
112 } 110 }
113 111
114 } // namespace content 112 } // namespace content
OLDNEW
« no previous file with comments | « base/metrics/histogram_snapshot_manager.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698