capture: add pid-root frame type

While I'm not thrilled to add new frame types for every sort of thing, I
think having this will be relatively useful so we can improve decoding
operations.

This adds SysprofCapturePidRoot which lets us specify a root directory
on the host system for which is the real root (/) of the PID. This can
be useful when reconstructing overlays for containers and you need to
direct access to alternate roots.

The layer gives us some ability to try to deal with overlayfs, albeit at
a very rudimentary level. In most cases I anticipate we just deal with
the main root and ignore overlays until necessary.
This commit is contained in:
Christian Hergert
2021-02-24 17:50:36 -08:00
parent ff22417de9
commit 4758fb42ce
8 changed files with 138 additions and 2 deletions

View File

@ -120,6 +120,8 @@ SYSPROF_AVAILABLE_IN_ALL
const SysprofCaptureFileChunk *sysprof_capture_reader_read_file (SysprofCaptureReader *self);
SYSPROF_AVAILABLE_IN_3_36
const SysprofCaptureAllocation *sysprof_capture_reader_read_allocation (SysprofCaptureReader *self);
SYSPROF_AVAILABLE_IN_3_40
const SysprofCapturePidRoot *sysprof_capture_reader_read_pid_root (SysprofCaptureReader *self);
SYSPROF_AVAILABLE_IN_ALL
bool sysprof_capture_reader_reset (SysprofCaptureReader *self);
SYSPROF_AVAILABLE_IN_ALL