Table of Contents
Benchmarking (2D FDTD)
Benchmarking measures how quickly the simulation advances a specified workload. FDTD CUDA reports cell-update throughput in millions of cell updates per second (Mcells/s). For a grid of $n_x$ by $n_y$ cells, $N$ steps, and elapsed time $t$:
$$ \mathrm{throughput}=\frac{n_xn_yN}{10^6t}\quad\mathrm{Mcells/s} $$
The project provides a configurable sweep:
$ cp config.example config $ make bench
The configuration selects backends, variants, thread counts, grid sizes, step counts, and repetitions. It also controls boundary conditions and whether snapshot transfers occur inside the timed run. make bench-double repeats the workflow in double precision.
Each run writes CSV samples and machine metadata under results/benchmarks/. Repeated measurements expose timing variation, while interleaving configurations helps distribute changing machine load across the sweep. Speedup comparisons should use the same numerical workload and precision. Snapshot settings matter because copying results to the host adds work beyond updating the fields.
