aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf
diff options
context:
space:
mode:
Diffstat (limited to 'tools/perf')
-rw-r--r--tools/perf/ui/browsers/annotate.c6
-rw-r--r--tools/perf/ui/browsers/hists.c13
-rw-r--r--tools/perf/ui/browsers/map.c2
-rw-r--r--tools/perf/ui/browsers/scripts.c2
-rw-r--r--tools/perf/util/symbol.c18
-rw-r--r--tools/perf/util/unwind-libunwind.c14
6 files changed, 30 insertions, 25 deletions
diff --git a/tools/perf/ui/browsers/annotate.c b/tools/perf/ui/browsers/annotate.c
index 29739b347599..bec0b62d8e38 100644
--- a/tools/perf/ui/browsers/annotate.c
+++ b/tools/perf/ui/browsers/annotate.c
@@ -768,8 +768,8 @@ static int annotate_browser__run(struct annotate_browser *browser,
768 "UP/DOWN/PGUP\n" 768 "UP/DOWN/PGUP\n"
769 "PGDN/SPACE Navigate\n" 769 "PGDN/SPACE Navigate\n"
770 "q/ESC/CTRL+C Exit\n\n" 770 "q/ESC/CTRL+C Exit\n\n"
771 "-> Go to target\n" 771 "ENTER Go to target\n"
772 "<- Exit\n" 772 "ESC Exit\n"
773 "H Cycle thru hottest instructions\n" 773 "H Cycle thru hottest instructions\n"
774 "j Toggle showing jump to target arrows\n" 774 "j Toggle showing jump to target arrows\n"
775 "J Toggle showing number of jump sources on targets\n" 775 "J Toggle showing number of jump sources on targets\n"
@@ -1056,7 +1056,7 @@ int symbol__tui_annotate(struct symbol *sym, struct map *map,
1056 goto out_free_offsets; 1056 goto out_free_offsets;
1057 } 1057 }
1058 1058
1059 ui_helpline__push("Press <- or ESC to exit"); 1059 ui_helpline__push("Press ESC to exit");
1060 1060
1061 notes = symbol__annotation(sym); 1061 notes = symbol__annotation(sym);
1062 browser.start = map__rip_2objdump(map, sym->start); 1062 browser.start = map__rip_2objdump(map, sym->start);
diff --git a/tools/perf/ui/browsers/hists.c b/tools/perf/ui/browsers/hists.c
index 9b7346a881cf..e5afb8936040 100644
--- a/tools/perf/ui/browsers/hists.c
+++ b/tools/perf/ui/browsers/hists.c
@@ -1496,7 +1496,7 @@ do_zoom_thread(struct hist_browser *browser, struct popup_action *act)
1496 thread__zput(browser->hists->thread_filter); 1496 thread__zput(browser->hists->thread_filter);
1497 ui_helpline__pop(); 1497 ui_helpline__pop();
1498 } else { 1498 } else {
1499 ui_helpline__fpush("To zoom out press <- or -> + \"Zoom out of %s(%d) thread\"", 1499 ui_helpline__fpush("To zoom out press ESC or ENTER + \"Zoom out of %s(%d) thread\"",
1500 thread->comm_set ? thread__comm_str(thread) : "", 1500 thread->comm_set ? thread__comm_str(thread) : "",
1501 thread->tid); 1501 thread->tid);
1502 browser->hists->thread_filter = thread__get(thread); 1502 browser->hists->thread_filter = thread__get(thread);
@@ -1540,7 +1540,7 @@ do_zoom_dso(struct hist_browser *browser, struct popup_action *act)
1540 } else { 1540 } else {
1541 if (map == NULL) 1541 if (map == NULL)
1542 return 0; 1542 return 0;
1543 ui_helpline__fpush("To zoom out press <- or -> + \"Zoom out of %s DSO\"", 1543 ui_helpline__fpush("To zoom out press ESC or ENTER + \"Zoom out of %s DSO\"",
1544 __map__is_kernel(map) ? "the Kernel" : map->dso->short_name); 1544 __map__is_kernel(map) ? "the Kernel" : map->dso->short_name);
1545 browser->hists->dso_filter = map->dso; 1545 browser->hists->dso_filter = map->dso;
1546 perf_hpp__set_elide(HISTC_DSO, true); 1546 perf_hpp__set_elide(HISTC_DSO, true);
@@ -1761,14 +1761,15 @@ static int perf_evsel__hists_browse(struct perf_evsel *evsel, int nr_events,
1761 "For multiple event sessions:\n\n" \ 1761 "For multiple event sessions:\n\n" \
1762 "TAB/UNTAB Switch events\n\n" \ 1762 "TAB/UNTAB Switch events\n\n" \
1763 "For symbolic views (--sort has sym):\n\n" \ 1763 "For symbolic views (--sort has sym):\n\n" \
1764 "-> Zoom into DSO/Threads & Annotate current symbol\n" \ 1764 "ENTER Zoom into DSO/Threads & Annotate current symbol\n" \
1765 "<- Zoom out\n" \ 1765 "ESC Zoom out\n" \
1766 "a Annotate current symbol\n" \ 1766 "a Annotate current symbol\n" \
1767 "C Collapse all callchains\n" \ 1767 "C Collapse all callchains\n" \
1768 "d Zoom into current DSO\n" \ 1768 "d Zoom into current DSO\n" \
1769 "E Expand all callchains\n" \ 1769 "E Expand all callchains\n" \
1770 "F Toggle percentage of filtered entries\n" \ 1770 "F Toggle percentage of filtered entries\n" \
1771 "H Display column headers\n" \ 1771 "H Display column headers\n" \
1772 "m Display context menu\n" \
1772 "S Zoom into current Processor Socket\n" \ 1773 "S Zoom into current Processor Socket\n" \
1773 1774
1774 /* help messages are sorted by lexical order of the hotkey */ 1775 /* help messages are sorted by lexical order of the hotkey */
@@ -1889,7 +1890,8 @@ static int perf_evsel__hists_browse(struct perf_evsel *evsel, int nr_events,
1889 continue; 1890 continue;
1890 case '/': 1891 case '/':
1891 if (ui_browser__input_window("Symbol to show", 1892 if (ui_browser__input_window("Symbol to show",
1892 "Please enter the name of symbol you want to see", 1893 "Please enter the name of symbol you want to see.\n"
1894 "To remove the filter later, press / + ENTER.",
1893 buf, "ENTER: OK, ESC: Cancel", 1895 buf, "ENTER: OK, ESC: Cancel",
1894 delay_secs * 2) == K_ENTER) { 1896 delay_secs * 2) == K_ENTER) {
1895 hists->symbol_filter_str = *buf ? buf : NULL; 1897 hists->symbol_filter_str = *buf ? buf : NULL;
@@ -1934,6 +1936,7 @@ static int perf_evsel__hists_browse(struct perf_evsel *evsel, int nr_events,
1934 continue; 1936 continue;
1935 case K_ENTER: 1937 case K_ENTER:
1936 case K_RIGHT: 1938 case K_RIGHT:
1939 case 'm':
1937 /* menu */ 1940 /* menu */
1938 break; 1941 break;
1939 case K_ESC: 1942 case K_ESC:
diff --git a/tools/perf/ui/browsers/map.c b/tools/perf/ui/browsers/map.c
index 8c154c7d4669..80912778bb6d 100644
--- a/tools/perf/ui/browsers/map.c
+++ b/tools/perf/ui/browsers/map.c
@@ -72,7 +72,7 @@ static int map_browser__run(struct map_browser *browser)
72 int key; 72 int key;
73 73
74 if (ui_browser__show(&browser->b, browser->map->dso->long_name, 74 if (ui_browser__show(&browser->b, browser->map->dso->long_name,
75 "Press <- or ESC to exit, %s / to search", 75 "Press ESC to exit, %s / to search",
76 verbose ? "" : "restart with -v to use") < 0) 76 verbose ? "" : "restart with -v to use") < 0)
77 return -1; 77 return -1;
78 78
diff --git a/tools/perf/ui/browsers/scripts.c b/tools/perf/ui/browsers/scripts.c
index e13b48d705ef..ad6b6ee3770e 100644
--- a/tools/perf/ui/browsers/scripts.c
+++ b/tools/perf/ui/browsers/scripts.c
@@ -89,7 +89,7 @@ static int script_browser__run(struct perf_script_browser *browser)
89 int key; 89 int key;
90 90
91 if (ui_browser__show(&browser->b, browser->script_name, 91 if (ui_browser__show(&browser->b, browser->script_name,
92 "Press <- or ESC to exit") < 0) 92 "Press ESC to exit") < 0)
93 return -1; 93 return -1;
94 94
95 while (1) { 95 while (1) {
diff --git a/tools/perf/util/symbol.c b/tools/perf/util/symbol.c
index bcda43bee4d4..e7bf0c46918d 100644
--- a/tools/perf/util/symbol.c
+++ b/tools/perf/util/symbol.c
@@ -1607,6 +1607,15 @@ int dso__load_vmlinux_path(struct dso *dso, struct map *map,
1607 int i, err = 0; 1607 int i, err = 0;
1608 char *filename = NULL; 1608 char *filename = NULL;
1609 1609
1610 pr_debug("Looking at the vmlinux_path (%d entries long)\n",
1611 vmlinux_path__nr_entries + 1);
1612
1613 for (i = 0; i < vmlinux_path__nr_entries; ++i) {
1614 err = dso__load_vmlinux(dso, map, vmlinux_path[i], false, filter);
1615 if (err > 0)
1616 goto out;
1617 }
1618
1610 if (!symbol_conf.ignore_vmlinux_buildid) 1619 if (!symbol_conf.ignore_vmlinux_buildid)
1611 filename = dso__build_id_filename(dso, NULL, 0); 1620 filename = dso__build_id_filename(dso, NULL, 0);
1612 if (filename != NULL) { 1621 if (filename != NULL) {
@@ -1615,15 +1624,6 @@ int dso__load_vmlinux_path(struct dso *dso, struct map *map,
1615 goto out; 1624 goto out;
1616 free(filename); 1625 free(filename);
1617 } 1626 }
1618
1619 pr_debug("Looking at the vmlinux_path (%d entries long)\n",
1620 vmlinux_path__nr_entries + 1);
1621
1622 for (i = 0; i < vmlinux_path__nr_entries; ++i) {
1623 err = dso__load_vmlinux(dso, map, vmlinux_path[i], false, filter);
1624 if (err > 0)
1625 break;
1626 }
1627out: 1627out:
1628 return err; 1628 return err;
1629} 1629}
diff --git a/tools/perf/util/unwind-libunwind.c b/tools/perf/util/unwind-libunwind.c
index 4c00507ee3fd..f729f9e99f99 100644
--- a/tools/perf/util/unwind-libunwind.c
+++ b/tools/perf/util/unwind-libunwind.c
@@ -330,6 +330,7 @@ find_proc_info(unw_addr_space_t as, unw_word_t ip, unw_proc_info_t *pi,
330 struct map *map; 330 struct map *map;
331 unw_dyn_info_t di; 331 unw_dyn_info_t di;
332 u64 table_data, segbase, fde_count; 332 u64 table_data, segbase, fde_count;
333 int ret = -EINVAL;
333 334
334 map = find_map(ip, ui); 335 map = find_map(ip, ui);
335 if (!map || !map->dso) 336 if (!map || !map->dso)
@@ -348,13 +349,14 @@ find_proc_info(unw_addr_space_t as, unw_word_t ip, unw_proc_info_t *pi,
348 di.u.rti.table_data = map->start + table_data; 349 di.u.rti.table_data = map->start + table_data;
349 di.u.rti.table_len = fde_count * sizeof(struct table_entry) 350 di.u.rti.table_len = fde_count * sizeof(struct table_entry)
350 / sizeof(unw_word_t); 351 / sizeof(unw_word_t);
351 return dwarf_search_unwind_table(as, ip, &di, pi, 352 ret = dwarf_search_unwind_table(as, ip, &di, pi,
352 need_unwind_info, arg); 353 need_unwind_info, arg);
353 } 354 }
354 355
355#ifndef NO_LIBUNWIND_DEBUG_FRAME 356#ifndef NO_LIBUNWIND_DEBUG_FRAME
356 /* Check the .debug_frame section for unwinding info */ 357 /* Check the .debug_frame section for unwinding info */
357 if (!read_unwind_spec_debug_frame(map->dso, ui->machine, &segbase)) { 358 if (ret < 0 &&
359 !read_unwind_spec_debug_frame(map->dso, ui->machine, &segbase)) {
358 int fd = dso__data_get_fd(map->dso, ui->machine); 360 int fd = dso__data_get_fd(map->dso, ui->machine);
359 int is_exec = elf_is_exec(fd, map->dso->name); 361 int is_exec = elf_is_exec(fd, map->dso->name);
360 unw_word_t base = is_exec ? 0 : map->start; 362 unw_word_t base = is_exec ? 0 : map->start;
@@ -370,7 +372,7 @@ find_proc_info(unw_addr_space_t as, unw_word_t ip, unw_proc_info_t *pi,
370 } 372 }
371#endif 373#endif
372 374
373 return -EINVAL; 375 return ret;
374} 376}
375 377
376static int access_fpreg(unw_addr_space_t __maybe_unused as, 378static int access_fpreg(unw_addr_space_t __maybe_unused as,
@@ -461,7 +463,7 @@ static int access_mem(unw_addr_space_t __maybe_unused as,
461 if (ret) { 463 if (ret) {
462 pr_debug("unwind: access_mem %p not inside range" 464 pr_debug("unwind: access_mem %p not inside range"
463 " 0x%" PRIx64 "-0x%" PRIx64 "\n", 465 " 0x%" PRIx64 "-0x%" PRIx64 "\n",
464 (void *) addr, start, end); 466 (void *) (uintptr_t) addr, start, end);
465 *valp = 0; 467 *valp = 0;
466 return ret; 468 return ret;
467 } 469 }
@@ -471,7 +473,7 @@ static int access_mem(unw_addr_space_t __maybe_unused as,
471 offset = addr - start; 473 offset = addr - start;
472 *valp = *(unw_word_t *)&stack->data[offset]; 474 *valp = *(unw_word_t *)&stack->data[offset];
473 pr_debug("unwind: access_mem addr %p val %lx, offset %d\n", 475 pr_debug("unwind: access_mem addr %p val %lx, offset %d\n",
474 (void *) addr, (unsigned long)*valp, offset); 476 (void *) (uintptr_t) addr, (unsigned long)*valp, offset);
475 return 0; 477 return 0;
476} 478}
477 479