Lines Matching full:ui

45 			    struct unwind_info *ui)  in __report_module()  argument
54 thread__find_symbol(ui->thread, PERF_RECORD_MISC_USER, ip, al); in __report_module()
74 mod = dwfl_addrmodule(ui->dwfl, ip); in __report_module()
87 mod = dwfl_report_elf(ui->dwfl, dso__short_name(dso), filename, -1, in __report_module()
94 mod = dwfl_report_elf(ui->dwfl, dso__short_name(dso), filename, -1, in __report_module()
105 return mod && dwfl_addrmodule(ui->dwfl, ip) == mod ? 0 : -1; in __report_module()
108 static int report_module(u64 ip, struct unwind_info *ui) in report_module() argument
114 res = __report_module(&al, ip, ui); in report_module()
123 static int entry(u64 ip, struct unwind_info *ui) in entry() argument
126 struct unwind_entry *e = &ui->entries[ui->idx++]; in entry()
130 if (__report_module(&al, ip, ui)) { in entry()
158 static int access_dso_mem(struct unwind_info *ui, Dwarf_Addr addr, in access_dso_mem() argument
166 if (!thread__find_map(ui->thread, PERF_RECORD_MISC_USER, addr, &al)) { in access_dso_mem()
174 size = dso__data_read_addr(dso, al.map, ui->machine, addr, (u8 *) data, sizeof(*data)); in access_dso_mem()
186 struct unwind_info *ui = arg; in memory_read() local
187 const char *arch = perf_env__arch(ui->machine->env); in memory_read()
188 struct stack_dump *stack = &ui->sample->user_stack; in memory_read()
193 ret = perf_reg_value(&start, &ui->sample->user_regs, in memory_read()
205 ret = access_dso_mem(ui, addr, result); in memory_read()
231 struct unwind_info *ui = arg; in frame_callback() local
236 if (!ui->best_effort) in frame_callback()
242 report_module(pc, ui); in frame_callback()
245 if (!ui->best_effort) in frame_callback()
253 return entry(pc, ui) || !(--ui->max_stack) ? in frame_callback()
263 struct unwind_info *ui, ui_buf = { in unwind__get_entries() local
279 ui = zalloc(sizeof(ui_buf) + sizeof(ui_buf.entries[0]) * max_stack); in unwind__get_entries()
280 if (!ui) in unwind__get_entries()
283 *ui = ui_buf; in unwind__get_entries()
285 ui->dwfl = dwfl_begin(&offline_callbacks); in unwind__get_entries()
286 if (!ui->dwfl) in unwind__get_entries()
293 err = report_module(ip, ui); in unwind__get_entries()
297 err = !dwfl_attach_state(ui->dwfl, EM_NONE, thread__tid(thread), &callbacks, ui); in unwind__get_entries()
301 err = dwfl_getthread_frames(ui->dwfl, thread__tid(thread), frame_callback, ui); in unwind__get_entries()
303 if (err && ui->max_stack != max_stack) in unwind__get_entries()
309 for (i = 0; i < ui->idx && !err; i++) { in unwind__get_entries()
313 j = ui->idx - i - 1; in unwind__get_entries()
315 err = ui->entries[j].ip ? ui->cb(&ui->entries[j], ui->arg) : 0; in unwind__get_entries()
322 dwfl_end(ui->dwfl); in unwind__get_entries()
323 free(ui); in unwind__get_entries()