Skip to content
  • Leo Yan's avatar
    81e70d7e
    perf session: Dump PERF_RECORD_TIME_CONV event · 81e70d7e
    Leo Yan authored
    
    
    Now perf tool uses the common stub function process_event_op2_stub() for
    dumping TIME_CONV event, thus it doesn't output the clock parameters
    contained in the event.
    
    This patch adds the callback function for dumping the hardware clock
    parameters in TIME_CONV event.
    
    Before:
    
      # perf report -D
    
      0x978 [0x38]: event: 79
      .
      . ... raw event: size 56 bytes
      .  0000:  4f 00 00 00 00 00 38 00 15 00 00 00 00 00 00 00  O.....8.........
      .  0010:  00 00 40 01 00 00 00 00 86 89 0b bf df ff ff ff  ..@........<BF><DF><FF><FF><FF>
      .  0020:  d1 c1 b2 39 03 00 00 00 ff ff ff ff ff ff ff 00  <D1><C1><B2>9....<FF><FF><FF><FF><FF><FF><FF>.
      .  0030:  01 01 00 00 00 00 00 00                          ........
    
      0 0 0x978 [0x38]: PERF_RECORD_TIME_CONV
      : unhandled!
    
      [...]
    
    After:
    
      # perf report -D
    
      0x978 [0x38]: event: 79
      .
      . ... raw event: size 56 bytes
      .  0000:  4f 00 00 00 00 00 38 00 15 00 00 00 00 00 00 00  O.....8.........
      .  0010:  00 00 40 01 00 00 00 00 86 89 0b bf df ff ff ff  ..@........<BF><DF><FF><FF><FF>
      .  0020:  d1 c1 b2 39 03 00 00 00 ff ff ff ff ff ff ff 00  <D1><C1><B2>9....<FF><FF><FF><FF><FF><FF><FF>.
      .  0030:  01 01 00 00 00 00 00 00                          ........
    
      0 0 0x978 [0x38]: PERF_RECORD_TIME_CONV
      ... Time Shift      21
      ... Time Muliplier  20971520
      ... Time Zero       18446743935180835206
      ... Time Cycles     13852918225
      ... Time Mask       0xffffffffffffff
      ... Cap Time Zero   1
      ... Cap Time Short  1
      : unhandled!
    
      [...]
    
    Signed-off-by: default avatarLeo Yan <leo.yan@linaro.org>
    Acked-by: default avatarAdrian Hunter <adrian.hunter@intel.com>
    Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
    Cc: Gustavo A. R. Silva <gustavoars@kernel.org>
    Cc: Ingo Molnar <mingo@redhat.com>
    Cc: Jiri Olsa <jolsa@redhat.com>
    Cc: Kan Liang <kan.liang@linux.intel.com>
    Cc: Mark Rutland <mark.rutland@arm.com>
    Cc: Namhyung Kim <namhyung@kernel.org>
    Cc: Peter Zijlstra <peterz@infradead.org>
    Cc: Steve MacLean <Steve.MacLean@Microsoft.com>
    Cc: Yonatan Goldschmidt <yonatan.goldschmidt@granulate.io>
    Link: https://lore.kernel.org/r/20210428120915.7123-5-leo.yan@linaro.org
    
    
    Signed-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
    81e70d7e
    perf session: Dump PERF_RECORD_TIME_CONV event
    Leo Yan authored
    
    
    Now perf tool uses the common stub function process_event_op2_stub() for
    dumping TIME_CONV event, thus it doesn't output the clock parameters
    contained in the event.
    
    This patch adds the callback function for dumping the hardware clock
    parameters in TIME_CONV event.
    
    Before:
    
      # perf report -D
    
      0x978 [0x38]: event: 79
      .
      . ... raw event: size 56 bytes
      .  0000:  4f 00 00 00 00 00 38 00 15 00 00 00 00 00 00 00  O.....8.........
      .  0010:  00 00 40 01 00 00 00 00 86 89 0b bf df ff ff ff  ..@........<BF><DF><FF><FF><FF>
      .  0020:  d1 c1 b2 39 03 00 00 00 ff ff ff ff ff ff ff 00  <D1><C1><B2>9....<FF><FF><FF><FF><FF><FF><FF>.
      .  0030:  01 01 00 00 00 00 00 00                          ........
    
      0 0 0x978 [0x38]: PERF_RECORD_TIME_CONV
      : unhandled!
    
      [...]
    
    After:
    
      # perf report -D
    
      0x978 [0x38]: event: 79
      .
      . ... raw event: size 56 bytes
      .  0000:  4f 00 00 00 00 00 38 00 15 00 00 00 00 00 00 00  O.....8.........
      .  0010:  00 00 40 01 00 00 00 00 86 89 0b bf df ff ff ff  ..@........<BF><DF><FF><FF><FF>
      .  0020:  d1 c1 b2 39 03 00 00 00 ff ff ff ff ff ff ff 00  <D1><C1><B2>9....<FF><FF><FF><FF><FF><FF><FF>.
      .  0030:  01 01 00 00 00 00 00 00                          ........
    
      0 0 0x978 [0x38]: PERF_RECORD_TIME_CONV
      ... Time Shift      21
      ... Time Muliplier  20971520
      ... Time Zero       18446743935180835206
      ... Time Cycles     13852918225
      ... Time Mask       0xffffffffffffff
      ... Cap Time Zero   1
      ... Cap Time Short  1
      : unhandled!
    
      [...]
    
    Signed-off-by: default avatarLeo Yan <leo.yan@linaro.org>
    Acked-by: default avatarAdrian Hunter <adrian.hunter@intel.com>
    Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
    Cc: Gustavo A. R. Silva <gustavoars@kernel.org>
    Cc: Ingo Molnar <mingo@redhat.com>
    Cc: Jiri Olsa <jolsa@redhat.com>
    Cc: Kan Liang <kan.liang@linux.intel.com>
    Cc: Mark Rutland <mark.rutland@arm.com>
    Cc: Namhyung Kim <namhyung@kernel.org>
    Cc: Peter Zijlstra <peterz@infradead.org>
    Cc: Steve MacLean <Steve.MacLean@Microsoft.com>
    Cc: Yonatan Goldschmidt <yonatan.goldschmidt@granulate.io>
    Link: https://lore.kernel.org/r/20210428120915.7123-5-leo.yan@linaro.org
    
    
    Signed-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
Loading