We would like to experiment with storing heap profiling data in a separate process. This will avoid perturbing the instrumented process as much and will allow additional capabilities.
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/4a5810c3e6b5834a2609bf5935c0d31506f813bf commit 4a5810c3e6b5834a2609bf5935c0d31506f813bf Author: brettw <brettw@chromium.org> Date: Thu Jun 15 01:34:07 2017 Add flags and skeleton for profiling process. This will be used for the out-of-process heap profiler. Currently it just checks for the new process type and returns success. BUG= 733336 Review-Url: https://codereview.chromium.org/2941823002 Cr-Commit-Position: refs/heads/master@{#479572} [modify] https://crrev.com/4a5810c3e6b5834a2609bf5935c0d31506f813bf/chrome/BUILD.gn [modify] https://crrev.com/4a5810c3e6b5834a2609bf5935c0d31506f813bf/chrome/app/DEPS [modify] https://crrev.com/4a5810c3e6b5834a2609bf5935c0d31506f813bf/chrome/app/chrome_main.cc [modify] https://crrev.com/4a5810c3e6b5834a2609bf5935c0d31506f813bf/chrome/common/BUILD.gn [modify] https://crrev.com/4a5810c3e6b5834a2609bf5935c0d31506f813bf/chrome/common/features.gni [add] https://crrev.com/4a5810c3e6b5834a2609bf5935c0d31506f813bf/chrome/profiling/BUILD.gn [add] https://crrev.com/4a5810c3e6b5834a2609bf5935c0d31506f813bf/chrome/profiling/README.md [add] https://crrev.com/4a5810c3e6b5834a2609bf5935c0d31506f813bf/chrome/profiling/profiling_main.cc [add] https://crrev.com/4a5810c3e6b5834a2609bf5935c0d31506f813bf/chrome/profiling/profiling_main.h
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/1664378033de651755a3b4e46ec9690600dc8873 commit 1664378033de651755a3b4e46ec9690600dc8873 Author: Brett Wilson <brettw@chromium.org> Date: Thu Jun 15 18:01:09 2017 Launch browser when --memlog is specified on the command line. This communicates a pipe name to the launched process which is propagated to child processes. It is not yet used. The current process topology is the profiling process launches the browser which then runs like normal. In a later pass I will change this to have the browser process launch the profiling process when the flag is set. I believe this topology will be required for certain platforms. But it will require more plumbing for "process hosts" and mojo pipes that will take more time and don't need to block the current work. BUG= 733336 R=ajwong@chromium.org, borisv@chromium.org Review-Url: https://codereview.chromium.org/2937133002 . Cr-Commit-Position: refs/heads/master@{#479754} [modify] https://crrev.com/1664378033de651755a3b4e46ec9690600dc8873/chrome/app/chrome_main.cc [modify] https://crrev.com/1664378033de651755a3b4e46ec9690600dc8873/chrome/browser/chrome_content_browser_client.cc [modify] https://crrev.com/1664378033de651755a3b4e46ec9690600dc8873/chrome/common/chrome_switches.cc [modify] https://crrev.com/1664378033de651755a3b4e46ec9690600dc8873/chrome/common/chrome_switches.h [modify] https://crrev.com/1664378033de651755a3b4e46ec9690600dc8873/chrome/profiling/BUILD.gn [add] https://crrev.com/1664378033de651755a3b4e46ec9690600dc8873/chrome/profiling/DEPS [add] https://crrev.com/1664378033de651755a3b4e46ec9690600dc8873/chrome/profiling/profiling_globals.cc [add] https://crrev.com/1664378033de651755a3b4e46ec9690600dc8873/chrome/profiling/profiling_globals.h [modify] https://crrev.com/1664378033de651755a3b4e46ec9690600dc8873/chrome/profiling/profiling_main.cc
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/32f79a03c84b1be1ab5f1216112a1658fd864a54 commit 32f79a03c84b1be1ab5f1216112a1658fd864a54 Author: brettw <brettw@chromium.org> Date: Fri Jun 16 02:30:53 2017 Add pipe implementation for OOP memory logging These pipes are not currently hooked up. The sender pipe just connects to a known Windows named pipe and has a send capability. The receiver has a server that waits on Windows I/O completion ports for connections, then associates those connections with a receiver pipe. We will investigate converting this to a Mojo EDK pipe in a second phase. The pipes will need very different implementations per-platform, but we won't need to switch them. As a result, I put the Windows implementation in _win.* files, but didn't do any virtual base classes or anything and just named the classes without the Win suffix. In my previous implementation I did some more separation that I didn't find gave any more flexibility. BUG= 733336 Review-Url: https://codereview.chromium.org/2940003002 Cr-Commit-Position: refs/heads/master@{#479927} [modify] https://crrev.com/32f79a03c84b1be1ab5f1216112a1658fd864a54/chrome/common/BUILD.gn [add] https://crrev.com/32f79a03c84b1be1ab5f1216112a1658fd864a54/chrome/common/profiling/BUILD.gn [add] https://crrev.com/32f79a03c84b1be1ab5f1216112a1658fd864a54/chrome/common/profiling/memlog_sender_pipe.h [add] https://crrev.com/32f79a03c84b1be1ab5f1216112a1658fd864a54/chrome/common/profiling/memlog_sender_pipe_win.cc [add] https://crrev.com/32f79a03c84b1be1ab5f1216112a1658fd864a54/chrome/common/profiling/memlog_sender_pipe_win.h [add] https://crrev.com/32f79a03c84b1be1ab5f1216112a1658fd864a54/chrome/common/profiling/memlog_stream.cc [add] https://crrev.com/32f79a03c84b1be1ab5f1216112a1658fd864a54/chrome/common/profiling/memlog_stream.h [modify] https://crrev.com/32f79a03c84b1be1ab5f1216112a1658fd864a54/chrome/profiling/BUILD.gn [add] https://crrev.com/32f79a03c84b1be1ab5f1216112a1658fd864a54/chrome/profiling/memlog_receiver_pipe_server_win.cc [add] https://crrev.com/32f79a03c84b1be1ab5f1216112a1658fd864a54/chrome/profiling/memlog_receiver_pipe_server_win.h [add] https://crrev.com/32f79a03c84b1be1ab5f1216112a1658fd864a54/chrome/profiling/memlog_receiver_pipe_win.cc [add] https://crrev.com/32f79a03c84b1be1ab5f1216112a1658fd864a54/chrome/profiling/memlog_receiver_pipe_win.h [add] https://crrev.com/32f79a03c84b1be1ab5f1216112a1658fd864a54/chrome/profiling/memlog_stream_receiver.h
Comment 1 by bugdroid1@chromium.org
, Jun 15 2017