[PATCH] D31384: [XRay] [compiler-rt] Write buffer length to FDR log before writing buffer.

Keith via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Mar 27 20:38:26 PDT 2017


kpw added a comment.

I thought about using the header as well. If we go that route, we can't decide to optimize to only flush up through the EOB without confusing readers that aren't equipped with a per buffer frame. It seemed a little odd to have FDR specific fields in the shared header struct as well although we could always fork it into two.

That's fine if we're designing for the common case where recording is turned on for long enough to use many buffers before flushing.

We've got 30 bits left in the bitfield (although Trace.cpp ignores the timespec struct field when reading). xray_buffer_queue.h defines the buffer size as a size_t. What do you think is a reasonable maximum to limit it? I'll change or least comment the header there to keep things honest.


https://reviews.llvm.org/D31384





More information about the llvm-commits mailing list