]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
perf arch x86 tests: Add test for topdown event sorting
authorIan Rogers <irogers@google.com>
Mon, 18 May 2026 06:29:04 +0000 (23:29 -0700)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Wed, 20 May 2026 21:24:01 +0000 (18:24 -0300)
commitb439c20b2fe1cfed2210e50c06006845ae424c48
tree4b555be836abe965fed7e01ac74aab5185cb80e1
parent9f116f4b811b5846808e27507a3aa2824819edeb
perf arch x86 tests: Add test for topdown event sorting

Add a test to capture the comment in tools/perf/arch/x86/util/evlist.c.

Test that slots and topdown-retiring get appropriately sorted with
respect to instructions when they're all specified together.

When the PMU requires topdown event grouping (indicated by the pressence
of the slots event) metric events should be after slots, which should be
the group leader.

Add a related test that when the slots event isn't given it is injected
into the appropriate group.

Signed-off-by: Ian Rogers <irogers@google.com>
Tested-by: Zide Chen <zide.chen@intel.com>
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Cc: Collin Funk <collin.funk1@gmail.com>
Cc: Dmitrii Dolgov <9erthalion6@gmail.com>
Cc: German Gomez <german.gomez@arm.com>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: James Clark <james.clark@linaro.org>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/arch/x86/tests/topdown.c