Lines Matching full:dbg

55 static int debuginfo__init_offline_dwarf(struct debuginfo *dbg,  in debuginfo__init_offline_dwarf()  argument
65 dbg->dwfl = dwfl_begin(&offline_callbacks); in debuginfo__init_offline_dwarf()
66 if (!dbg->dwfl) in debuginfo__init_offline_dwarf()
69 dwfl_report_begin(dbg->dwfl); in debuginfo__init_offline_dwarf()
70 dbg->mod = dwfl_report_offline(dbg->dwfl, "", "", fd); in debuginfo__init_offline_dwarf()
71 if (!dbg->mod) in debuginfo__init_offline_dwarf()
74 dbg->dbg = dwfl_module_getdwarf(dbg->mod, &dbg->bias); in debuginfo__init_offline_dwarf()
75 if (!dbg->dbg) in debuginfo__init_offline_dwarf()
78 dwfl_module_build_id(dbg->mod, &dbg->build_id, &dummy); in debuginfo__init_offline_dwarf()
80 dwfl_report_end(dbg->dwfl, NULL, NULL); in debuginfo__init_offline_dwarf()
84 if (dbg->dwfl) in debuginfo__init_offline_dwarf()
85 dwfl_end(dbg->dwfl); in debuginfo__init_offline_dwarf()
88 memset(dbg, 0, sizeof(*dbg)); in debuginfo__init_offline_dwarf()
95 struct debuginfo *dbg = zalloc(sizeof(*dbg)); in __debuginfo__new() local
96 if (!dbg) in __debuginfo__new()
99 if (debuginfo__init_offline_dwarf(dbg, path) < 0) in __debuginfo__new()
100 zfree(&dbg); in __debuginfo__new()
101 if (dbg) in __debuginfo__new()
103 return dbg; in __debuginfo__new()
142 void debuginfo__delete(struct debuginfo *dbg) in debuginfo__delete() argument
144 if (dbg) { in debuginfo__delete()
145 if (dbg->dwfl) in debuginfo__delete()
146 dwfl_end(dbg->dwfl); in debuginfo__delete()
147 free(dbg); in debuginfo__delete()
961 if (pf->dbg->build_id) { in find_probe_point_lazy()
962 build_id__init(&bid, pf->dbg->build_id, BUILD_ID_SIZE); in find_probe_point_lazy()
1126 static int pubname_search_cb(Dwarf *dbg, Dwarf_Global *gl, void *data) in pubname_search_cb() argument
1130 if (dwarf_offdie(dbg, gl->die_offset, param->sp_die)) { in pubname_search_cb()
1135 if (!dwarf_offdie(dbg, gl->cu_offset, param->cu_die)) in pubname_search_cb()
1150 static int debuginfo__find_probe_location(struct debuginfo *dbg, in debuginfo__find_probe_location() argument
1177 dwarf_getpubnames(dbg->dbg, pubname_search_cb, in debuginfo__find_probe_location()
1187 while (!dwarf_nextcu(dbg->dbg, off, &noff, &cuhl, NULL, NULL, NULL)) { in debuginfo__find_probe_location()
1189 diep = dwarf_offdie(dbg->dbg, off + cuhl, &pf->cu_die); in debuginfo__find_probe_location()
1222 static int debuginfo__find_probes(struct debuginfo *dbg, in debuginfo__find_probes() argument
1230 return debuginfo__find_probe_location(dbg, pf); in debuginfo__find_probes()
1233 elf = dwarf_getelf(dbg->dbg); in debuginfo__find_probes()
1250 pf->cfi_dbg = dwarf_getcfi(dbg->dbg); in debuginfo__find_probes()
1254 ret = debuginfo__find_probe_location(dbg, pf); in debuginfo__find_probes()
1459 int debuginfo__find_trace_events(struct debuginfo *dbg, in debuginfo__find_trace_events() argument
1464 .pf = {.pev = pev, .dbg = dbg, .callback = add_probe_trace_event}, in debuginfo__find_trace_events()
1465 .max_tevs = probe_conf.max_probes, .mod = dbg->mod}; in debuginfo__find_trace_events()
1479 ret = debuginfo__find_probes(dbg, &tf.pf); in debuginfo__find_trace_events()
1629 int debuginfo__find_available_vars_at(struct debuginfo *dbg, in debuginfo__find_available_vars_at() argument
1634 .pf = {.pev = pev, .dbg = dbg, .callback = add_available_vars}, in debuginfo__find_available_vars_at()
1635 .mod = dbg->mod, in debuginfo__find_available_vars_at()
1647 ret = debuginfo__find_probes(dbg, &af.pf); in debuginfo__find_available_vars_at()
1662 int debuginfo__get_text_offset(struct debuginfo *dbg, Dwarf_Addr *offs, in debuginfo__get_text_offset() argument
1672 elf = dwfl_module_getelf(dbg->mod, &dbg->bias); in debuginfo__get_text_offset()
1677 n = dwfl_module_relocations(dbg->mod); in debuginfo__get_text_offset()
1682 p = dwfl_module_relocation_info(dbg->mod, i, &shndx); in debuginfo__get_text_offset()
1700 int debuginfo__find_probe_point(struct debuginfo *dbg, unsigned long addr, in debuginfo__find_probe_point() argument
1709 if (debuginfo__get_text_offset(dbg, &baseaddr, false) == 0) in debuginfo__find_probe_point()
1712 if (!dwarf_addrdie(dbg->dbg, (Dwarf_Addr)addr, &cudie)) { in debuginfo__find_probe_point()
1918 int debuginfo__find_line_range(struct debuginfo *dbg, struct line_range *lr) in debuginfo__find_line_range() argument
1935 dwarf_getpubnames(dbg->dbg, pubname_search_cb, in debuginfo__find_line_range()
1946 if (dwarf_nextcu(dbg->dbg, off, &noff, &cuhl, in debuginfo__find_line_range()
1951 diep = dwarf_offdie(dbg->dbg, off + cuhl, &lf.cu_die); in debuginfo__find_line_range()