mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-23 06:15:38 +07:00
f6832e1720
'perf record' post-processes the event stream to create a list of build-ids for object files for which sample events have been recorded. That results in those object files being recorded in the build-id cache. In the case of VDSO, perf tools reads it from memory and copies it into a temporary file, which as decribed above, gets added to the build-id cache. Then when the perf.data file is processed by other tools, the build-id of VDSO is listed in the perf.data file and the VDSO can be read from the build-id cache. In that case the name of the map, the short name of the DSO, and the entry in the build-id cache are all "[vdso]". However, in the 64-bit case, there also can be 32-bit compatibility VDSOs. A previous patch added programs "perf-read-vdso32" and "perf read-vdsox32". This patch uses those programs to read the correct VDSO for a thread and create a temporary file just as for the 64-bit VDSO. The map name and the entry in the build-id cache are still "[vdso]" but the DSO short name becomes "[vdso32]" and "[vdsox32]" respectively. Signed-off-by: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Namhyung Kim <namhyung@gmail.com> Cc: Paul Mackerras <paulus@samba.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Link: http://lkml.kernel.org/r/1414061124-26830-16-git-send-email-adrian.hunter@intel.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
30 lines
588 B
C
30 lines
588 B
C
#ifndef __PERF_VDSO__
|
|
#define __PERF_VDSO__
|
|
|
|
#include <linux/types.h>
|
|
#include <string.h>
|
|
#include <stdbool.h>
|
|
|
|
#define VDSO__MAP_NAME "[vdso]"
|
|
|
|
#define DSO__NAME_VDSO "[vdso]"
|
|
#define DSO__NAME_VDSO32 "[vdso32]"
|
|
#define DSO__NAME_VDSOX32 "[vdsox32]"
|
|
|
|
static inline bool is_vdso_map(const char *filename)
|
|
{
|
|
return !strcmp(filename, VDSO__MAP_NAME);
|
|
}
|
|
|
|
struct dso;
|
|
|
|
bool dso__is_vdso(struct dso *dso);
|
|
|
|
struct machine;
|
|
struct thread;
|
|
|
|
struct dso *vdso__dso_findnew(struct machine *machine, struct thread *thread);
|
|
void vdso__exit(struct machine *machine);
|
|
|
|
#endif /* __PERF_VDSO__ */
|