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

Issue 177024: Linux: about:memory (Closed)

Created:
11 years, 3 months ago by agl
Modified:
9 years, 7 months ago
Reviewers:
Evan Martin
CC:
chromium-reviews_googlegroups.com
Visibility:
Public.

Description

Linux: about:memory (based on http://code.google.com/p/chromium/issues/detail?id=16251) Add about:memory support to Linux. Rather than try and copy the Windows output, we use a couple of metrics which make more sense on Linux: USS and PSS.

Patch Set 1 #

Patch Set 2 : ... #

Total comments: 24

Patch Set 3 : ... #

Patch Set 4 : ... #

Unified diffs Side-by-side diffs Delta from patch set Stats (+526 lines, -283 lines) Patch
M base/process_util.h View 1 2 2 chunks +9 lines, -0 lines 0 comments Download
M base/process_util_linux.cc View 1 2 1 chunk +4 lines, -5 lines 0 comments Download
M chrome/browser/browser_about_handler.cc View 1 2 1 chunk +3 lines, -3 lines 0 comments Download
M chrome/browser/browser_resources.grd View 1 2 1 chunk +9 lines, -1 line 0 comments Download
M chrome/browser/memory_details.h View 4 chunks +13 lines, -20 lines 0 comments Download
M chrome/browser/memory_details.cc View 1 2 3 8 chunks +35 lines, -129 lines 0 comments Download
A chrome/browser/memory_details_linux.cc View 1 2 1 chunk +258 lines, -0 lines 0 comments Download
A chrome/browser/memory_details_win.cc View 1 chunk +156 lines, -0 lines 0 comments Download
M chrome/browser/renderer_host/render_sandbox_host_linux.h View 2 chunks +2 lines, -0 lines 0 comments Download
M chrome/browser/renderer_host/render_sandbox_host_linux.cc View 1 chunk +2 lines, -2 lines 0 comments Download
M chrome/browser/resources/about_memory_linux.html View 10 chunks +19 lines, -122 lines 0 comments Download
M chrome/browser/zygote_host_linux.h View 2 chunks +5 lines, -0 lines 0 comments Download
M chrome/browser/zygote_host_linux.cc View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/chrome.gyp View 1 2 2 chunks +2 lines, -1 line 0 comments Download
M chrome/common/child_process_info.h View 1 chunk +2 lines, -0 lines 0 comments Download
M chrome/common/child_process_info.cc View 1 chunk +4 lines, -0 lines 0 comments Download
M chrome/common/temp_scaffolding_stubs.cc View 2 chunks +2 lines, -0 lines 0 comments Download

Messages

Total messages: 3 (0 generated)
agl
11 years, 3 months ago (2009-08-28 18:20:08 UTC) #1
Evan Martin
http://codereview.chromium.org/177024/diff/2001/2002 File base/process_util.h (right): http://codereview.chromium.org/177024/diff/2001/2002#newcode288 Line 288: // Working Set (resident) memory usage broken down ...
11 years, 3 months ago (2009-08-28 22:32:09 UTC) #2
agl
11 years, 3 months ago (2009-08-28 22:55:38 UTC) #3
http://codereview.chromium.org/177024/diff/2001/2002
File base/process_util.h (right):

http://codereview.chromium.org/177024/diff/2001/2002#newcode288
Line 288: // Working Set (resident) memory usage broken down by
On 2009/08/28 22:32:09, Evan Martin wrote:
> Mention this one is Windows-specific?

Done.

http://codereview.chromium.org/177024/diff/2001/2003
File base/process_util_linux.cc (right):

http://codereview.chromium.org/177024/diff/2001/2003#newcode298
Line 298: ws_usage->shared = 0;
On 2009/08/28 22:32:09, Evan Martin wrote:
> I have no ability to vouch for the correctness of this, so I will only note
that
> L296 has weird tabbing.

Done.

http://codereview.chromium.org/177024/diff/2001/2006
File chrome/browser/memory_details.cc (right):

http://codereview.chromium.org/177024/diff/2001/2006#newcode203
Line 203: // Other types ignored.
On 2009/08/28 22:32:09, Evan Martin wrote:
> Should this default be NOTREACHED() with the list of other types explicitly
> handled as cases where they are explicitly ignored?  I'm worried about
> overlooking new process types.

It shouldn't be UNREACHED unless we want to add new UMA types. I don't really
understand UMA and I don't know if one can just add new strings like that.

http://codereview.chromium.org/177024/diff/2001/2008
File chrome/browser/memory_details_linux.cc (right):

http://codereview.chromium.org/177024/diff/2001/2008#newcode47
Line 47: BrowserType browser; }
On 2009/08/28 22:32:09, Evan Martin wrote:
> this would be clearer if the } was at the beginning of L48 I think.

Done.

http://codereview.chromium.org/177024/diff/2001/2008#newcode173
Line 173: for (std::vector<Process>::const_iterator
On 2009/08/28 22:32:09, Evan Martin wrote:
> weird wrapping

agl standard wrapping.

http://codereview.chromium.org/177024/diff/2001/2008#newcode187
Line 187: std::vector<ProcessMemoryInformation> child_info) {
On 2009/08/28 22:32:09, Evan Martin wrote:
> const &

Actually no, it's a callback

http://codereview.chromium.org/177024/diff/2001/2008#newcode219
Line 219: browsers_found.insert(current->pid);
On 2009/08/28 22:32:09, Evan Martin wrote:
> You could just use this test on each process to decide whether it's a root,
> rather than attempting to find parents of processes like you currently do.

Done.

http://codereview.chromium.org/177024/diff/2001/2008#newcode238
Line 238: current_browser.process_name = L"chrome";
On 2009/08/28 22:32:09, Evan Martin wrote:
> is this gonna need to be "translated" for chromium?

Done.

http://codereview.chromium.org/177024/diff/2001/2015
File chrome/chrome.gyp (left):

http://codereview.chromium.org/177024/diff/2001/2015#oldcode2591
Line 2591: 'browser/memory_details.cc',
On 2009/08/28 22:32:09, Evan Martin wrote:
> do you still need this exclude on mac?

Yes I think so. We don't have the needed code for Mac.

Powered by Google App Engine
This is Rietveld 408576698