From: Jiri Olsa <jolsa@redhat.com>
To: Arnaldo Carvalho de Melo <acme@kernel.org>
Cc: Jiri Olsa <jolsa@kernel.org>, lkml <linux-kernel@vger.kernel.org>,
Peter Zijlstra <a.p.zijlstra@chello.nl>,
Paul Mackerras <paulus@samba.org>,
David Ahern <dsahern@gmail.com>,
Namhyung Kim <namhyung@kernel.org>,
Ingo Molnar <mingo@kernel.org>, Andi Kleen <ak@linux.intel.com>,
Stephane Eranian <eranian@google.com>
Subject: Re: [PATCHv2 0/9] perf stat: Separate shadow counters code
Date: Thu, 4 Jun 2015 00:38:24 +0200 [thread overview]
Message-ID: <20150603223824.GA25840@krava.redhat.com> (raw)
In-Reply-To: <20150603222453.GG32707@kernel.org>
On Wed, Jun 03, 2015 at 07:24:53PM -0300, Arnaldo Carvalho de Melo wrote:
> Em Wed, Jun 03, 2015 at 07:07:05PM -0300, Arnaldo Carvalho de Melo escreveu:
> > Em Wed, Jun 03, 2015 at 04:25:50PM +0200, Jiri Olsa escreveu:
> > > hi,
> > > sending cleanup/move of shadow counters. I need it
> > > for my other changes of stat scripting, but I think
> > > it can stand alone as a cleanup.
> > >
> > > v2 changes:
> > > - move evsel id into 'struct perf_stat'
> > > and change the id functions namespace
> >
> > Thanks, applied.
>
> 15: struct perf_event_attr setup :sh: line 1: 27101 Segmentation fault (core dumped) PERF_TEST_ATTR=/tmp/tmptb9pWi /home/acme/bin/perf stat -o /tmp/tmptb9pWi/perf.data kill > /dev/null 2>&1
> sh: line 1: 27104 Segmentation fault (core dumped) PERF_TEST_ATTR=/tmp/tmpWgRK9D /home/acme/bin/perf stat -o /tmp/tmpWgRK9D/perf.data -d kill > /dev/null 2>&1
> sh: line 1: 27107 Segmentation fault (core dumped) PERF_TEST_ATTR=/tmp/tmpmCOyBe /home/acme/bin/perf stat -o /tmp/tmpmCOyBe/perf.data -dd kill > /dev/null 2>&1
> sh: line 1: 27110 Segmentation fault (core dumped) PERF_TEST_ATTR=/tmp/tmpJP9x2e /home/acme/bin/perf stat -o /tmp/tmpJP9x2e/perf.data -ddd kill > /dev/null 2>&1
> Ok
>
> Can you please check?
arghh.. sry, I remember running tests :-\ really ;-)
it's the -d default events that do not set evsel->name
attached patch fixes it, but I'll send v3 for the first patch
thanks,
jirka
---
diff --git a/tools/perf/util/stat.c b/tools/perf/util/stat.c
index d22791d02db0..dba762da5679 100644
--- a/tools/perf/util/stat.c
+++ b/tools/perf/util/stat.c
@@ -88,7 +88,7 @@ void perf_stat_evsel_id_init(struct perf_evsel *evsel)
/* ps->id is 0 hence PERF_STAT_EVSEL_ID__NONE by default */
for (i = 0; i < PERF_STAT_EVSEL_ID__MAX; i++) {
- if (!strcmp(evsel->name, id_str[i])) {
+ if (evsel->name && !strcmp(evsel->name, id_str[i])) {
ps->id = i;
break;
}
next prev parent reply other threads:[~2015-06-03 22:38 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-06-03 14:25 Jiri Olsa
2015-06-03 14:25 ` [PATCH 1/9] perf stat: Add id into perf_stat struct Jiri Olsa
2015-06-04 13:50 ` [PATCHv3] " Jiri Olsa
2015-06-08 14:03 ` Arnaldo Carvalho de Melo
2015-06-09 20:09 ` Jiri Olsa
2015-06-09 9:48 ` [tip:perf/core] " tip-bot for Jiri Olsa
2015-06-03 14:25 ` [PATCH 2/9] perf stat: Replace transaction event possition check with id check Jiri Olsa
2015-06-09 9:49 ` [tip:perf/core] " tip-bot for Jiri Olsa
2015-06-03 14:25 ` [PATCH 3/9] perf stat: Remove setup_events function Jiri Olsa
2015-06-09 9:49 ` [tip:perf/core] " tip-bot for Jiri Olsa
2015-06-03 14:25 ` [PATCH 4/9] perf stat: Remove transaction_run from shadow update/print code Jiri Olsa
2015-06-03 15:10 ` Arnaldo Carvalho de Melo
2015-06-03 15:14 ` Jiri Olsa
2015-06-03 15:55 ` Arnaldo Carvalho de Melo
2015-06-09 9:49 ` [tip:perf/core] " tip-bot for Jiri Olsa
2015-06-03 14:25 ` [PATCH 5/9] perf stat: Introduce reset_shadow_stats function Jiri Olsa
2015-06-09 9:50 ` [tip:perf/core] " tip-bot for Jiri Olsa
2015-06-03 14:25 ` [PATCH 6/9] perf stat: Introduce print_shadow_stats function Jiri Olsa
2015-06-09 9:50 ` [tip:perf/core] " tip-bot for Jiri Olsa
2015-06-03 14:25 ` [PATCH 7/9] perf stat: Add output file argument to " Jiri Olsa
2015-06-09 9:50 ` [tip:perf/core] " tip-bot for Jiri Olsa
2015-06-03 14:25 ` [PATCH 8/9] perf stat: Add aggr_mode " Jiri Olsa
2015-06-09 9:51 ` [tip:perf/core] " tip-bot for Jiri Olsa
2015-06-03 14:25 ` [PATCH 9/9] perf stat: Move shadow stat counters into separate object Jiri Olsa
2015-06-09 9:51 ` [tip:perf/core] " tip-bot for Jiri Olsa
2015-06-03 22:07 ` [PATCHv2 0/9] perf stat: Separate shadow counters code Arnaldo Carvalho de Melo
2015-06-03 22:24 ` Arnaldo Carvalho de Melo
2015-06-03 22:38 ` Jiri Olsa [this message]
2015-06-03 22:42 ` Arnaldo Carvalho de Melo
2015-06-04 13:49 ` Jiri Olsa
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20150603223824.GA25840@krava.redhat.com \
--to=jolsa@redhat.com \
--cc=a.p.zijlstra@chello.nl \
--cc=acme@kernel.org \
--cc=ak@linux.intel.com \
--cc=dsahern@gmail.com \
--cc=eranian@google.com \
--cc=jolsa@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@kernel.org \
--cc=namhyung@kernel.org \
--cc=paulus@samba.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome