class StarnixCaptureStrategy

Defined at line 62 of file ../../src/developer/memory/metrics/capture_strategy.h

Extracts VMO information out of a process tree.

When a job contains a process named |process_name|, assume all processes within that job are

shared processes. This strategy attributes the VMOs of processes of these jobs as follows:

- Memory mapped to the private, restricted address space of a process is attributed to this

process;

- Memory mapped into the shared address space is attributed to the process |process_name|;

- Handles of unmapped VMOs are attributed to the process |process_name|;

- Handles of mapped VMOs are not taken into account (their mapping is).

For all other processes, this delegates to |BaseCaptureStrategy|.

Note: usage is similar to |BaseCaptureStrategy|; see its documentation.

Public Methods

void StarnixCaptureStrategy (std::string process_name)

Defined at line 87 of file ../../src/developer/memory/metrics/capture_strategy.cc

zx_status_t OnNewProcess (OS & os, Process process, zx::handle process_handle)

Defined at line 90 of file ../../src/developer/memory/metrics/capture_strategy.cc

zx::result<std::tuple<std::unordered_map<zx_koid_t, Process>, std::unordered_map<zx_koid_t, Vmo>>> Finalize (OS & os, StarnixCaptureStrategy && starnix_capture_strategy)

Defined at line 102 of file ../../src/developer/memory/metrics/capture_strategy.cc