Linux Perf
|
#include <linux/refcount.h>
#include <linux/types.h>
#include <linux/rbtree.h>
#include <sys/types.h>
#include <stdbool.h>
#include "rwsem.h"
#include <linux/bitops.h>
#include "map.h"
#include "namespaces.h"
#include "build-id.h"
Go to the source code of this file.
Classes | |
struct | dso_cache |
struct | dsos |
struct | dso |
struct | kmod_path |
Macros | |
#define | DSO__SWAP(dso, type, val) |
#define | DSO__DATA_CACHE_SIZE 4096 |
#define | DSO__DATA_CACHE_MASK ~(DSO__DATA_CACHE_SIZE - 1) |
#define | dso__for_each_symbol(dso, pos, n) symbols__for_each_entry(&(dso)->symbols, pos, n) |
#define | dso__zput(dso) __dso__zput(&dso) |
#define | KMOD_DECOMP_NAME "/tmp/perf-kmod-XXXXXX" |
#define | KMOD_DECOMP_LEN sizeof(KMOD_DECOMP_NAME) |
#define | kmod_path__parse(__m, __p) __kmod_path__parse(__m, __p, false, false) |
#define | kmod_path__parse_name(__m, __p) __kmod_path__parse(__m, __p, true , false) |
#define | kmod_path__parse_ext(__m, __p) __kmod_path__parse(__m, __p, false, true) |
Functions | |
static void | dso__set_loaded (struct dso *dso) |
struct dso * | dso__new (const char *name) |
void | dso__delete (struct dso *dso) |
void | dso__set_short_name (struct dso *dso, const char *name, bool name_allocated) |
void | dso__set_long_name (struct dso *dso, const char *name, bool name_allocated) |
int | dso__name_len (const struct dso *dso) |
struct dso * | dso__get (struct dso *dso) |
void | dso__put (struct dso *dso) |
static void | __dso__zput (struct dso **dso) |
bool | dso__loaded (const struct dso *dso) |
static bool | dso__has_symbols (const struct dso *dso) |
bool | dso__sorted_by_name (const struct dso *dso) |
void | dso__set_sorted_by_name (struct dso *dso) |
void | dso__sort_by_name (struct dso *dso) |
void | dso__set_build_id (struct dso *dso, void *build_id) |
bool | dso__build_id_equal (const struct dso *dso, u8 *build_id) |
void | dso__read_running_kernel_build_id (struct dso *dso, struct machine *machine) |
int | dso__kernel_module_get_build_id (struct dso *dso, const char *root_dir) |
char | dso__symtab_origin (const struct dso *dso) |
int | dso__read_binary_type_filename (const struct dso *dso, enum dso_binary_type type, char *root_dir, char *filename, size_t size) |
bool | is_supported_compression (const char *ext) |
bool | is_kernel_module (const char *pathname, int cpumode) |
bool | decompress_to_file (const char *ext, const char *filename, int output_fd) |
bool | dso__needs_decompress (struct dso *dso) |
int | dso__decompress_kmodule_fd (struct dso *dso, const char *name) |
int | dso__decompress_kmodule_path (struct dso *dso, const char *name, char *pathname, size_t len) |
int | __kmod_path__parse (struct kmod_path *m, const char *path, bool alloc_name, bool alloc_ext) |
void | dso__set_module_info (struct dso *dso, struct kmod_path *m, struct machine *machine) |
int | dso__data_get_fd (struct dso *dso, struct machine *machine) |
void | dso__data_put_fd (struct dso *dso) |
void | dso__data_close (struct dso *dso) |
off_t | dso__data_size (struct dso *dso, struct machine *machine) |
ssize_t | dso__data_read_offset (struct dso *dso, struct machine *machine, u64 offset, u8 *data, ssize_t size) |
ssize_t | dso__data_read_addr (struct dso *dso, struct map *map, struct machine *machine, u64 addr, u8 *data, ssize_t size) |
bool | dso__data_status_seen (struct dso *dso, enum dso_data_status_seen by) |
struct map * | dso__new_map (const char *name) |
struct dso * | machine__findnew_kernel (struct machine *machine, const char *name, const char *short_name, int dso_type) |
void | __dsos__add (struct dsos *dsos, struct dso *dso) |
void | dsos__add (struct dsos *dsos, struct dso *dso) |
struct dso * | __dsos__addnew (struct dsos *dsos, const char *name) |
struct dso * | __dsos__find (struct dsos *dsos, const char *name, bool cmp_short) |
struct dso * | dsos__find (struct dsos *dsos, const char *name, bool cmp_short) |
struct dso * | __dsos__findnew (struct dsos *dsos, const char *name) |
struct dso * | dsos__findnew (struct dsos *dsos, const char *name) |
bool | __dsos__read_build_ids (struct list_head *head, bool with_hits) |
void | dso__reset_find_symbol_cache (struct dso *dso) |
size_t | __dsos__fprintf_buildid (struct list_head *head, FILE *fp, bool(skip)(struct dso *dso, int parm), int parm) |
size_t | __dsos__fprintf (struct list_head *head, FILE *fp) |
size_t | dso__fprintf_buildid (struct dso *dso, FILE *fp) |
size_t | dso__fprintf_symbols_by_name (struct dso *dso, FILE *fp) |
size_t | dso__fprintf (struct dso *dso, FILE *fp) |
static bool | dso__is_vmlinux (struct dso *dso) |
static bool | dso__is_kcore (struct dso *dso) |
static bool | dso__is_kallsyms (struct dso *dso) |
void | dso__free_a2l (struct dso *dso) |
enum dso_type | dso__type (struct dso *dso, struct machine *machine) |
int | dso__strerror_load (struct dso *dso, char *buf, size_t buflen) |
void | reset_fd_limit (void) |
#define DSO__DATA_CACHE_MASK ~(DSO__DATA_CACHE_SIZE - 1) |
#define dso__for_each_symbol | ( | dso, | |
pos, | |||
n | |||
) | symbols__for_each_entry(&(dso)->symbols, pos, n) |
#define DSO__SWAP | ( | dso, | |
type, | |||
val | |||
) |
#define dso__zput | ( | dso | ) | __dso__zput(&dso) |
#define KMOD_DECOMP_LEN sizeof(KMOD_DECOMP_NAME) |
#define kmod_path__parse | ( | __m, | |
__p | |||
) | __kmod_path__parse(__m, __p, false, false) |
#define kmod_path__parse_ext | ( | __m, | |
__p | |||
) | __kmod_path__parse(__m, __p, false, true) |
#define kmod_path__parse_name | ( | __m, | |
__p | |||
) | __kmod_path__parse(__m, __p, true , false) |
enum dso_binary_type |
enum dso_data_status |
enum dso_data_status_seen |
enum dso_kernel_type |
enum dso_load_errno |
enum dso_swap_type |
enum dso_type |
|
inlinestatic |
size_t __dsos__fprintf | ( | struct list_head * | head, |
FILE * | fp | ||
) |
bool __dsos__read_build_ids | ( | struct list_head * | head, |
bool | with_hits | ||
) |
int __kmod_path__parse | ( | struct kmod_path * | m, |
const char * | path, | ||
bool | alloc_name, | ||
bool | alloc_ext | ||
) |
bool decompress_to_file | ( | const char * | ext, |
const char * | filename, | ||
int | output_fd | ||
) |
bool dso__build_id_equal | ( | const struct dso * | dso, |
u8 * | build_id | ||
) |
void dso__data_close | ( | struct dso * | dso | ) |
dso__data_get_fd - Get dso's data file descriptor : dso object : machine object
External interface to find dso's file, open it and returns file descriptor. It should be paired with dso__data_put_fd() if it returns non-negative value.
Definition at line 678 of file dso.c.
void dso__data_put_fd | ( | struct dso * | dso | ) |
ssize_t dso__data_read_offset | ( | struct dso * | dso, |
struct machine * | machine, | ||
u64 | offset, | ||
u8 * | data, | ||
ssize_t | size | ||
) |
dso__data_read_offset - Read data from dso file offset : dso object : machine object : file offset : buffer to store data : size of the buffer
External interface to read data from dso file offset. Open dso data file and use cached_read to get the data.
Definition at line 986 of file dso.c.
bool dso__data_status_seen | ( | struct dso * | dso, |
enum dso_data_status_seen | by | ||
) |
int dso__decompress_kmodule_fd | ( | struct dso * | dso, |
const char * | name | ||
) |
int dso__decompress_kmodule_path | ( | struct dso * | dso, |
const char * | name, | ||
char * | pathname, | ||
size_t | len | ||
) |
void dso__delete | ( | struct dso * | dso | ) |
size_t dso__fprintf | ( | struct dso * | dso, |
FILE * | fp | ||
) |
size_t dso__fprintf_buildid | ( | struct dso * | dso, |
FILE * | fp | ||
) |
size_t dso__fprintf_symbols_by_name | ( | struct dso * | dso, |
FILE * | fp | ||
) |
Definition at line 60 of file symbol_fprintf.c.
void dso__free_a2l | ( | struct dso * | dso | ) |
|
inlinestatic |
|
inlinestatic |
int dso__kernel_module_get_build_id | ( | struct dso * | dso, |
const char * | root_dir | ||
) |
struct dso* dso__new | ( | const char * | name | ) |
struct map* dso__new_map | ( | const char * | name | ) |
void dso__put | ( | struct dso * | dso | ) |
int dso__read_binary_type_filename | ( | const struct dso * | dso, |
enum dso_binary_type | type, | ||
char * | root_dir, | ||
char * | filename, | ||
size_t | size | ||
) |
void dso__set_build_id | ( | struct dso * | dso, |
void * | build_id | ||
) |
|
inlinestatic |
void dso__set_long_name | ( | struct dso * | dso, |
const char * | name, | ||
bool | name_allocated | ||
) |
void dso__set_short_name | ( | struct dso * | dso, |
const char * | name, | ||
bool | name_allocated | ||
) |
void dso__sort_by_name | ( | struct dso * | dso | ) |
int dso__strerror_load | ( | struct dso * | dso, |
char * | buf, | ||
size_t | buflen | ||
) |