Concepts

Performance

Every number on this page comes from one results file, measured with Peel 1.4.0, with the method, the limits and the script to repeat it.

Peel 1.4.0 · Snack Studio · Updated

What was measured

The measurements live in one file, engine-scores.json, and the engine page draws from it. They were taken on 2026-11-25 with Peel 1.4.0 on an Apple M4 Pro with 14 cores, under macOS 27.2.1. The reference tools were zstd 1.5.7, Apple gzip, xz 5.8.4 and bzip2 1.0.8.

There are two test files:

File What it is Size in bytes
Program Peel’s own command-line tool 18,913,504
Source A tar of Peel’s Rust and Swift source 5,171,200

A third test unpacks a tree of 1,151 files from Peel’s repository, 64,391,997 bytes in all, that Peel packed as ZIP, .tar.zst, .tar.gz, .tar.xz and 7z, once with Peel and once with macOS’s bsdtar.

The method, as the file records it:

One machine, one afternoon. The load average was 5.2 at the start of the run and 7.27 at the end, so other work was running. Treat the numbers as a fair comparison on this Mac, not a promise for yours. The next section shows how to repeat the run on your own.

Packing

Median milliseconds to compress, Peel and the reference tool, per format, with the compression ratio. Shorter is faster.Peelthe format’s own toolzstPeel: 29 ms, 2.39×29 ms · 2.39×zstd: 29 ms, 2.39×29 ms · 2.39×gzPeel: 505 ms, 2.32×505 ms · 2.32×gzip: 498 ms, 2.32×498 ms · 2.32×xzPeel: 4054 ms, 3.25×4054 ms · 3.25×xz: 3993 ms, 3.25×3993 ms · 3.25×bz2Peel: 825 ms, 2.45×825 ms · 2.45×bzip2: 848 ms, 2.47×848 ms · 2.47×
Packing an 18.9 MB program: Peel against each format’s own tool. Median of 5 runs, peel 1.4.0 on an Apple M4 Pro, measured 2026-11-25. Raw data.
Show the numbers
FormatPeel msTool msRatioWeissman
zst29zstd 292.39×1.90
gz505gzip 4982.32×1.00
xz4054xz 39933.25×1.04
bz2825bzip2 8482.45×0.98

For the program file, Peel and each format’s own tool land in the same place. The ratio is the same for gzip (2.3238 against 2.3238) and xz (3.2475 against 3.2475). Packing time is within a few percent for every format: gzip 504.68 ms against 498.17 ms, xz 4,053.85 ms against 3,993.15 ms, bzip2 825.38 ms against 847.99 ms. Peel’s bzip2 ran at level 6 and the reference at level 9, which is why its ratio is a little lower, 2.452 against 2.4711.

The one place Peel’s output is far from gzip -6 is Zstandard. At the default level 3, Peel packs the program in 28.95 ms to a ratio of 2.3937, while gzip -6 takes 504.68 ms for 2.3238. That gap, a smaller file made much faster, is what the headline score measures. Against zstd itself, Peel is level: 28.95 ms against 28.55 ms, at the same ratio of 2.3937.

The encoders have moved on since this run. The 1.4.0 results above predate several changes in the source. The code after 1.4.0 compresses small inputs on more cores for zstd and xz and adds parallel gzip and bzip2 writers, described under How Peel packs on every core. The results file has not been re-measured for them, so the chart shows 1.4.0.

The Weissman score

The Weissman score was invented for HBO’s Silicon Valley. It folds compression ratio and packing time into one number, relative to a reference. The definition used here:

Text
W = α × (r / r̄) × (log T̄ / log T)
Symbol Meaning
r The tool’s compression ratio, how many times smaller the file gets
r̄ The reference’s ratio. The reference is gzip -6 on the same file
T The tool’s packing time, in milliseconds
T̄ The reference’s packing time
α A scaling constant, 1 here, so the reference scores exactly 1.00

Peel’s Zstandard on the program file scores 1.901, which the engine page rounds to 1.90 and states as +90% against gzip -6. The other three formats score near 1.0 on the same file: gzip 0.998, xz 1.045 and bzip2 0.976, against 1.0 for the reference itself.

The limits matter more than the number:

The engine page also offers other scores from the same file, among them a composite and a Pareto frontier of size against speed. No single score says which tool is best.

Unpacking

Median milliseconds to unpack, Peel and bsdtar, per format. Shorter is faster.PeelbsdtarzipPeel: 105 ms105 msbsdtar: 245 ms245 mstar.zstPeel: 125 ms125 msbsdtar: 154 ms154 mstar.gzPeel: 155 ms155 msbsdtar: 228 ms228 mstar.xzPeel: 1079 ms1079 msbsdtar: 1218 ms1218 ms7zPeel: 1224 ms1224 msbsdtar: 1301 ms1301 ms
Unpacking the same 1,151-file tree: Peel against bsdtar. Median of 5 runs, peel 1.4.0 on an Apple M4 Pro, measured 2026-11-25. Raw data.
Show the numbers
FormatFilesPeel msbsdtar msUnpack score
zip11511052451.18
tar.zst11511251541.04
tar.gz11511552281.08
tar.xz1151107912181.02
7z1151122413011.01

Peel was faster than bsdtar on all five formats in this tree, by different margins:

Format Peel bsdtar
ZIP 104.75 ms 244.55 ms
.tar.gz 155.44 ms 227.74 ms
.tar.zst 125.15 ms 153.75 ms
.tar.xz 1,079.03 ms 1,218.02 ms
7z 1,224.35 ms 1,300.75 ms

The gap is widest for ZIP and narrowest for 7z and .tar.xz. For the compressed single files, decoding the program file to a file, Peel and the reference tool are close, and neither always wins: .zst 22.2 ms against 20.43 ms for zstd, .gz 34.29 against 32.77, .xz 211.3 against 206.63, and .bz2 378.73 against 431.82.

One detail of the method: bsdtar here is tar -x fed by the tool’s own -d -c, because Peel opens a tar it finds inside a compressed file by itself.

Memory

Peel streams and does not load an archive into memory. These are bytes of peak resident size on the program file:

Format Peel, packing Tool, packing Peel, unpacking Tool, unpacking
zst 35,307,520 36,503,552 47,923,200 8,224,768
gz 4,947,968 1,572,864 44,548,096 1,327,104
xz 102,285,312 124,682,240 53,116,928 35,438,592
bz2 9,191,424 7,798,784 47,677,440 4,800,512

Peel’s unpacking peaks at between 44,548,096 and 53,116,928 bytes for every format here, higher than each reference tool. It is bounded, but it is not the lowest.

Reading part of a file

peel cat --offset N --length N returns a window of one member instead of the whole thing. The same read is available as the MCP read_member tool with offset and length, and as peel_session_read_member_range in the C library.

peel cat demo.zip project/docs/chapter-1.md --offset 10 --length 30; echo " [exit $?]"; peel cat demo.zip project/docs/chapter-1.md --max-bytes 100; echo "exit $?"
lorem ipsum dolor sit amet lor [exit 0]
peel: project/docs/chapter-1.md is larger than the read limit of 100 bytes; raise it with --max-bytes
exit 10
Real output from peel 1.4.0, recorded 2026-11-26.

What it costs depends on the format, and the honest rule is simple:

The results file measures one case: a 1 MiB read from the middle of the program file Peel made, against decoding the whole file. The reading is Peel’s peel cat --offset --length, and times include starting the program.

Format 1 MiB from the middle The whole file
zst 11.48 ms 22.2 ms
gz 18.39 ms 34.29 ms
xz 115.67 ms 211.3 ms
bz2 206.7 ms 378.73 ms

Each window read costs about half the full decode. That is consistent with the rule above: decode from the start up to the middle of the file, then stop. The other tools cannot read part of a file, so they have no comparison row. The cost of a read grows with its offset, so a window near the end of a large compressed member costs nearly a full decode.

Random access is not density. A window read avoids the work after the window. It does not make a file smaller or a full decode cheaper.

How Peel packs on every core

peel create uses every core the system reports. How it does so differs by format, and the output is always a standard file that stock tools read:

Of these, multithreaded zstd and xz are in 1.4.0. The per-core zstd jobs, the small xz blocks and the parallel gzip and bzip2 writers are in the source after 1.4.0, so the 1.4.0 results above do not include them.

Measure it yourself

The script that wrote the results file is in the repository and uses only the Python standard library:

TerminalShell
python3 scripts/measure-engine-scores.py --peel "$(command -v peel)" --runs 5 --sweep-runs 3

It writes site/data/engine-scores.json and a CSV beside it. It needs zstd, gzip, xz and bzip2 on the path, macOS’s bsdtar, and a git checkout of the repository, because the unpack test packs its tracked Rust and Swift files. Quit other work first, record the load average, and measure the build you will ship: the numbers in the results file name the release they describe.

To time your own data, run the commands the script runs:

TerminalShell
time peel create -q -f out.tar.zst ~/Project
time peel x -q -f -o scratch out.tar.zst
time peel cat -q --offset 5000000 --length 1048576 out.tar.zst path/in/archive > /dev/null

See the CLI reference for the options, architecture for how a read flows, and the engine page for the charts and the downloads.