perf top: Fix userspace sample addr map offset
authorArnaldo Carvalho de Melo <acme@redhat.com>
Wed, 14 Sep 2011 18:54:30 +0000 (15:54 -0300)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Fri, 23 Sep 2011 17:37:54 +0000 (14:37 -0300)
commitaf52aafad26fe83edc3ff95d6f630c2fc98a0c4c
treead71a13f3fa386c50fc1b0f3b50b20a0b3ce4b0e
parentbe96ea8ffa788dccb1ba895cced29db6687c4911
perf top: Fix userspace sample addr map offset

The 'perf top' tool came from the kernel where we had each DSO (vmlinux,
modules) loaded just once at a time.

But userspace may have DSOs loaded in multiple addresses (shared
libraries), requiring that we use the just resolved map instead of the
first one found.

Cc: David Ahern <dsahern@gmail.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Mike Galbraith <efault@gmx.de>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Stephane Eranian <eranian@google.com>
Link: http://lkml.kernel.org/n/tip-ag53wz0yllpgers0n2w7hchp@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/builtin-top.c