2010-02-04 01:52:04 +07:00
|
|
|
#ifndef PERF_BUILD_ID_H_
|
|
|
|
#define PERF_BUILD_ID_H_ 1
|
|
|
|
|
2015-07-15 16:14:28 +07:00
|
|
|
#define BUILD_ID_SIZE 20
|
|
|
|
#define SBUILD_ID_SIZE (BUILD_ID_SIZE * 2 + 1)
|
2012-10-28 04:18:29 +07:00
|
|
|
|
|
|
|
#include "tool.h"
|
2015-02-27 11:50:26 +07:00
|
|
|
#include "strlist.h"
|
2014-04-26 02:31:02 +07:00
|
|
|
#include <linux/types.h>
|
2010-02-04 01:52:04 +07:00
|
|
|
|
2011-11-28 17:30:20 +07:00
|
|
|
extern struct perf_tool build_id__mark_dso_hit_ops;
|
2012-10-28 04:18:29 +07:00
|
|
|
struct dso;
|
2010-02-04 01:52:04 +07:00
|
|
|
|
2012-10-28 04:18:28 +07:00
|
|
|
int build_id__sprintf(const u8 *build_id, int len, char *bf);
|
2015-08-15 18:42:59 +07:00
|
|
|
int sysfs__sprintf_build_id(const char *root_dir, char *sbuild_id);
|
|
|
|
int filename__sprintf_build_id(const char *pathname, char *sbuild_id);
|
|
|
|
|
2013-12-11 01:46:29 +07:00
|
|
|
char *dso__build_id_filename(const struct dso *dso, char *bf, size_t size);
|
2010-05-20 22:15:33 +07:00
|
|
|
|
2012-08-07 19:56:05 +07:00
|
|
|
int build_id__mark_dso_hit(struct perf_tool *tool, union perf_event *event,
|
|
|
|
struct perf_sample *sample, struct perf_evsel *evsel,
|
|
|
|
struct machine *machine);
|
2014-11-04 08:14:30 +07:00
|
|
|
|
|
|
|
int dsos__hit_all(struct perf_session *session);
|
|
|
|
|
|
|
|
bool perf_session__read_build_ids(struct perf_session *session, bool with_hits);
|
|
|
|
int perf_session__write_buildid_table(struct perf_session *session, int fd);
|
|
|
|
int perf_session__cache_build_ids(struct perf_session *session);
|
|
|
|
|
2015-02-27 11:50:26 +07:00
|
|
|
int build_id_cache__list_build_ids(const char *pathname,
|
|
|
|
struct strlist **result);
|
2015-02-26 13:54:40 +07:00
|
|
|
bool build_id_cache__cached(const char *sbuild_id);
|
2015-02-10 16:18:51 +07:00
|
|
|
int build_id_cache__add_s(const char *sbuild_id,
|
2014-11-04 08:14:30 +07:00
|
|
|
const char *name, bool is_kallsyms, bool is_vdso);
|
2015-02-10 16:18:51 +07:00
|
|
|
int build_id_cache__remove_s(const char *sbuild_id);
|
2014-11-07 20:57:56 +07:00
|
|
|
void disable_buildid_cache(void);
|
2014-11-04 08:14:30 +07:00
|
|
|
|
2010-02-04 01:52:04 +07:00
|
|
|
#endif
|