← Back to section · Research & Analysis

The Performance Weight of Sampling: The Invisible Half of the Cost

Rejection sampling, binomial sampling, and discrete Gaussian sampling differ by orders of magnitude in cost. This article analyzes the performance weight of sampling in ML-KEM, ML-DSA, Falcon, and SLH-DSA, and why it is so often the missing column in benchmark tables.

Published 22 November 2026 · 5 min read · PQ Frontier

The Performance Weight of Sampling: The Invisible Half of the Cost
AI-generated site artwork
Video explainer · Algorithm Performance: Benchmarks and Methods

When people discuss PQC performance, they tend to stare at multiplications and transforms. But under a profiler, another stage quietly consumes a third or more of the cycles: sampling — turning a stream of random bytes into coefficients, noise, and challenge values that follow a prescribed distribution. The sampling method is written into the algorithm specification itself, and which distribution is chosen, and how it is generated, directly determines a large part of the performance map. This article lines up four representative sampling methods, ordered from cheapest to most expensive.

Binomial sampling: cheap for a reason

The noise in ML-KEM and ML-DSA comes from the centered binomial distribution (CBD): take a string of random bits, count the ones in two halves, and subtract. With parameter η equal to 2 or 3, each coefficient needs only a handful of bits and a few additions. It is cheap to the point of being nearly free, for two reasons: the distribution’s shape emerges naturally from bit counting, with no rejection and no table lookups; and its secret-independent, publicly parameterized construction makes constant-time implementation effortless. In performance profiles, CBD sampling’s share is so small it is usually folded into an “other” row. That is not an oversight — the designers deliberately made noise generation the lightest stage of the pipeline.

Rejection sampling: throughput throttled by the hash

Generating the matrix A is a different picture. ML-KEM expands a seed with SHAKE128 into a byte stream, then compares each 12-bit chunk against the modulus 3329, discarding and retrying on overflow. The rejection rate is set by 3329/4096: roughly one in five candidates is thrown away. The true cost of this stage is therefore SHAKE’s output throughput multiplied by an expansion factor of about 1.23. The Keccak permutation works on fixed-size blocks; the longer the output, the more rounds run, so cost scales strictly with matrix size. For ML-KEM-1024 with k=4, sixteen polynomial positions of matrix elements must be expanded — this pipeline is the widest pipe in key generation.

ML-DSA pushes rejection sampling into another dimension: the entire signing procedure is a loop — generate a mask, compute the challenge, form the response, check the norm bounds, and restart the whole round on failure. The iteration count follows a geometric distribution whose expectation is set by parameters such as β and γ, typically in the single digits, but the distribution has a tail: an unlucky run of a dozen-plus rounds is not rare. This yields a key corollary for reading benchmarks: ML-DSA signing time is intrinsically a random variable, and quoting an “average signing time” conceals the tail latency. Latency-sensitive systems should look at high percentiles, not the mean.

Discrete Gaussian sampling: Falcon’s solitary road

Falcon’s signing requires discrete Gaussian sampling over a lattice, using recursive trapdoor sampling with floating-point arithmetic. It is the only mainstream PQC scheme that puts Gaussian sampling on the hot path, and its cost structure differs completely from its peers: the computation itself is substantial, and the numerical-precision and constant-time requirements of floating-point Gaussian sampling pull against each other — every step of the sampler must carefully avoid timing leakage. The result is Falcon’s distinctive profile: verification is extremely fast (NTT-domain multiplication and hashing only), while signing is markedly slower and far harder to implement. Reading only Falcon’s verification numbers badly understates its engineering cost on the signing side.

Sampling’s hidden dividing line: public versus secret

Sampling conceals a further dividing line with direct performance consequences: whether the data being sampled is secret. The rejection sampling of matrix A handles public values; its speed and rejection counts leak nothing, so implementations may freely use variable-time code and early exits — whatever is fastest. Sampling tied to noise and secrets is entirely different: if the noise and challenge sampling inside ML-KEM decapsulation and ML-DSA signing takes time that varies with the sampled values, it forms a timing-leakage surface and must be made constant-time. The same “rejection sampling” code is free on a public path and taxed on a secret path. This explains a common implementation arrangement: sampling code is often maintained in two variants, public and secret, even when they generate identical distributions. When a profiling write-up shows a sampler that looks “clumsily written,” first check whether it handles secrets — the clumsiness may be the shape of the tax, not implementer negligence.

The coupling to the randomness source is another frequently unrecorded bill. All sampling consumes a downstream stream of random bytes, and in high-frequency signing scenarios the expansion throughput of the system entropy source and the deterministic random bit generator (DRBG) becomes the upstream bottleneck: no sampler outruns the byte stream feeding it. A complete performance profile of sampling must meter this upstream pipe as well.

The control group that barely samples: SLH-DSA

For contrast, SLH-DSA performs almost no distributional sampling: its secret key is simply a seed, and signing is repeated evaluation of hash chains and Merkle trees, with randomness appearing only in the pseudorandom generation of FORS keys. Its performance profile is therefore unusually “pure” — cost is determined almost entirely by the number of hash invocations, and the sampling weight is close to zero. Placing the four schemes side by side, sampling weight runs from CBD’s near-zero, through rejection sampling’s middle range, up to Gaussian sampling’s dominant share — tracing the full spectrum of the PQC family along the dimension of “randomness processing.”

Summary

Sampling is the processing stage that connects random bytes to an algorithm’s internal state, and its cost is set by the shape of the distribution and the generation method: binomial sampling is nearly free, rejection sampling bills most of its cost to hash throughput and gives signing time a distributional tail, and discrete Gaussian sampling is a heavy asset that Falcon carries alone. When dissecting any PQC performance figure, ask first: how much of it is sampling, and of which kind? That determines whether the speed you see is dictated by algorithm structure, or by where an implementation cut corners in the pipeline.

References

  • FIPS 203, Chapter 7 — definitions of the sampling algorithms (SampleNTT and SamplePolyCBD)
  • FIPS 204 — on ML-DSA’s signing rejection loop and its parameters (β, γ₁, γ₂)
  • The FN-DSA (Falcon) draft specification — implementation requirements for Gaussian sampling

Tags: SamplingRejection SamplingFalconPerformance Profile