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

Side by Side Diff: base/process/process_metrics.h

Issue 549753002: Cleanup bits of base::ProcessMetrics. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 3 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 | base/process/process_metrics.cc » ('j') | base/process/process_metrics.cc » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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 // This file contains routines for gathering resource statistics for processes 5 // This file contains routines for gathering resource statistics for processes
6 // running on the system. 6 // running on the system.
7 7
8 #ifndef BASE_PROCESS_PROCESS_METRICS_H_ 8 #ifndef BASE_PROCESS_PROCESS_METRICS_H_
9 #define BASE_PROCESS_PROCESS_METRICS_H_ 9 #define BASE_PROCESS_PROCESS_METRICS_H_
10 10
(...skipping 184 matching lines...) Expand 10 before | Expand all | Expand 10 after
195 195
196 ProcessHandle process_; 196 ProcessHandle process_;
197 197
198 int processor_count_; 198 int processor_count_;
199 199
200 // Used to store the previous times and CPU usage counts so we can 200 // Used to store the previous times and CPU usage counts so we can
201 // compute the CPU usage between calls. 201 // compute the CPU usage between calls.
202 TimeTicks last_cpu_time_; 202 TimeTicks last_cpu_time_;
203 int64 last_system_time_; 203 int64 last_system_time_;
204 204
205 #if defined(OS_MACOSX)
Lei Zhang 2014/09/06 09:31:57 OS X only variables
205 // Same thing for idle wakeups. 206 // Same thing for idle wakeups.
206 TimeTicks last_idle_wakeups_time_; 207 TimeTicks last_idle_wakeups_time_;
207 int64 last_absolute_idle_wakeups_; 208 uint64 last_absolute_idle_wakeups_;
Lei Zhang 2014/09/06 09:31:57 in process_metrics_mac.cc, the value from OS X is
209 #endif
208 210
209 #if !defined(OS_IOS) 211 #if !defined(OS_IOS)
210 #if defined(OS_MACOSX) 212 #if defined(OS_MACOSX)
211 // Queries the port provider if it's set. 213 // Queries the port provider if it's set.
212 mach_port_t TaskForPid(ProcessHandle process) const; 214 mach_port_t TaskForPid(ProcessHandle process) const;
213 215
214 PortProvider* port_provider_; 216 PortProvider* port_provider_;
215 #elif defined(OS_POSIX) 217 #elif defined(OS_POSIX)
216 // Jiffie count at the last_cpu_time_ we updated. 218 // Jiffie count at the last_cpu_time_ we updated.
217 int last_cpu_; 219 int last_cpu_;
(...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after
377 SystemDiskInfo disk_info_; 379 SystemDiskInfo disk_info_;
378 #endif 380 #endif
379 #if defined(OS_CHROMEOS) 381 #if defined(OS_CHROMEOS)
380 SwapInfo swap_info_; 382 SwapInfo swap_info_;
381 #endif 383 #endif
382 }; 384 };
383 385
384 } // namespace base 386 } // namespace base
385 387
386 #endif // BASE_PROCESS_PROCESS_METRICS_H_ 388 #endif // BASE_PROCESS_PROCESS_METRICS_H_
OLDNEW
« no previous file with comments | « no previous file | base/process/process_metrics.cc » ('j') | base/process/process_metrics.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698