What is Span<T> in C#, and when does it actually make your code faster?
Span<T> is a stack-only ref struct that points at memory you already own, so it has no backing allocation. It speeds code up in exactly three situations: replacing a heap buffer with stackalloc, slicing without copying, and tight loops where the JIT elides bounds checks. Everywhere else it changes nothing, and across an await it does not compile.