Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 264100
b: refs/heads/master
c: af52aaf
h: refs/heads/master
v: v3
  • Loading branch information
Arnaldo Carvalho de Melo committed Sep 23, 2011
1 parent faf8160 commit 7f05dea
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: be96ea8ffa788dccb1ba895cced29db6687c4911
refs/heads/master: af52aafad26fe83edc3ff95d6f630c2fc98a0c4c
9 changes: 5 additions & 4 deletions trunk/tools/perf/builtin-top.c
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,8 @@ static void __zero_source_counters(struct sym_entry *syme)
symbol__annotate_zero_histograms(sym);
}

static void record_precise_ip(struct sym_entry *syme, int counter, u64 ip)
static void record_precise_ip(struct sym_entry *syme, struct map *map,
int counter, u64 ip)
{
struct annotation *notes;
struct symbol *sym;
Expand All @@ -205,8 +206,8 @@ static void record_precise_ip(struct sym_entry *syme, int counter, u64 ip)
if (pthread_mutex_trylock(&notes->lock))
return;

ip = syme->map->map_ip(syme->map, ip);
symbol__inc_addr_samples(sym, syme->map, counter, ip);
ip = map->map_ip(map, ip);
symbol__inc_addr_samples(sym, map, counter, ip);

pthread_mutex_unlock(&notes->lock);
}
Expand Down Expand Up @@ -810,7 +811,7 @@ static void perf_event__process_sample(const union perf_event *event,
evsel = perf_evlist__id2evsel(top.evlist, sample->id);
assert(evsel != NULL);
syme->count[evsel->idx]++;
record_precise_ip(syme, evsel->idx, ip);
record_precise_ip(syme, al.map, evsel->idx, ip);
pthread_mutex_lock(&top.active_symbols_lock);
if (list_empty(&syme->node) || !syme->node.next) {
static bool first = true;
Expand Down

0 comments on commit 7f05dea

Please sign in to comment.