Skip to content

Commit e65f91b

Browse files
Kan Liangacmel
authored andcommitted
perf test x86: Support the retire_lat (Retire Latency) sample_type check
Add test for the new field for Retire Latency in the X86 specific test. Signed-off-by: Kan Liang <[email protected]> Tested-by: Arnaldo Carvalho de Melo <[email protected]> Cc: Andi Kleen <[email protected]> Cc: Ian Rogers <[email protected]> Cc: Ingo Molnar <[email protected]> Cc: Peter Zijlstra <[email protected]> Cc: Stephane Eranian <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
1 parent ee739f1 commit e65f91b

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

tools/perf/arch/x86/tests/sample-parsing.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,10 @@ static bool samples_same(const struct perf_sample *s1,
2727
const struct perf_sample *s2,
2828
u64 type)
2929
{
30-
if (type & PERF_SAMPLE_WEIGHT_STRUCT)
30+
if (type & PERF_SAMPLE_WEIGHT_STRUCT) {
3131
COMP(ins_lat);
32+
COMP(retire_lat);
33+
}
3234

3335
return true;
3436
}
@@ -48,6 +50,7 @@ static int do_test(u64 sample_type)
4850
struct perf_sample sample = {
4951
.weight = 101,
5052
.ins_lat = 102,
53+
.retire_lat = 103,
5154
};
5255
struct perf_sample sample_out;
5356
size_t i, sz, bufsz;

0 commit comments

Comments
 (0)