perf test: Test 2 libpfm4 error cases
authorIan Rogers <irogers@google.com>
Wed, 19 May 2021 15:12:13 +0000 (08:12 -0700)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Thu, 27 May 2021 16:55:28 +0000 (13:55 -0300)
Proposed in:

https://lore.kernel.org/lkml/20210517140931.2559364-1-tmricht@linux.ibm.com/

Signed-off-by: Ian Rogers <irogers@google.com>
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Mark Rutland <mark.rutland@arm.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Stephane Eranian <eranian@google.com>
Cc: Thomas Richter <tmricht@linux.ibm.com>
Link: http://lore.kernel.org/lkml/20210519151213.2643570-1-irogers@google.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/tests/pfm.c

index d4b0ef7..acd5094 100644 (file)
@@ -155,6 +155,16 @@ static int test__pfm_group(void)
                        .nr_events = 3,
                        .nr_groups = 1,
                },
+               {
+                       .events = "instructions}",
+                       .nr_events = 1,
+                       .nr_groups = 0,
+               },
+               {
+                       .events = "{{instructions}}",
+                       .nr_events = 0,
+                       .nr_groups = 0,
+               },
        };
 
        for (i = 0; i < ARRAY_SIZE(table); i++) {