should small rust structs be passed by copy

see also: Latency Budget · Platform Risk

context shard

A Rust performance note explained when passing small structs by copy is faster than borrowing (source). It reframed intuition about ownership and performance.

signal stack

  • Rust performance requires empirical thinking.
  • Copy can be cheaper than references in tight loops.
  • ABI and optimization details matter.
  • The low-level mindset echoes CPU Branch Prediction Evolution.

take line

Performance intuition is unreliable without measurements.

This links to CPU Branch Prediction Evolution and I Wrote a SQL Engine in Python and Why I’m Still Using Python.

open loop

Which performance assumptions are we still carrying from other languages?