Linux Perf
symbol-minimal.c File Reference
#include "symbol.h"
#include "util.h"
#include <errno.h>
#include <stdio.h>
#include <fcntl.h>
#include <string.h>
#include <byteswap.h>
#include <sys/stat.h>
Include dependency graph for symbol-minimal.c:

Go to the source code of this file.

Macros

#define NOTE_ALIGN(sz)   (((sz) + 3) & ~3)
 
#define NT_GNU_BUILD_ID   3
 

Functions

static bool check_need_swap (int file_endian)
 
static int read_build_id (void *note_data, size_t note_len, void *bf, size_t size, bool need_swap)
 
int filename__read_debuglink (const char *filename __maybe_unused, char *debuglink __maybe_unused, size_t size __maybe_unused)
 
int filename__read_build_id (const char *filename, void *bf, size_t size)
 
int sysfs__read_build_id (const char *filename, void *build_id, size_t size)
 
int symsrc__init (struct symsrc *ss, struct dso *dso, const char *name, enum dso_binary_type type)
 
bool symsrc__possibly_runtime (struct symsrc *ss __maybe_unused)
 
bool symsrc__has_symtab (struct symsrc *ss __maybe_unused)
 
void symsrc__destroy (struct symsrc *ss)
 
int dso__synthesize_plt_symbols (struct dso *dso __maybe_unused, struct symsrc *ss __maybe_unused)
 
static int fd__is_64_bit (int fd)
 
enum dso_type dso__type_fd (int fd)
 
int dso__load_sym (struct dso *dso, struct map *map __maybe_unused, struct symsrc *ss, struct symsrc *runtime_ss __maybe_unused, int kmodule __maybe_unused)
 
int file__read_maps (int fd __maybe_unused, bool exe __maybe_unused, mapfn_t mapfn __maybe_unused, void *data __maybe_unused, bool *is_64_bit __maybe_unused)
 
int kcore_extract__create (struct kcore_extract *kce __maybe_unused)
 
void kcore_extract__delete (struct kcore_extract *kce __maybe_unused)
 
int kcore_copy (const char *from_dir __maybe_unused, const char *to_dir __maybe_unused)
 
void symbol__elf_init (void)
 
char * dso__demangle_sym (struct dso *dso __maybe_unused, int kmodule __maybe_unused, const char *elf_name __maybe_unused)
 

Macro Definition Documentation

◆ NOTE_ALIGN

#define NOTE_ALIGN (   sz)    (((sz) + 3) & ~3)

Definition at line 27 of file symbol-minimal.c.

◆ NT_GNU_BUILD_ID

#define NT_GNU_BUILD_ID   3

Definition at line 29 of file symbol-minimal.c.

Function Documentation

◆ check_need_swap()

static bool check_need_swap ( int  file_endian)
static

Definition at line 13 of file symbol-minimal.c.

Here is the call graph for this function:

◆ dso__demangle_sym()

char* dso__demangle_sym ( struct dso *dso  __maybe_unused,
int kmodule  __maybe_unused,
const char *elf_name  __maybe_unused 
)

Definition at line 378 of file symbol-minimal.c.

◆ dso__load_sym()

int dso__load_sym ( struct dso dso,
struct map *map  __maybe_unused,
struct symsrc ss,
struct symsrc *runtime_ss  __maybe_unused,
int kmodule  __maybe_unused 
)

Definition at line 334 of file symbol-minimal.c.

Here is the call graph for this function:

◆ dso__synthesize_plt_symbols()

int dso__synthesize_plt_symbols ( struct dso *dso  __maybe_unused,
struct symsrc *ss  __maybe_unused 
)

Definition at line 290 of file symbol-minimal.c.

◆ dso__type_fd()

enum dso_type dso__type_fd ( int  fd)

Definition at line 313 of file symbol-minimal.c.

Here is the call graph for this function:

◆ fd__is_64_bit()

static int fd__is_64_bit ( int  fd)
static

Definition at line 296 of file symbol-minimal.c.

Here is the call graph for this function:

◆ file__read_maps()

int file__read_maps ( int fd  __maybe_unused,
bool exe  __maybe_unused,
mapfn_t mapfn  __maybe_unused,
void *data  __maybe_unused,
bool *is_64_bit  __maybe_unused 
)

Definition at line 352 of file symbol-minimal.c.

◆ filename__read_build_id()

int filename__read_build_id ( const char *  filename,
void *  bf,
size_t  size 
)

Definition at line 84 of file symbol-minimal.c.

Here is the call graph for this function:

◆ filename__read_debuglink()

int filename__read_debuglink ( const char *filename  __maybe_unused,
char *debuglink  __maybe_unused,
size_t size  __maybe_unused 
)

Definition at line 74 of file symbol-minimal.c.

◆ kcore_copy()

int kcore_copy ( const char *from_dir  __maybe_unused,
const char *to_dir  __maybe_unused 
)

Definition at line 368 of file symbol-minimal.c.

◆ kcore_extract__create()

int kcore_extract__create ( struct kcore_extract *kce  __maybe_unused)

Definition at line 359 of file symbol-minimal.c.

◆ kcore_extract__delete()

void kcore_extract__delete ( struct kcore_extract *kce  __maybe_unused)

Definition at line 364 of file symbol-minimal.c.

◆ read_build_id()

static int read_build_id ( void *  note_data,
size_t  note_len,
void *  bf,
size_t  size,
bool  need_swap 
)
static

Definition at line 31 of file symbol-minimal.c.

Here is the call graph for this function:

◆ symbol__elf_init()

void symbol__elf_init ( void  )

Definition at line 374 of file symbol-minimal.c.

◆ symsrc__destroy()

void symsrc__destroy ( struct symsrc ss)

Definition at line 284 of file symbol-minimal.c.

◆ symsrc__has_symtab()

bool symsrc__has_symtab ( struct symsrc *ss  __maybe_unused)

Definition at line 279 of file symbol-minimal.c.

◆ symsrc__init()

int symsrc__init ( struct symsrc ss,
struct dso dso,
const char *  name,
enum dso_binary_type  type 
)

Definition at line 251 of file symbol-minimal.c.

Here is the call graph for this function:

◆ symsrc__possibly_runtime()

bool symsrc__possibly_runtime ( struct symsrc *ss  __maybe_unused)

Definition at line 273 of file symbol-minimal.c.

◆ sysfs__read_build_id()

int sysfs__read_build_id ( const char *  filename,
void *  build_id,
size_t  size 
)

Definition at line 220 of file symbol-minimal.c.

Here is the call graph for this function: