Same Answer on Every Launch: A Reproducibility Contract for In-Browser and GPU Ensemble Solvers of Magnetic Tunnel Junction Dynamics, with Counter-Keyed Noise, a Single-Precision Error Budget and Order-Independent Reductions
Statistical simulation of MRAM cells, from worst-case sweeps to high-sigma yield, is naturally an ensemble of independent stochastic macrospin trajectories, and a browser compute shader can run it without any installation. The results are only useful for sign-off if they can be reproduced: the same seed must give the same answer whatever the launch size, thread order or device, or the departure from that ideal must be known and bounded. This paper proposes a reproducibility contract for such solvers with four clauses. Noise is counter-keyed, a pure function of run, cell and step, so no thread shares generator state. Reductions are either integer counts or fixed trees over the cell index. The single-precision error of the integrator is budgeted as a deviation measured against a double-precision reference on identical noise. And a certificate records the generator's known-answer checks, the partition and permutation tests, and the declared tolerance. A CPU illustration of a simplified macrospin ensemble of 40,000 cells shows bit-identical results across five random partitions with counter-keyed noise, while a shared stream leaves only 57 per cent of the cells with the same outcome; single precision keeps every switching outcome at the observation time, with a median trajectory deviation of 5×10⁻⁵; summation order alone moves a float32 total by up to 8×10⁻⁷ in relative terms while integer counts do not move at all. A published WebGPU shading language specification lists no 64-bit types and no multiply-high built-in, so the generator's multiplication is shown to be reproducible with 16-bit limbs.
Authors
- I-Wei Tseng
Publication Details
- Journal
- Zenodo (CERN European Organization for Nuclear Research)
- Published
- 2026-12-02
- DOI
- https://doi.org/10.5281/zenodo.24755660
- Primary Topic
- Parallel Computing and Optimization Techniques
- Type
- preprint