提交 4c09e0d6 编写于 作者: I Ingo Molnar

Merge tag 'perf-urgent-for-mingo' of...

Merge tag 'perf-urgent-for-mingo' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/urgent

Pull perf/urgent fix from Arnaldo Carvalho de Melo:

  - Use index, not CPU id, to find core/pkg id in 'perf stat' (Kan Liang)
Signed-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
Signed-off-by: NIngo Molnar <mingo@kernel.org>
...@@ -694,7 +694,7 @@ static void abs_printout(int id, int nr, struct perf_evsel *evsel, double avg) ...@@ -694,7 +694,7 @@ static void abs_printout(int id, int nr, struct perf_evsel *evsel, double avg)
static void print_aggr(char *prefix) static void print_aggr(char *prefix)
{ {
struct perf_evsel *counter; struct perf_evsel *counter;
int cpu, cpu2, s, s2, id, nr; int cpu, s, s2, id, nr;
double uval; double uval;
u64 ena, run, val; u64 ena, run, val;
...@@ -707,8 +707,7 @@ static void print_aggr(char *prefix) ...@@ -707,8 +707,7 @@ static void print_aggr(char *prefix)
val = ena = run = 0; val = ena = run = 0;
nr = 0; nr = 0;
for (cpu = 0; cpu < perf_evsel__nr_cpus(counter); cpu++) { for (cpu = 0; cpu < perf_evsel__nr_cpus(counter); cpu++) {
cpu2 = perf_evsel__cpus(counter)->map[cpu]; s2 = aggr_get_id(perf_evsel__cpus(counter), cpu);
s2 = aggr_get_id(evsel_list->cpus, cpu2);
if (s2 != id) if (s2 != id)
continue; continue;
val += perf_counts(counter->counts, cpu, 0)->val; val += perf_counts(counter->counts, cpu, 0)->val;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册