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

Side by Side Diff: chrome/browser/memory_details_linux.cc

Issue 823533004: Move memory histograms generation to MetricsMemoryDetails. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Better class comment. Created 5 years, 11 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 | « chrome/browser/memory_details_browsertest.cc ('k') | chrome/browser/memory_details_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) 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 "chrome/browser/memory_details.h" 5 #include "chrome/browser/memory_details.h"
6 6
7 #include <sys/types.h> 7 #include <sys/types.h>
8 #include <unistd.h> 8 #include <unistd.h>
9 9
10 #include <map> 10 #include <map>
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
61 { "firefox-bin", FIREFOX }, 61 { "firefox-bin", FIREFOX },
62 { "iceweasel", ICEWEASEL }, 62 { "iceweasel", ICEWEASEL },
63 { "opera", OPERA }, 63 { "opera", OPERA },
64 { "konqueror", KONQUEROR }, 64 { "konqueror", KONQUEROR },
65 { "epiphany-browse", EPIPHANY }, 65 { "epiphany-browse", EPIPHANY },
66 { "epiphany", EPIPHANY }, 66 { "epiphany", EPIPHANY },
67 { "midori", MIDORI }, 67 { "midori", MIDORI },
68 { "", MAX_BROWSERS }, 68 { "", MAX_BROWSERS },
69 }; 69 };
70 70
71 MemoryDetails::MemoryDetails() 71 MemoryDetails::MemoryDetails() {
72 : user_metrics_mode_(UPDATE_USER_METRICS),
73 memory_growth_tracker_(NULL) {
74 } 72 }
75 73
76 ProcessData* MemoryDetails::ChromeBrowser() { 74 ProcessData* MemoryDetails::ChromeBrowser() {
77 return &process_data_[0]; 75 return &process_data_[0];
78 } 76 }
79 77
80 struct Process { 78 struct Process {
81 pid_t pid; 79 pid_t pid;
82 pid_t parent; 80 pid_t parent;
83 std::string name; 81 std::string name;
(...skipping 152 matching lines...) Expand 10 before | Expand all | Expand 10 after
236 234
237 #if defined(OS_CHROMEOS) 235 #if defined(OS_CHROMEOS)
238 base::GetSwapInfo(&swap_info_); 236 base::GetSwapInfo(&swap_info_);
239 #endif 237 #endif
240 238
241 // Finally return to the browser thread. 239 // Finally return to the browser thread.
242 BrowserThread::PostTask( 240 BrowserThread::PostTask(
243 BrowserThread::UI, FROM_HERE, 241 BrowserThread::UI, FROM_HERE,
244 base::Bind(&MemoryDetails::CollectChildInfoOnUIThread, this)); 242 base::Bind(&MemoryDetails::CollectChildInfoOnUIThread, this));
245 } 243 }
OLDNEW
« no previous file with comments | « chrome/browser/memory_details_browsertest.cc ('k') | chrome/browser/memory_details_mac.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698