‹ BackHN Continuity

Thread

The state of SIMD in Rust in 2026

209 points · 65 comments · verdagon

  1. Archit3ch · · focus · HN ↗
    Hot take: there is no portable SIMD.

    You can either have performance (=write manual ASM for each platform), or portability, but not both.

    What so-called "portable SIMD" libraries give you is "portable auto-vectorization". "Portable performance" is a global property of the algorithm. Relying on auto-vectorization will result in e.g. sub-optimal register spills in practice. The microbenchmarks will look great, though. ;)

    1. Scene_Cast2 · · focus · HN ↗
      What about numpy, numba, and torch.compile?
      1. izacus · · focus · HN ↗
        Those are manually optimized per arch, aren't they?
        1. Scene_Cast2 · · focus · HN ↗
          The libraries, yes, but the code you write is portable (at least until you get into squeezing the last few percent and switch to Triton / Helion in case of GPU, and even those are decently portable).

          There's also Halide, where you write the algo but the framework gets you the scheduling and SIMD.

Open on Hacker News to reply ↗

Unofficial Hacker News client; not affiliated with Y Combinator.