News for hackers. Stuff that matters.
Re:JAX – NumPy on the CPU, GPU, and TPU, with great automati... by incrudible on Friday September 29, 2023 @06:19AM (#37701577)
Convenient authoring doesn't necessarily make it a good fit for the hardware. Add in enough divergence and your GPU code is going to be matched or outperformed by a competent CPU implementation (on a chip of comparable size). Branchless code can result in substantial speedups on either.

To be fair though, modern GPUs are pretty good at branching and latency hiding, while numpy-style code has poor data locality unless you have a magic compiler.

There are no comments on this comment yet.