Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1680382 > unrolled thread
| Started by | Jiri Olsa <jolsa@kernel.org> |
|---|---|
| First post | 2017-07-03 17:00 +0200 |
| Last post | 2017-07-17 15:00 +0200 |
| Articles | 4 — 3 participants |
Back to article view | Back to linux.kernel
[PATCH 00/15] perf tools: Fix attr tests Jiri Olsa <jolsa@kernel.org> - 2017-07-03 17:00 +0200
[PATCH 05/15] perf tests attr: Rename compare_data to data_equal Jiri Olsa <jolsa@kernel.org> - 2017-07-03 17:00 +0200
Re: [PATCH 00/15] perf tools: Fix attr tests Jiri Olsa <jolsa@redhat.com> - 2017-07-17 14:20 +0200
Re: [PATCH 00/15] perf tools: Fix attr tests Arnaldo Carvalho de Melo <acme@kernel.org> - 2017-07-17 15:00 +0200
| From | Jiri Olsa <jolsa@kernel.org> |
|---|---|
| Date | 2017-07-03 17:00 +0200 |
| Subject | [PATCH 00/15] perf tools: Fix attr tests |
| Message-ID | <tZaZr-2UC-7@gated-at.bofh.it> |
hi,
attr tests have been broken for some time now. Updating
the data files plus some other processing fixes.
It's also available in here:
git://git.kernel.org/pub/scm/linux/kernel/git/jolsa/perf.git
perf/attr_test
thanks,
jirka
---
tools/perf/perf.h | 1 +
tools/perf/tests/attr.c | 12 +++++++++++-
tools/perf/tests/attr.py | 50 +++++++++++++++++++++++++++++---------------------
tools/perf/tests/attr/base-record | 8 ++++----
tools/perf/tests/attr/base-stat | 4 ++--
tools/perf/tests/attr/test-record-C0 | 1 +
tools/perf/tests/attr/test-record-basic | 1 +
tools/perf/tests/attr/test-record-branch-any | 2 +-
tools/perf/tests/attr/test-record-branch-filter-any | 2 +-
tools/perf/tests/attr/test-record-branch-filter-any_call | 2 +-
tools/perf/tests/attr/test-record-branch-filter-any_ret | 2 +-
tools/perf/tests/attr/test-record-branch-filter-hv | 2 +-
tools/perf/tests/attr/test-record-branch-filter-ind_call | 2 +-
tools/perf/tests/attr/test-record-branch-filter-k | 2 +-
tools/perf/tests/attr/test-record-branch-filter-u | 2 +-
tools/perf/tests/attr/test-record-count | 1 +
tools/perf/tests/attr/test-record-data | 3 +--
tools/perf/tests/attr/test-record-freq | 1 +
tools/perf/tests/attr/test-record-graph-default | 1 +
tools/perf/tests/attr/test-record-graph-dwarf | 4 +++-
tools/perf/tests/attr/test-record-graph-fp | 1 +
tools/perf/tests/attr/test-record-group | 2 ++
tools/perf/tests/attr/test-record-group-sampling | 3 ++-
tools/perf/tests/attr/test-record-group1 | 2 ++
tools/perf/tests/attr/{test-record-no-delay => test-record-no-buffering} | 4 ++--
tools/perf/tests/attr/test-record-no-inherit | 1 +
tools/perf/tests/attr/test-record-no-samples | 1 +
tools/perf/tests/attr/test-record-period | 1 +
tools/perf/tests/attr/test-record-raw | 2 +-
tools/perf/tests/attr/test-stat-C0 | 4 ++--
tools/perf/tests/attr/test-stat-default | 2 ++
tools/perf/tests/attr/test-stat-detailed-1 | 2 ++
tools/perf/tests/attr/test-stat-detailed-2 | 3 +++
tools/perf/tests/attr/test-stat-detailed-3 | 5 +++++
tools/perf/util/evsel.c | 8 +++++++-
35 files changed, 98 insertions(+), 46 deletions(-)
[toc] | [next] | [standalone]
| From | Jiri Olsa <jolsa@kernel.org> |
|---|---|
| Date | 2017-07-03 17:00 +0200 |
| Subject | [PATCH 05/15] perf tests attr: Rename compare_data to data_equal |
| Message-ID | <tZaZu-2UC-97@gated-at.bofh.it> |
| In reply to | #1680382 |
The data_equal name fits better to the return value
of the function. It's true when the data is equal.
Link: http://lkml.kernel.org/n/tip-rmebesaea5axp8fq9lfvx35s@git.kernel.org
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
---
tools/perf/tests/attr.py | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/tools/perf/tests/attr.py b/tools/perf/tests/attr.py
index bb671cd1d66a..b03261c6b1ed 100644
--- a/tools/perf/tests/attr.py
+++ b/tools/perf/tests/attr.py
@@ -9,7 +9,7 @@ import logging
import shutil
import ConfigParser
-def compare_data(a, b):
+def data_equal(a, b):
# Allow multiple values in assignment separated by '|'
a_list = a.split('|')
b_list = b.split('|')
@@ -101,7 +101,7 @@ class Event(dict):
log.debug(" [%s] %s %s" % (t, self[t], other[t]));
if not self.has_key(t) or not other.has_key(t):
return False
- if not compare_data(self[t], other[t]):
+ if not data_equal(self[t], other[t]):
return False
return True
@@ -109,7 +109,7 @@ class Event(dict):
for t in Event.terms:
if not self.has_key(t) or not other.has_key(t):
continue
- if not compare_data(self[t], other[t]):
+ if not data_equal(self[t], other[t]):
log.warning("expected %s=%s, got %s" % (t, self[t], other[t]))
# Test file description needs to have following sections:
@@ -220,7 +220,7 @@ class Test(object):
log.info(" '%s' ret '%s', expected '%s'" % (cmd, str(ret), str(self.ret)))
- if not compare_data(str(ret), str(self.ret)):
+ if not data_equal(str(ret), str(self.ret)):
raise Unsup(self)
def compare(self, expect, result):
--
2.9.4
[toc] | [prev] | [next] | [standalone]
| From | Jiri Olsa <jolsa@redhat.com> |
|---|---|
| Date | 2017-07-17 14:20 +0200 |
| Message-ID | <u4dai-4Tx-15@gated-at.bofh.it> |
| In reply to | #1680382 |
On Mon, Jul 03, 2017 at 04:50:15PM +0200, Jiri Olsa wrote:
> hi,
> attr tests have been broken for some time now. Updating
> the data files plus some other processing fixes.
>
> It's also available in here:
> git://git.kernel.org/pub/scm/linux/kernel/git/jolsa/perf.git
> perf/attr_test
hi,
just noticed that this got removed from your branch.. anything wrong with that?
thanks,
jirka
>
> thanks,
> jirka
> ---
> tools/perf/perf.h | 1 +
> tools/perf/tests/attr.c | 12 +++++++++++-
> tools/perf/tests/attr.py | 50 +++++++++++++++++++++++++++++---------------------
> tools/perf/tests/attr/base-record | 8 ++++----
> tools/perf/tests/attr/base-stat | 4 ++--
> tools/perf/tests/attr/test-record-C0 | 1 +
> tools/perf/tests/attr/test-record-basic | 1 +
> tools/perf/tests/attr/test-record-branch-any | 2 +-
> tools/perf/tests/attr/test-record-branch-filter-any | 2 +-
> tools/perf/tests/attr/test-record-branch-filter-any_call | 2 +-
> tools/perf/tests/attr/test-record-branch-filter-any_ret | 2 +-
> tools/perf/tests/attr/test-record-branch-filter-hv | 2 +-
> tools/perf/tests/attr/test-record-branch-filter-ind_call | 2 +-
> tools/perf/tests/attr/test-record-branch-filter-k | 2 +-
> tools/perf/tests/attr/test-record-branch-filter-u | 2 +-
> tools/perf/tests/attr/test-record-count | 1 +
> tools/perf/tests/attr/test-record-data | 3 +--
> tools/perf/tests/attr/test-record-freq | 1 +
> tools/perf/tests/attr/test-record-graph-default | 1 +
> tools/perf/tests/attr/test-record-graph-dwarf | 4 +++-
> tools/perf/tests/attr/test-record-graph-fp | 1 +
> tools/perf/tests/attr/test-record-group | 2 ++
> tools/perf/tests/attr/test-record-group-sampling | 3 ++-
> tools/perf/tests/attr/test-record-group1 | 2 ++
> tools/perf/tests/attr/{test-record-no-delay => test-record-no-buffering} | 4 ++--
> tools/perf/tests/attr/test-record-no-inherit | 1 +
> tools/perf/tests/attr/test-record-no-samples | 1 +
> tools/perf/tests/attr/test-record-period | 1 +
> tools/perf/tests/attr/test-record-raw | 2 +-
> tools/perf/tests/attr/test-stat-C0 | 4 ++--
> tools/perf/tests/attr/test-stat-default | 2 ++
> tools/perf/tests/attr/test-stat-detailed-1 | 2 ++
> tools/perf/tests/attr/test-stat-detailed-2 | 3 +++
> tools/perf/tests/attr/test-stat-detailed-3 | 5 +++++
> tools/perf/util/evsel.c | 8 +++++++-
> 35 files changed, 98 insertions(+), 46 deletions(-)
[toc] | [prev] | [next] | [standalone]
| From | Arnaldo Carvalho de Melo <acme@kernel.org> |
|---|---|
| Date | 2017-07-17 15:00 +0200 |
| Message-ID | <u4dN0-57W-37@gated-at.bofh.it> |
| In reply to | #1688976 |
Em Mon, Jul 17, 2017 at 02:18:14PM +0200, Jiri Olsa escreveu:
> On Mon, Jul 03, 2017 at 04:50:15PM +0200, Jiri Olsa wrote:
> > hi,
> > attr tests have been broken for some time now. Updating
> > the data files plus some other processing fixes.
> >
> > It's also available in here:
> > git://git.kernel.org/pub/scm/linux/kernel/git/jolsa/perf.git
> > perf/attr_test
>
> hi,
> just noticed that this got removed from your branch.. anything wrong with that?
Something st00pid on my part, I'll get it remerged, sorry.
- Arnaldo
> thanks,
> jirka
>
> >
> > thanks,
> > jirka
> > ---
> > tools/perf/perf.h | 1 +
> > tools/perf/tests/attr.c | 12 +++++++++++-
> > tools/perf/tests/attr.py | 50 +++++++++++++++++++++++++++++---------------------
> > tools/perf/tests/attr/base-record | 8 ++++----
> > tools/perf/tests/attr/base-stat | 4 ++--
> > tools/perf/tests/attr/test-record-C0 | 1 +
> > tools/perf/tests/attr/test-record-basic | 1 +
> > tools/perf/tests/attr/test-record-branch-any | 2 +-
> > tools/perf/tests/attr/test-record-branch-filter-any | 2 +-
> > tools/perf/tests/attr/test-record-branch-filter-any_call | 2 +-
> > tools/perf/tests/attr/test-record-branch-filter-any_ret | 2 +-
> > tools/perf/tests/attr/test-record-branch-filter-hv | 2 +-
> > tools/perf/tests/attr/test-record-branch-filter-ind_call | 2 +-
> > tools/perf/tests/attr/test-record-branch-filter-k | 2 +-
> > tools/perf/tests/attr/test-record-branch-filter-u | 2 +-
> > tools/perf/tests/attr/test-record-count | 1 +
> > tools/perf/tests/attr/test-record-data | 3 +--
> > tools/perf/tests/attr/test-record-freq | 1 +
> > tools/perf/tests/attr/test-record-graph-default | 1 +
> > tools/perf/tests/attr/test-record-graph-dwarf | 4 +++-
> > tools/perf/tests/attr/test-record-graph-fp | 1 +
> > tools/perf/tests/attr/test-record-group | 2 ++
> > tools/perf/tests/attr/test-record-group-sampling | 3 ++-
> > tools/perf/tests/attr/test-record-group1 | 2 ++
> > tools/perf/tests/attr/{test-record-no-delay => test-record-no-buffering} | 4 ++--
> > tools/perf/tests/attr/test-record-no-inherit | 1 +
> > tools/perf/tests/attr/test-record-no-samples | 1 +
> > tools/perf/tests/attr/test-record-period | 1 +
> > tools/perf/tests/attr/test-record-raw | 2 +-
> > tools/perf/tests/attr/test-stat-C0 | 4 ++--
> > tools/perf/tests/attr/test-stat-default | 2 ++
> > tools/perf/tests/attr/test-stat-detailed-1 | 2 ++
> > tools/perf/tests/attr/test-stat-detailed-2 | 3 +++
> > tools/perf/tests/attr/test-stat-detailed-3 | 5 +++++
> > tools/perf/util/evsel.c | 8 +++++++-
> > 35 files changed, 98 insertions(+), 46 deletions(-)
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web