Brainstorming new kernel interfaces for rr

Chris Jones jones.chris.g at
Tue Feb 25 21:29:14 PST 2014

I don't want to distract anyone from 1.0, but we've run into enough tracing
shortcomings that I think we can start putting together a "kernel
wishlist".  This stuff can take awhile to trickle out to where rr users
will be able to take advantage, so it makes sense to front load.  Here's my
strawman list

 - in-kernel buffering of syscall outparam data.  Syscallbuf+vsyscall
hooking works OK in practice, but the kernel can do so much better, so much
more easily.  Essentially it "just" has to record copy_to_user() within
syscall handlers, plus a bit of metadata.  Perhaps could be exposed through

 - trapping on CPUID, like the RDTSC traps.  Modern Intel chips can do this.

 - expose Branch Trace Store data, probably through perf_event.  There was
a previous attempt to do this, but I think it fizzled out.

 - implement a way for ptrace tracers to efficiently wait on a tracee's
private futex

 - we hit a pwrite64/pread64 bug that we shouldn't let slip through the

Anything else to add?

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the rr-dev mailing list