forked from luck/tmp_suning_uos_patched
perf test: Ensure sample_period is set libpfm4 events
Test that a command line option doesn't override the period set on a libpfm4 event. Without libpfm4 test passes as unsupported. Signed-off-by: Ian Rogers <irogers@google.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Alexei Starovoitov <ast@kernel.org> Cc: Andi Kleen <ak@linux.intel.com> Cc: Andrii Nakryiko <andriin@fb.com> Cc: Athira Jajeev <atrajeev@linux.vnet.ibm.com> Cc: Daniel Borkmann <daniel@iogearbox.net> Cc: Jiri Olsa <jolsa@redhat.com> Cc: John Fastabend <john.fastabend@gmail.com> Cc: KP Singh <kpsingh@chromium.org> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Martin KaFai Lau <kafai@fb.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Song Liu <songliubraving@fb.com> Cc: Stephane Eranian <eranian@google.com> Cc: Yonghong Song <yhs@fb.com> Cc: bpf@vger.kernel.org Cc: netdev@vger.kernel.org Link: http://lore.kernel.org/lkml/20200728085734.609930-4-irogers@google.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
This commit is contained in:
parent
4929e95a14
commit
1b98c6e3ba
|
@ -53,6 +53,7 @@ Following tests are defined (with perf commands):
|
|||
perf record -i kill (test-record-no-inherit)
|
||||
perf record -n kill (test-record-no-samples)
|
||||
perf record -c 100 -P kill (test-record-period)
|
||||
perf record -c 1 --pfm-events=cycles:period=2 (test-record-pfm-period)
|
||||
perf record -R kill (test-record-raw)
|
||||
perf stat -e cycles kill (test-stat-basic)
|
||||
perf stat kill (test-stat-default)
|
||||
|
|
9
tools/perf/tests/attr/test-record-pfm-period
Normal file
9
tools/perf/tests/attr/test-record-pfm-period
Normal file
|
@ -0,0 +1,9 @@
|
|||
[config]
|
||||
command = record
|
||||
args = --no-bpf-event -c 10000 --pfm-events=cycles:period=77777 kill >/dev/null 2>&1
|
||||
ret = 1
|
||||
|
||||
[event:base-record]
|
||||
sample_period=77777
|
||||
sample_type=7
|
||||
freq=0
|
Loading…
Reference in New Issue
Block a user