summaryrefslogtreecommitdiff
path: root/tools/perf/util/db-export.c
diff options
context:
space:
mode:
authorIngo Molnar <mingo@kernel.org>2016-05-12 08:57:52 +0200
committerIngo Molnar <mingo@kernel.org>2016-05-12 08:57:52 +0200
commit9ab975a029ec96b47c2f830aef6efd0e24f5c304 (patch)
tree9f72227d5a3282e19994cf8ee0ad81c4d66abdd7 /tools/perf/util/db-export.c
parent38f5d8b32f36bcac1f54d4511a81e02ed8771a29 (diff)
parentd65444d2fba98dcd4fa028ffada39c36a46f0038 (diff)
Merge tag 'perf-core-for-mingo-20160511' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core
Pull perf/core improvements and fixes from Arnaldo Carvalho de Melo: User visible changes: - Fix symbol insertion and callchain behavior in db-export (Chris Phlipot) Infrastructure changes: - Add libunwind build test (feature query), working towards supporting cross-platform DWARF callchains, starting with arm/arm64 (He Kuang) - Use lsdir() more extensively (Masami Hiramatsu) - Use SBUILD_ID_SIZE in places where the equivalent expression was being used (Masami Hiramatsu) - Split some more 'perf trace' syscall arg beautifiers (Arnaldo Carvalho de Melo) Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'tools/perf/util/db-export.c')
-rw-r--r--tools/perf/util/db-export.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/tools/perf/util/db-export.c b/tools/perf/util/db-export.c
index f8e3057ae3b1..8d96c80cc67e 100644
--- a/tools/perf/util/db-export.c
+++ b/tools/perf/util/db-export.c
@@ -260,8 +260,7 @@ static int db_ids_from_al(struct db_export *dbe, struct addr_location *al,
if (!al->sym) {
al->sym = symbol__new(al->addr, 0, 0, "unknown");
if (al->sym)
- symbols__insert(&dso->symbols[al->map->type],
- al->sym);
+ dso__insert_symbol(dso, al->map->type, al->sym);
}
if (al->sym) {
@@ -325,10 +324,11 @@ static struct call_path *call_path_from_sample(struct db_export *dbe,
al.sym = node->sym;
al.map = node->map;
al.machine = machine;
- if (al.map)
- al.addr = al.map->map_ip(al.map, node->ip);
- else
- al.addr = node->ip;
+ al.addr = node->ip;
+
+ if (al.map && !al.sym)
+ al.sym = dso__find_symbol(al.map->dso, MAP__FUNCTION,
+ al.addr);
db_ids_from_al(dbe, &al, &dso_db_id, &sym_db_id, &offset);