‹ BackHN Continuity

Thread

The state of SIMD in Rust in 2026

209 points · 65 comments · verdagon

  1. sharktheone · · focus · HN ↗
    I am hoping for portable SIMD so much. But I still think that often a manually rolled SIMD will be faster.

    Also the state of SIMD in Cranelift is also very WIP. They pretty much just support a subset of 128bit vectors with some rare exceptions.

    1. dwattttt · · focus · HN ↗
      I guarantee you with my lack of skill, my attempt at using portable simd will exist while using manual intrinsics I doubt I'd get there.

      The question for me is whether portable simd will result in faster code than plain auto-vectorisation; for the simplest loops auto has me beat (the few times I've tried it), but I imagine as the complexity grows I'll be more likely to try do something that breaks auto-vectorisation, and it'll be more obvious to me when I do that in portable simd.

      1. nextaccountic · · focus · HN ↗
        nowadays it doesn't matter if you personally don't have this particular expertise, people still expect you to use an agent to write this code
    2. astrange · · focus · HN ↗
      Portable SIMD is a bad abstraction. The only two good choices are "something like ISPC" (basically "autoscalarization", similar to GPU kernels) and "writing in assembly" (ffmpeg does this for a reason).
      1. Archit3ch · · focus · HN ↗
        Note that ISPC does not handle symbolic math e.g. sparsity preserving linear solvers or equation simplification a la Mathematica. Manual ASM does. ;)
Open on Hacker News to reply ↗

Unofficial Hacker News client; not affiliated with Y Combinator.