When the fractional part of a float fixes your shader

The other night I wanted to implement a small Voronoi-diagram shader as a music-video background. I got it looking cool, then next morning found that—on one computer only—there was a weird stutter. This is the write-up of a week debugging and disassembling shaders.

The shader

A Worley/Voronoi noise: tile space, pick random centers, nearest of 9 centers colors a cell; UV warping via noise; palette lookup. Noise came from Inigo Quilez-style value noise using fract / hash1.

The problem

Devices tested: Intel iGPU Linux laptops (OK), Pixel 9 Pro (OK), Linux RTX 2070 (OK), Windows RTX 4070 (broken) across Firefox/Chrome/Edge.