Advanced & Emerging Architectures
Chapter: 6.5 Advanced & Emerging Architectures Level: 5 — Mastery (cross-domain: math + physics + coding, build/prove) Time limit: 2 hours 30 minutes Total marks: 100
Instructions: Answer all three questions. Show derivations fully; state assumptions explicitly. Numerical answers must carry units and be justified. Partial credit follows the mark scheme.
Question 1 — Systolic Arrays, HBM Bandwidth & the Roofline (36 marks)
A domain-specific accelerator uses an output-stationary systolic array of MAC (multiply-accumulate) processing elements running at clock frequency . It computes dense matrix multiplication where is and is , all in bf16 (2 bytes/element). Weights and activations stream from an HBM3 stack.
(a) Derive the peak throughput of the array in FLOP/s. Take , , and count one MAC as 2 FLOP. Give the numeric peak. (6)
(b) The systolic array has fill (latency) overhead: for a single tile the pipeline takes cycles to fill before the first full column of results emerges, then produces results every cycle. For a full by multiply tiled into blocks, derive the hardware utilization (useful MAC-cycles / total MAC-cycles) as a function of assuming is streamed through each tile (accumulation dimension). Evaluate for , . (8)
(c) One HBM3 stack delivers . Using the arithmetic-intensity roofline model, derive the arithmetic intensity (FLOP/byte) at the ridge point where the machine transitions from memory-bound to compute-bound. Use your part (a) peak. (7)
(d) For the multiply of part (b) (... use , tiling), compute the operational intensity of the whole GEMM assuming each of , read once from HBM and written once. State whether this workload is compute- or memory-bound on this machine, and give the achievable throughput. (9)
(e) Argue quantitatively why increasing improves operational intensity for square GEMM, and name one physical constraint from 2.5D/3D packaging that bounds how large (and on-die SRAM) can grow. (6)
Question 2 — Quantum Hardware, Coherence & Error Budget (32 marks)
A superconducting transmon quantum processor has single-qubit gate time and qubit relaxation time , dephasing time .
(a) The probability that a qubit in has not decayed after time is . Derive the per-gate error contribution from relaxation for one gate, (state the small- approximation used and its justification). Compute . (8)
(b) A circuit must run for depth gates on one qubit within the coherence-limited window. Define the "gate budget" as the number of gates before accumulated single-qubit error reaches (assuming errors add linearly for small , using the combined ). Derive and compute this budget . (8)
(c) Surface-code quantum error correction requires physical error rate below threshold and needs roughly physical qubits per logical qubit (distance ), with logical error suppressed as . Given physical error , , find the smallest odd distance giving , and the physical-qubit cost per logical qubit. (10)
(d) Contrast, in physical terms, why photonic interconnects (6.5.15/6.5.18) are attractive for linking quantum/cryogenic modules but why the qubits themselves are not simply "run faster" — connect to the coherence argument above. (6)
Question 3 — Build & Prove: Approximate MAC + Dataflow Energy (32 marks)
You will design and analyze an approximate fixed-point accelerator datapath and reason about its dataflow.
(a) Consider an approximate multiplier that truncates the lower bits of each -bit unsigned operand before multiplying (operands in ). Derive the maximum relative error of the product vs. exact as a function of and (worst case, non-trivial operands). Bound it and evaluate for , . (9)
(b) Write pseudocode (or Python) for the approximate MAC accumulating products, and give the worst-case bound on accumulated absolute error over terms. State how error-averaging (statistical, uniform inputs) changes the expected error growth (scaling with ). (9)
(c) In a weight-stationary dataflow, energy per MAC is dominated by data movement: where accesses at level (RF, SRAM, DRAM/HBM) have relative energy costs (per byte). For a convolution reusing each weight times, derive the amortized DRAM energy per MAC and show the reuse factor at which SRAM access dominates DRAM. Take ranging; find where . (8)
(d) Prove that approximate computing gives no benefit for a workload whose correctness constraint requires bit-exact reproducibility, and give one realistic domain-specific accelerator workload (from 6.5.6) where approximation is safe and why. (6)
End of paper.
Answer keyMark scheme & solutions
Question 1
(a) Peak = (number of MACs) × (MACs/cycle each) × × (FLOP/MAC).
- PEs, each 1 MAC/cycle. (2)
- MAC-rate MAC/s. (2)
- Peak FLOP/s FLOP/s TFLOP/s. (2)
(b) Number of tiles: row-blocks × ... For GEMM by with tile:
- Number of output tiles tiles when output width = . Each tile streams elements of the accumulation dimension.
- Per tile: fill cycles, then useful cycles (streaming accumulations). Total cycles per tile . Useful cycles .
- Utilization . (5)
- Evaluate: . (3)
(Fill overhead is amortized over the streamed cycles; larger → higher .)
(c) Ridge point: . (3)
- FLOP/byte. (4)
Below memory-bound; above, compute-bound.
(d) GEMM with , (square whole-GEMM operational intensity — tiling internal):
- FLOP FLOP. (2)
- Bytes (bf16, 2 B): read () + read () + write () B. (2)
- FLOP/byte. (2)
- → compute-bound. (1)
- Achievable throughput ≈ peak × utilization TFLOP/s (compute-bound, so memory not limiting). (2)
(e) For square GEMM, FLOP (per block) while HBM traffic , so — bigger tiles reuse each loaded element more, raising intensity linearly. (3) Physical constraints from packaging: on-die SRAM to hold an tile grows as , and the interposer/TSV area, thermal density (power/area, cooling through stacked dies), and reticle/interposer size limit die area, capping and SRAM. (3)
Question 2
(a) . Small-: , so . (3) Error averaged over states (qubit equally in ; only decays) gives factor : . (3)
- . (2)
(b) Combined decoherence per gate . (3)
- Linear accumulation: gates. (5)
(c) Need , with , .
- → → → . (6)
- Smallest odd . (2)
- Physical qubits per logical qubit. (2)
(d) Photonic links (6.5.15/6.5.18) move information between cryostats/modules at low loss and no resistive heat dissipation in the fiber, ideal for scaling out modules and cutting cryogenic heat load. (3) But qubit operation speed is bounded by coherence, not link bandwidth: gates faster than risk leakage/control-bandwidth errors, and coherence () sets the fixed error-per-gate — "running faster" doesn't extend the coherence window, so optics help interconnect, not qubit fidelity. (3)
Question 3
(a) Truncating bits: , similarly . Max truncation loss per operand .
- , . Error ; worst-case relative error dominated by terms. (3)
- Worst relative error when operands are small but threshold; bound: for operands with MSB set (), . (3)
- : worst case (bounded operands). (3)
(b) Pseudocode:
def approx_mac(xs, ys, b):
acc = 0
for x, y in zip(xs, ys):
xt = x & ~((1<<b)-1) # truncate low b bits
yt = y & ~((1<<b)-1)
acc += xt * yt
return acc(3) Worst-case absolute error per product ; over terms adds linearly: (loose). Grows . (3) For uniform random inputs, truncation errors are zero-mean-ish and partly independent → expected error grows as (central-limit), not ; so statistical averaging keeps relative accumulation error . (3)
(c) DRAM read once per weight, reused times → amortized DRAM energy per MAC . (3) SRAM accessed each MAC: . (2) Crossover: . So for reuses, DRAM is no longer dominant and SRAM access dominates. (3)
(d) If correctness demands bit-exact output, any approximation changes bits → violates constraint by definition, so accuracy-for-energy trade is unusable (must run exact path). (3) Safe example (6.5.6): a neural-network inference accelerator (e.g., image classifier) — outputs are argmax class labels robust to low-order-bit noise; quantization/approximate MACs shift logits negligibly and rarely flip the top-1 result, saving energy. (3)
[
{"claim":"Q1a peak = 32.768 TFLOP/s","code":"N=128;f=1.0e9;peak=2*N*N*f;result=abs(peak-3.2768e13)<1e9"},
{"claim":"Q1b utilization = 1024/1279","code":"K=1024;N=128;eta=K/(K+2*N-1);result=abs(eta-0.8006)<1e-3"},
{"claim":"Q1c ridge intensity = 40 FLOP/byte","code":"peak=3.2768e13;B=819e9;I=peak/B;result=abs(I-40.0)<0.2"},
{"claim":"Q1d GEMM intensity = 341","code":"M=K=Nn=1024;flop=2*M*K*Nn;byts=2*(M*K+K*Nn+M*Nn);I=flop/byts;result=abs(I-341.3)<1"},
{"claim":"Q2b gate budget = 2000","code":"tg=20e-9;T2=80e-6;eps=tg/T2;D=0.5/eps;result=abs(D-2000)<1"},
{"claim":"Q2c smallest odd distance = 21","code":"import math;p=1e-3;pth=1e-2;A=