Add memory size, build id, and debug link info to statedump and dl
authorAntoine Busque <abusque@efficios.com>
Thu, 2 Jul 2015 15:55:53 +0000 (11:55 -0400)
committerMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Sat, 29 Aug 2015 02:13:53 +0000 (22:13 -0400)
Implement a minimal ELF parser allowing to compute an executable's
in-memory size and to read its build id and debug link info, if any,
at runtime. This is performed during base address statedump, and on
dlopen when using the `liblttng-ust-dl.so` helper.

This adds a `memsz` field to `lttng_ust_statedump:soinfo` and
`lttng_ust_dl:dlopen`. Also adds two events to both providers,
`build_id` and `debug_link`, which are only traced when the
corresponding information is found in the executable file. They can be
matched with the corresponding `soinfo` or `dlopen` via the `baddr`
field shared amongst all the events. Build ID and debug link are
standard methods of identifying and retrieving debug information
corresponding to a specific version of an executable.

The fields `size` and `mtime` from the existing `soinfo` and `dlopen`
events have been removed as they provided no valuable information for
analysis, whereas build ID or debug link allow unambiguous retrieval
of the debug information, and the on-disk `size` is superseded by the
in-memory `memsz`.

Signed-off-by: Antoine Busque <abusque@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>

No differences found
This page took 0.033821 seconds and 4 git commands to generate.