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

Side by Side Diff: chrome/test/chrome_process_util.h

Issue 504068: Revert 34994, maybe it regressed startup perf - Fix cpu/memory measurements o... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 11 years 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 | « chrome/common/mach_ipc_mac.mm ('k') | webkit/glue/webkitclient_impl.cc » ('j') | 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) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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 #ifndef CHROME_TEST_CHROME_PROCESS_UTIL_H_ 5 #ifndef CHROME_TEST_CHROME_PROCESS_UTIL_H_
6 #define CHROME_TEST_CHROME_PROCESS_UTIL_H_ 6 #define CHROME_TEST_CHROME_PROCESS_UTIL_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/file_path.h" 10 #include "base/file_path.h"
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 } 50 }
51 51
52 bool GetIOCounters(IoCounters* io_counters) { 52 bool GetIOCounters(IoCounters* io_counters) {
53 return process_metrics_->GetIOCounters(io_counters); 53 return process_metrics_->GetIOCounters(io_counters);
54 } 54 }
55 55
56 base::ProcessHandle process_handle_; 56 base::ProcessHandle process_handle_;
57 57
58 private: 58 private:
59 explicit ChromeTestProcessMetrics(base::ProcessHandle process) { 59 explicit ChromeTestProcessMetrics(base::ProcessHandle process) {
60 process_metrics_.reset( 60 process_metrics_.reset(base::ProcessMetrics::CreateProcessMetrics(process));
61 #if !defined(OS_MACOSX)
62 base::ProcessMetrics::CreateProcessMetrics(process));
63 #else
64 base::ProcessMetrics::CreateProcessMetrics(process, NULL));
65 #endif
66 process_handle_ = process; 61 process_handle_ = process;
67 } 62 }
68 63
69 scoped_ptr<base::ProcessMetrics> process_metrics_; 64 scoped_ptr<base::ProcessMetrics> process_metrics_;
70 65
71 DISALLOW_COPY_AND_ASSIGN(ChromeTestProcessMetrics); 66 DISALLOW_COPY_AND_ASSIGN(ChromeTestProcessMetrics);
72 }; 67 };
73 68
74 #if defined(OS_MACOSX) 69 #if defined(OS_MACOSX)
75 70
(...skipping 14 matching lines...) Expand all
90 85
91 typedef std::vector<MacChromeProcessInfo> MacChromeProcessInfoList; 86 typedef std::vector<MacChromeProcessInfo> MacChromeProcessInfoList;
92 87
93 // Any ProcessId that info can't be found for will be left out. 88 // Any ProcessId that info can't be found for will be left out.
94 MacChromeProcessInfoList GetRunningMacProcessInfo( 89 MacChromeProcessInfoList GetRunningMacProcessInfo(
95 const ChromeProcessList &process_list); 90 const ChromeProcessList &process_list);
96 91
97 #endif // defined(OS_MACOSX) 92 #endif // defined(OS_MACOSX)
98 93
99 #endif // CHROME_TEST_CHROME_PROCESS_UTIL_H_ 94 #endif // CHROME_TEST_CHROME_PROCESS_UTIL_H_
OLDNEW
« no previous file with comments | « chrome/common/mach_ipc_mac.mm ('k') | webkit/glue/webkitclient_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698