Browse Source

perf tests attr: Add proper return values

The record command now properly returns the status of the tracee if
there's any. We need to properly set the expected return value of the
tracee in the attr tests.

Signed-off-by: Jiri Olsa <jolsa@kernel.org>
Cc: David Ahern <dsahern@gmail.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Thomas Richter <tmricht@linux.vnet.ibm.com>
Link: http://lkml.kernel.org/r/20170703145030.12903-10-jolsa@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Jiri Olsa 8 years ago
parent
commit
a72fe0afa1

+ 1 - 0
tools/perf/tests/attr/test-record-C0

@@ -1,6 +1,7 @@
 [config]
 command = record
 args    = -C 0 kill >/dev/null 2>&1
+ret     = 1
 
 [event:base-record]
 cpu=0

+ 1 - 0
tools/perf/tests/attr/test-record-basic

@@ -1,5 +1,6 @@
 [config]
 command = record
 args    = kill >/dev/null 2>&1
+ret     = 1
 
 [event:base-record]

+ 1 - 0
tools/perf/tests/attr/test-record-branch-any

@@ -1,6 +1,7 @@
 [config]
 command = record
 args    = -b kill >/dev/null 2>&1
+ret     = 1
 
 [event:base-record]
 sample_period=4000

+ 1 - 0
tools/perf/tests/attr/test-record-branch-filter-any

@@ -1,6 +1,7 @@
 [config]
 command = record
 args    = -j any kill >/dev/null 2>&1
+ret     = 1
 
 [event:base-record]
 sample_period=4000

+ 1 - 0
tools/perf/tests/attr/test-record-branch-filter-any_call

@@ -1,6 +1,7 @@
 [config]
 command = record
 args    = -j any_call kill >/dev/null 2>&1
+ret     = 1
 
 [event:base-record]
 sample_period=4000

+ 1 - 0
tools/perf/tests/attr/test-record-branch-filter-any_ret

@@ -1,6 +1,7 @@
 [config]
 command = record
 args    = -j any_ret kill >/dev/null 2>&1
+ret     = 1
 
 [event:base-record]
 sample_period=4000

+ 1 - 0
tools/perf/tests/attr/test-record-branch-filter-hv

@@ -1,6 +1,7 @@
 [config]
 command = record
 args    = -j hv kill >/dev/null 2>&1
+ret     = 1
 
 [event:base-record]
 sample_period=4000

+ 1 - 0
tools/perf/tests/attr/test-record-branch-filter-ind_call

@@ -1,6 +1,7 @@
 [config]
 command = record
 args    = -j ind_call kill >/dev/null 2>&1
+ret     = 1
 
 [event:base-record]
 sample_period=4000

+ 1 - 0
tools/perf/tests/attr/test-record-branch-filter-k

@@ -1,6 +1,7 @@
 [config]
 command = record
 args    = -j k kill >/dev/null 2>&1
+ret     = 1
 
 [event:base-record]
 sample_period=4000

+ 1 - 0
tools/perf/tests/attr/test-record-branch-filter-u

@@ -1,6 +1,7 @@
 [config]
 command = record
 args    = -j u kill >/dev/null 2>&1
+ret     = 1
 
 [event:base-record]
 sample_period=4000

+ 1 - 0
tools/perf/tests/attr/test-record-count

@@ -1,6 +1,7 @@
 [config]
 command = record
 args    = -c 123 kill >/dev/null 2>&1
+ret     = 1
 
 [event:base-record]
 sample_period=123

+ 1 - 0
tools/perf/tests/attr/test-record-data

@@ -1,6 +1,7 @@
 [config]
 command = record
 args    = -d kill >/dev/null 2>&1
+ret     = 1
 
 [event:base-record]
 sample_period=4000

+ 1 - 0
tools/perf/tests/attr/test-record-freq

@@ -1,6 +1,7 @@
 [config]
 command = record
 args    = -F 100 kill >/dev/null 2>&1
+ret     = 1
 
 [event:base-record]
 sample_period=100

+ 1 - 0
tools/perf/tests/attr/test-record-graph-default

@@ -1,6 +1,7 @@
 [config]
 command = record
 args    = -g kill >/dev/null 2>&1
+ret     = 1
 
 [event:base-record]
 sample_type=295

+ 1 - 0
tools/perf/tests/attr/test-record-graph-dwarf

@@ -1,6 +1,7 @@
 [config]
 command = record
 args    = --call-graph dwarf -- kill >/dev/null 2>&1
+ret     = 1
 
 [event:base-record]
 sample_type=45359

+ 1 - 0
tools/perf/tests/attr/test-record-graph-fp

@@ -1,6 +1,7 @@
 [config]
 command = record
 args    = --call-graph fp kill >/dev/null 2>&1
+ret     = 1
 
 [event:base-record]
 sample_type=295

+ 1 - 0
tools/perf/tests/attr/test-record-group

@@ -1,6 +1,7 @@
 [config]
 command = record
 args    = --group -e cycles,instructions kill >/dev/null 2>&1
+ret     = 1
 
 [event-1:base-record]
 fd=1

+ 1 - 0
tools/perf/tests/attr/test-record-group-sampling

@@ -1,6 +1,7 @@
 [config]
 command = record
 args    = -e '{cycles,cache-misses}:S' kill >/dev/null 2>&1
+ret     = 1
 
 [event-1:base-record]
 fd=1

+ 1 - 0
tools/perf/tests/attr/test-record-group1

@@ -1,6 +1,7 @@
 [config]
 command = record
 args    = -e '{cycles,instructions}' kill >/dev/null 2>&1
+ret     = 1
 
 [event-1:base-record]
 fd=1

+ 1 - 0
tools/perf/tests/attr/test-record-no-buffering

@@ -1,6 +1,7 @@
 [config]
 command = record
 args    = --no-buffering kill >/dev/null 2>&1
+ret     = 1
 
 [event:base-record]
 sample_period=4000

+ 1 - 0
tools/perf/tests/attr/test-record-no-inherit

@@ -1,6 +1,7 @@
 [config]
 command = record
 args    = -i kill >/dev/null 2>&1
+ret     = 1
 
 [event:base-record]
 sample_type=263

+ 1 - 0
tools/perf/tests/attr/test-record-no-samples

@@ -1,6 +1,7 @@
 [config]
 command = record
 args    = -n kill >/dev/null 2>&1
+ret     = 1
 
 [event:base-record]
 sample_period=0

+ 1 - 0
tools/perf/tests/attr/test-record-period

@@ -1,6 +1,7 @@
 [config]
 command = record
 args    = -c 100 -P kill >/dev/null 2>&1
+ret     = 1
 
 [event:base-record]
 sample_period=100

+ 1 - 0
tools/perf/tests/attr/test-record-raw

@@ -1,6 +1,7 @@
 [config]
 command = record
 args    = -R kill >/dev/null 2>&1
+ret     = 1
 
 [event:base-record]
 sample_period=4000