mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* Adding MSR trace points, new edition
@ 2015-10-21 20:14 Andi Kleen
  2015-10-21 20:14 ` [PATCH 1/4] x86: Don't include asm/processor.h into asm/atomic.h Andi Kleen
                   ` (3 more replies)
  0 siblings, 4 replies; 6+ messages in thread
From: Andi Kleen @ 2015-10-21 20:14 UTC (permalink / raw)
  To: x86; +Cc: rostedt, peterz, linux-kernel

[v2: Move trace header into architecture specific include]

For debugging perf it's very useful to trace CPU MSR read / writes.
perf has a hackish way to do it, but it does not support reads,
requires hacking a header file, and cannot be used with triggers.

MSR accesses are inlined, which makes it difficult to directly
add trace points to them.

I posted a patch some time ago that moved them out of line
to make it possible to trace them.

Steven proposed a different approach of open coding the trace point
static key access. This patchkit implements the different approach.

To avoid include loops, it required some changes in the trace point
and in the x86 headers. These can be considered cleanups in thri own.
This is implemented in the first two patches.

Then the later patch adds the actual trace points, and a pretty
printing script for them, and then finally removes the old hackish
perf MSR tracing.



^ permalink raw reply	[flat|nested] 6+ messages in thread
* Adding MSR trace points, new edition
@ 2015-10-20 18:40 Andi Kleen
  0 siblings, 0 replies; 6+ messages in thread
From: Andi Kleen @ 2015-10-20 18:40 UTC (permalink / raw)
  To: x86; +Cc: rostedt, peterz, linux-kernel

For debugging perf it's very useful to trace CPU MSR read / writes.
perf has a hackish way to do it, but it does not support reads,
requires hacking a header file, and cannot be used with triggers.

MSR accesses are inlined, which makes it difficult to directly
add trace points to them.

I posted a patch some time ago that moved them out of line
to make it possible to trace them.

Steven proposed a different approach of open coding the trace point
static key access. This patchkit implements the different approach.

To avoid include loops, it required some changes in the trace point
and in the x86 headers. These can be considered cleanups in thri own.
This is implemented in the first two patches.

Then the later patch adds the actual trace points, and a pretty
printing script for them, and then finally removes the old hackish
perf MSR tracing.


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2015-10-21 20:20 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-10-21 20:14 Adding MSR trace points, new edition Andi Kleen
2015-10-21 20:14 ` [PATCH 1/4] x86: Don't include asm/processor.h into asm/atomic.h Andi Kleen
2015-10-21 20:14 ` [PATCH 2/4] tracepoints: Move struct tracepoint to new tracepoint-defs.h header Andi Kleen
2015-10-21 20:14 ` [PATCH 3/4] x86: Add trace point for MSR accesses Andi Kleen
2015-10-21 20:14 ` [PATCH 4/4] perf, x86: Remove old MSR perf tracing code Andi Kleen
  -- strict thread matches above, loose matches on Subject: below --
2015-10-20 18:40 Adding MSR trace points, new edition Andi Kleen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®