Capstone: Design a Photonic Accelerator

The brief on your desk reads: "Photonic inference accelerator for datacenter deployment. Recommend build / no-build, with numbers." This capstone is that recommendation, assembled from the whole course. You will choose a mesh size, a precision, and a clock; budget every energy line item the last five lessons priced — laser, modulators, detectors, converters, tuning, control — compute the machine's honest TOPS and TOPS/W; and set it against an electronic baseline that will not stand still. Nothing new is introduced here. That is the point: a systems verdict is what the course's pieces look like when they are all forced to be true at once.

Three decisions before any arithmetic

Mesh size N. Bigger amortises the border toll as 1/N (the interface lesson) — but a Clements mesh is N MZIs deep, so insertion loss grows linearly in N and the laser must pay for it exponentially in decibels; area grows as N^2; and the calibration burden grows with every added phase. Precision B. Each bit costs 2\text{–}4\times in conversion energy and — at the shot-noise limit from the precision lesson4\times in received photons, so B is chosen as the smallest number the retrained model tolerates (the co-design lesson's gift), not the largest the hardware can manage. Rate f. Modulators and detectors run happily at many GHz; the converters must run at the same rate, and their power scales linearly with it. Choose N = 64, B = 6, f = 5 GHz as the opening position — then let the calculator argue.

The budget calculator

Every parameter below is a dial the course has explained. The laser line uses the shot-noise photon budget 4^{B} photons per detected symbol, marked up by insertion loss and wall-plug efficiency; conversion uses the Walden scaling \mathrm{FOM}\cdot 2^{B}; tuning is standing power divided by the MAC rate. Run it, read the itemized table — then edit and re-run. Try heaterMW = 0.5 (undercut heaters) or 0 (phase-change weights); try B = 8; try N = 256. Watch which line items trade places at the top of the bill.

// ── Design parameters: edit these and press Run ───────────────── const N = 64; // mesh size (N×N MACs per pass) const bits = 6; // target precision B const rateGHz = 5; // vector rate, GS/s per channel const fomDacFJ = 5; // DAC energy, fJ per conversion-step const fomAdcFJ = 15; // ADC energy, fJ per conversion-step const eModFJ = 50; // modulator + driver, fJ per input symbol const eRxFJ = 80; // TIA + receiver front-end, fJ per output symbol const lossDB = 10; // laser-to-detector insertion loss, dB const wallPlugPct = 20; // laser wall-plug efficiency, % const heaterMW = 5; // standing tuning power per phase shifter, mW const eDigitalFJ = 20; // digital orchestration + SRAM, fJ per MAC const eBaselineFJ = 100; // electronic INT8 accelerator, fJ per MAC (system) // ── Derived per-MAC budget, all in femtojoules ────────────────── const macsPerSec = N * N * rateGHz * 1e9; const dac = (fomDacFJ * Math.pow(2, bits)) / N; // amortised over N MACs const adc = (fomAdcFJ * Math.pow(2, bits)) / N; const mod = eModFJ / N; const rx = eRxFJ / N; const photonFJ = 1.28e-4; // one 1550 nm photon, fJ const laser = (Math.pow(4, bits) * photonFJ // shot-noise photon budget * Math.pow(10, lossDB / 10) // marked up by loss… * (100 / wallPlugPct)) / N; // …and wall-plug efficiency const tuning = (N * (N - 1) * heaterMW * 1e-3 * 1e15) / macsPerSec; const items: [string, number][] = [ ["input DAC", dac], ["modulator + driver", mod], ["laser (wall-plug)", laser], ["mesh tuning (standing)", tuning], ["receiver TIA", rx], ["output ADC", adc], ["digital overhead", eDigitalFJ], ]; console.log("per-MAC budget N=" + N + " B=" + bits + " bits f=" + rateGHz + " GHz"); let total = 0; for (const [name, fj] of items) { total += fj; console.log(" " + name.padEnd(24) + (fj.toFixed(2) + " fJ").padStart(12)); } console.log(" " + "TOTAL".padEnd(24) + (total.toFixed(2) + " fJ").padStart(12)); const tops = (2 * N * N * rateGHz) / 1000; // peak, 2 ops per MAC const watts = total * 1e-15 * macsPerSec; console.log(""); console.log("peak throughput : " + tops.toFixed(1) + " TOPS"); console.log("total power : " + watts.toFixed(1) + " W"); console.log("efficiency : " + (tops / watts).toFixed(2) + " TOPS/W"); const ratio = total / eBaselineFJ; if (total < eBaselineFJ) { console.log("VERDICT: beats the electronic baseline by " + (1 / ratio).toFixed(1) + "x per MAC"); } else { console.log("VERDICT: loses to the electronic baseline by " + ratio.toFixed(1) + "x per MAC"); }

With the defaults, the table delivers this module's thesis in one screen: standing tuning power dominates everything — nearly a picojoule per MAC, some fifty times the conversion lines — and the design loses to electronics by an order of magnitude. Kill the heaters (heaterMW = 0, phase-change or MEMS weights) and the same mesh lands near 40 fJ/MAC, beating the baseline. The difference between a fundable design and a footnote is not the optics at all; it is two boring engineering lines, tuning and conversion, exactly as Lessons 1 and 2 forewarned.

Where the crossover lives

The calculator gives one design at a time; the chart shows the whole design space. Per-MAC energy against mesh size N: the conversion term falls as 1/N, the optics-plus-overhead floor is flat, and the electronic baseline sits at 100 fJ waiting to be undercut. The crossover mesh size — N^* = 2E_{\text{conv}}/(E_{\text{base}} - E_{\text{floor}}) — is the single most important number in your recommendation. Slide the conversion energy (equivalently, the precision) and watch N^* march: cheap 4-bit conversions break even at toy sizes, while 8-bit conversions demand meshes so large that loss, area and calibration (the terms the chart politely omits) come due first.

The verdict

So: build or no-build? The honest recommendation the numbers support is conditional, and the conditions are sharp. Build if the workload offers large, dense, heavily reused matrices (big-batch inference of wide layers); the model tolerates ~4–6 bits after noise-aware retraining; low-standing-power tuning is available; and the product can promise a multi-year efficiency edge, because the electronic baseline improves roughly 2\times every couple of years and — as the end of scaling argued — still has room above its thermodynamic floor. Do not build if the workload is small-batch, dynamic (attention-dominated), or precision-hungry; if conversions cannot be amortised past the crossover; or if the pitch depends on a benchmark boundary the audit checklist would redraw. And in either case, note what the previous lesson observed the market already knows: the same fab line that makes your mesh makes optical I/O that sells today, with no verdict required.

The commonest failure mode of accelerator business plans — photonic or otherwise — is comparing next year's prototype with last year's incumbent. A photonic design that beats today's 20-TOPS/W digital chip by 3\times, shipping in three years, will meet a \sim 2\text{–}4\times better digital chip on arrival: advantage gone, plus you had to build a supply chain. Digital CMOS no longer rides Dennard scaling, but packaging, sparsity, precision tricks and sheer design effort keep compounding — the incumbent improves while standing still architecturally. The defensible photonic pitch is therefore never "we beat this year's GPU by a factor of two"; it is a scaling-law argument — the conversion toll falls as 1/N, bandwidth rises with wavelength count, and no electronic path touches either — projected against the incumbent's curve, with the crossover date stated and defended. If the advantage does not widen with time, it does not exist.

A closing sanity check from thermodynamics. Landauer's bound prices an irreversible bit operation at kT\ln 2 \approx 3 zeptojoules; your best design just celebrated 40 femtojoules per MAC — ten million times the floor, with most of the bill going to moving charge onto capacitors and holding heaters warm, not to computing. The same is true of the digital baseline, of course: nobody in this fight is anywhere near physics. That is the deepest lesson the capstone has to offer. Photonic computing's constraints — conversion, calibration, memory — are engineering walls, not laws of nature, and the reversible-computing course's heat-wall analysis applies to optics with full force: light itself dissipates nothing as it interferes — a lossless mesh is a unitary, energy-conserving by construction — and every joule in your budget table is spent at the edges, where photons meet electrons. The mesh is thermodynamically innocent; its entourage is not. Whether anyone can ever compute usefully near that innocence is one of the great open questions this course hands to the next one.

The end of the course: where light computes next

Eleven modules ago this course asked what computers gain when information rides on light. The answer assembled itself in three registers. What shipped: interconnect — photons carrying bits between electronic chips, from co-packaged optics to circuit switches, the one photonic business that never needed a pivot. What is fighting for its life: analog photonic compute, physically sound, systemically taxed, waiting on cheap conversion and cold tuning to cross the line your calculator drew. What plays the long game: photonic quantum machines, betting that light's coherence will matter more than its bandwidth. Whatever the outcomes, the pattern of this final module will hold: in photonics, systems eat physics — every wonder priced at the boundary, every verdict written in femtojoules. You now own the full audit toolkit: the transfer functions, the meshes, the noise budgets, the checklists, and the healthy reflex of asking, before anything else, who pays for the conversions? Light will keep its promises where those books balance — and you can now do the books.