Linux Perf
unwind-libdw.c File Reference
#include <linux/compiler.h>
#include <elfutils/libdw.h>
#include <elfutils/libdwfl.h>
#include <inttypes.h>
#include <errno.h>
#include "debug.h"
#include "unwind.h"
#include "unwind-libdw.h"
#include "machine.h"
#include "thread.h"
#include <linux/types.h>
#include "event.h"
#include "perf_regs.h"
#include "callchain.h"
#include "util.h"
Include dependency graph for unwind-libdw.c:

Go to the source code of this file.

Functions

static int __report_module (struct addr_location *al, u64 ip, struct unwind_info *ui)
 
static int report_module (u64 ip, struct unwind_info *ui)
 
static int entry (u64 ip, struct unwind_info *ui)
 
static pid_t next_thread (Dwfl *dwfl, void *arg, void **thread_argp)
 
static int access_dso_mem (struct unwind_info *ui, Dwarf_Addr addr, Dwarf_Word *data)
 
static bool memory_read (Dwfl *dwfl __maybe_unused, Dwarf_Addr addr, Dwarf_Word *result, void *arg)
 
static int frame_callback (Dwfl_Frame *state, void *arg)
 
int unwind__get_entries (unwind_entry_cb_t cb, void *arg, struct thread *thread, struct perf_sample *data, int max_stack)
 

Variables

static char * debuginfo_path
 
static const Dwfl_Callbacks offline_callbacks
 
static const Dwfl_Thread_Callbacks callbacks
 

Function Documentation

◆ __report_module()

static int __report_module ( struct addr_location al,
u64  ip,
struct unwind_info ui 
)
static

Definition at line 26 of file unwind-libdw.c.

Here is the call graph for this function:

◆ access_dso_mem()

static int access_dso_mem ( struct unwind_info ui,
Dwarf_Addr  addr,
Dwarf_Word *  data 
)
static

Definition at line 101 of file unwind-libdw.c.

Here is the call graph for this function:

◆ entry()

static int entry ( u64  ip,
struct unwind_info ui 
)
static

Definition at line 71 of file unwind-libdw.c.

Here is the call graph for this function:

◆ frame_callback()

static int frame_callback ( Dwfl_Frame *  state,
void *  arg 
)
static

Definition at line 165 of file unwind-libdw.c.

Here is the call graph for this function:

◆ memory_read()

static bool memory_read ( Dwfl *dwfl  __maybe_unused,
Dwarf_Addr  addr,
Dwarf_Word *  result,
void *  arg 
)
static

Definition at line 121 of file unwind-libdw.c.

Here is the call graph for this function:

◆ next_thread()

static pid_t next_thread ( Dwfl *  dwfl,
void *  arg,
void **  thread_argp 
)
static

Definition at line 91 of file unwind-libdw.c.

◆ report_module()

static int report_module ( u64  ip,
struct unwind_info ui 
)
static

Definition at line 60 of file unwind-libdw.c.

Here is the call graph for this function:

◆ unwind__get_entries()

int unwind__get_entries ( unwind_entry_cb_t cb  ,
void *  arg,
struct thread thread,
struct perf_sample data,
int  max_stack 
)

Definition at line 191 of file unwind-libdw.c.

Here is the call graph for this function:

Variable Documentation

◆ callbacks

const Dwfl_Thread_Callbacks callbacks
static
Initial value:
= {
.next_thread = next_thread,
.memory_read = memory_read,
.set_initial_registers = libdw__arch_set_initial_registers,
}
static bool memory_read(Dwfl *dwfl __maybe_unused, Dwarf_Addr addr, Dwarf_Word *result, void *arg)
Definition: unwind-libdw.c:121
static pid_t next_thread(Dwfl *dwfl, void *arg, void **thread_argp)
Definition: unwind-libdw.c:91
bool libdw__arch_set_initial_registers(Dwfl_Thread *thread, void *arg)
Definition: unwind-libdw.c:7

Definition at line 158 of file unwind-libdw.c.

◆ debuginfo_path

char* debuginfo_path
static

Definition at line 18 of file unwind-libdw.c.

◆ offline_callbacks

const Dwfl_Callbacks offline_callbacks
static
Initial value:
= {
.find_debuginfo = dwfl_standard_find_debuginfo,
.debuginfo_path = &debuginfo_path,
.section_address = dwfl_offline_section_address,
}
static char * debuginfo_path
Definition: unwind-libdw.c:18

Definition at line 20 of file unwind-libdw.c.