Bitcoin Institute

Ray Dillinger interview — early Bitcoin code reviewer recalls Satoshi's design choices

A dark navy infographic in which a magnifying glass inspects rows of ledger text, a decimal value sits beside a whole-number value in bordered boxes, a cracked jar spills coins beside a row of coins, and a glowing cluster of small hardware icons stands out on a stylized map.

For the Bitcoin whitepaper’s 10th anniversary, Tim Swanson of Great Wall of Numbers interviewed Ray Dillinger about the code review he did for Satoshi in November 2008. The full interview is here. Dillinger says Satoshi sent him the proof-chain code directly and that he found it, in his own words, “solid” — interesting enough, he says, that a system with no Trusted Roles at all was something “nobody had EVER come up with before.”

The most consequential thing Dillinger found was a design choice that should not have worked: Bitcoin’s accounting used floating-point numbers rather than integers, “a combination with a long and horrible history” that made him panic when he first spotted it. Satoshi’s reasoning, as Dillinger recounts it, was compatibility with JavaScript, which has no other numeric type, combined with a determination to squash rounding-error bugs before they could let different clients compute different answers and fork the chain. Dillinger’s own instinct ran the other way — “screw Javascript, I want rounding errors to be impossible” — but when he combed the accounting code for rounding errors afterward, he found none.

The reason, as he explains it, is that the satoshi was sized to sit just above the precision floor of double-precision floats, so that no operation touching satoshi-sized units could round at all short of adding or subtracting more than 21 million bitcoins. Hal Finney, who had handled exact floating-point math in his PGP work, was less alarmed by the design than Dillinger was; the two of them debated whether satoshis should be sized with more cushion against rounding error or kept near the precision limit so that any error would fail immediately and detectably.

Quote from: Ray Dillinger on October 01, 2018

In a fixed-supply economy, holding coins is a risk-free investment guaranteed to rise at the market average rate, so rational investors hoard rather than invest in productive businesses.

Dillinger reaches for ancient Rome to make the point concrete: a metal-backed currency whose economy collapsed even while people held plenty of it, because everyone hoarded coins against future gains instead of funding the businesses that would have produced them — “we are STILL finding stashes of Roman coins” fifteen centuries later. The same hoarding mechanic runs through Bitcoin’s own history: the scarcity that gives it value is the same scarcity that wore down its use as cash.

On mining, Dillinger doesn’t think Satoshi anticipated ASICs concentrating hashing power wherever electricity subsidies made mining cheapest, putting a majority of it at the mercy of a single government’s policy. That risk had already materialized a year before this interview: China’s 2017 ICO and exchange ban put a significant share of Bitcoin’s hash rate then based in the country at the mercy of a single government, until miners relocated abroad.

This interview supplies the technical substance behind the pre-release audit summarised in the Ray Dillinger biography, and complements his first-person retrospective “If I’d known then what I know now”, which gives the who, when, and why of the same November 2008 review this interview documents in technical detail.