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

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

Issue 2782083003: Clean up some Mac memory code. (Closed)
Patch Set: Update comment. Created 3 years, 8 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_mac.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) 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 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
56 // priv: Pages mapped only by this process. 56 // priv: Pages mapped only by this process.
57 // shared: PSS or 0 if the kernel doesn't support this. 57 // shared: PSS or 0 if the kernel doesn't support this.
58 // shareable: 0 58 // shareable: 0
59 59
60 // On ChromeOS: 60 // On ChromeOS:
61 // priv: Pages mapped only by this process. 61 // priv: Pages mapped only by this process.
62 // shared: PSS or 0 if the kernel doesn't support this. 62 // shared: PSS or 0 if the kernel doesn't support this.
63 // shareable: 0 63 // shareable: 0
64 // swapped Pages swapped out to zram. 64 // swapped Pages swapped out to zram.
65 // 65 //
66 // On OS X: TODO(thakis): Revise. 66 // On macOS:
67 // priv: Memory. 67 // priv: Resident size (RSS) including shared memory. Warning: This
68 // does not include compressed size and does not always
69 // accurately account for shared memory due to things like
70 // copy-on-write. TODO(erikchen): Revamp this with something
71 // more accurate.
68 // shared: 0 72 // shared: 0
69 // shareable: 0 73 // shareable: 0
70 // 74 //
71 struct WorkingSetKBytes { 75 struct WorkingSetKBytes {
72 WorkingSetKBytes() : priv(0), shareable(0), shared(0) {} 76 WorkingSetKBytes() : priv(0), shareable(0), shared(0) {}
73 size_t priv; 77 size_t priv;
74 size_t shareable; 78 size_t shareable;
75 size_t shared; 79 size_t shared;
76 #if defined(OS_CHROMEOS) 80 #if defined(OS_CHROMEOS)
77 size_t swapped; 81 size_t swapped;
(...skipping 381 matching lines...) Expand 10 before | Expand all | Expand 10 after
459 SystemDiskInfo disk_info_; 463 SystemDiskInfo disk_info_;
460 #endif 464 #endif
461 #if defined(OS_CHROMEOS) 465 #if defined(OS_CHROMEOS)
462 SwapInfo swap_info_; 466 SwapInfo swap_info_;
463 #endif 467 #endif
464 }; 468 };
465 469
466 } // namespace base 470 } // namespace base
467 471
468 #endif // BASE_PROCESS_PROCESS_METRICS_H_ 472 #endif // BASE_PROCESS_PROCESS_METRICS_H_
OLDNEW
« no previous file with comments | « no previous file | base/process/process_metrics_mac.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698