Linux Kernel's Perf Now Supports Zstd-Compressed Trace Recording

Written by Michael Larabel in Linux Kernel on 19 May 2019 at 07:46 AM EDT. Add A Comment
LINUX KERNEL
Late updates to the Linux kernel's perf subsystem introduces support for compressed recording of traces, which can yield a three to five time reduction in file-size.

The run-time trace compression and auto-decompression is actually a very useful feature in the context of the Perf subsystem with those records easily hitting many GB in size if making a recording of the events for any real length of time.

Particularly on bigger systems this Zstd-compressed recording can be very valuable: "saves storage space on larger
server systems where perf.data size can easily reach several tens or even hundreds of GiBs, especially when profiling with DWARF-based stacks and tracing of context switches.
"

Compression is activated with the -z switch and there is also a --compression_level= flag supported. This streaming compression of perf ring buffers was sent in via the perf tooling updates and is marked as "RFC" since it's coming in late, so we're still waiting to see if Linus Torvalds decides to pull this support into the Linux 5.2 kernel or will have to wait for Linux 5.3.
Related News
About The Author
Michael Larabel

Michael Larabel is the principal author of Phoronix.com and founded the site in 2004 with a focus on enriching the Linux hardware experience. Michael has written more than 20,000 articles covering the state of Linux hardware support, Linux performance, graphics drivers, and other topics. Michael is also the lead developer of the Phoronix Test Suite, Phoromatic, and OpenBenchmarking.org automated benchmarking software. He can be followed via Twitter, LinkedIn, or contacted via MichaelLarabel.com.

Popular News This Week