Skip to content

RFC Tracer Timestamping

Mathieu Desnoyers linux-arch linux-sh lkml 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 RFC Latest15 patches 50 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/15get_cycles() : kconfig HAVE_GET_CYCLESinit/Kconfig+10 -00 replies
2/15get_cycles() : x86 HAVE_GET_CYCLESarch/x86/Kconfig include/asm-x86/tsc.h+13 -00 replies
3/15get_cycles() : sparc64 HAVE_GET_CYCLESarch/sparc/include/asm/timex_64.h arch/sparc64/Kconfig+17 -12 replies
4/15get_cycles() : powerpc64 HAVE_GET_CYCLESarch/powerpc/Kconfig arch/powerpc/include/asm/timex.h+14 -06 replies
5/15get_cycles() : MIPS HAVE_GET_CYCLES_32arch/mips/Kconfig include/asm-mips/timex.h+29 -02 replies
6/15LTTng buildMakefile arch/sparc/Makefile+2 -22 replies
7/15LTTng timestampinit/Kconfig ltt/Kconfig ltt/Makefile +1 more+232 -02 replies
8/15LTTng - Timestampinginclude/asm-generic/ltt.h include/linux/ltt.h kernel/timer.c+82 -00 replies
9/15LTTng mips export hpt frequencyarch/mips/kernel/time.c include/asm-mips/timex.h+3 -00 replies
10/15LTTng timestamp mipsarch/mips/Kconfig include/asm-mips/ltt.h+46 -00 replies
11/15LTTng timestamp powerpcarch/powerpc/Kconfig include/asm-powerpc/ltt.h+38 -00 replies
12/15LTTng timestamp sparc64arch/sparc/include/asm/ltt.h arch/sparc64/Kconfig+36 -00 replies
13/15LTTng timestamp sharch/sh/Kconfig arch/sh/include/asm/ltt.h arch/sh/include/asm/timex.h+54 -10 replies
14/15LTTng - TSC synchronicity testltt/Kconfig ltt/Makefile ltt/ltt-test-tsc.c+136 -00 replies
15/15LTTng timestamp x86arch/x86/Kconfig include/asm-x86/ltt.h+125 -030 replies

Reviews trailers per patch

1 of 15 patches has a Reviewed-by or Acked-by.

PatchDavid S. Miller
1/15
2/15
3/15A-b
4/15
5/15
6/15
7/15
8/15
9/15
10/15
11/15
12/15
13/15
14/15
15/15

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [RFC patch 00/15] Tracer Timestamping

Hi,

Starting with the bottom of my LTTng patchset
(git://git.kernel.org/pub/scm/linux/kernel/git/compudj/linux-2.6-lttng.git)
I post as RFC the timestamping infrastructure I have been using for a while in the tracer. It integrates get_cycles() standardization following David Miller's comments I did more recently.

It also deals with 32 -> 64 bits timestamp counter extension with a RCU-style algorithm, which is especially useful on MIPS and SuperH architectures.

There is also a TSC synchronization test within this patchset to detect unsynchronized TSCs. See comments in this specific patch to figure out the difference between the current x86 tsc_sync.c and the one I propose in this patch.

It also provides an architecture-agnostic fallback in case there is no timestamp counter available : basically, it's
(jiffies << 13) | atomically_incremented_counter (if there are more than 8192 events per jiffy, time will still be monotonic, but will increment faster than the actual system frequency).

Comments are welcome. Note that this is only the beginning of the patchset. I plan to submit the event ID allocation/portable event typing aimed at exporting the data to userspace and buffering mechanism as soon as I integrate a core version of the LTTV userspace tools to the kernel build tree. Other than that, I currently have a tracer which fulfills most of the requirements expressed earlier. I just fear that if I release only the kernel part without foolproof binary-to-ascii trace decoder within the kernel, people might be a bit reluctant to fetch a separate userspace package.

Mathieu

Signature · 3 lines
Mathieu Desnoyers
Computer Engineering Ph.D. Student, Ecole Polytechnique de Montreal
OpenPGP key fingerprint: 8CD5 52C3 8E3C 4140 715F  BA06 3F25 A8FE 3BAE 9A68