News for hackers. Stuff that matters.
Re:Leveraging Zig's Allocators by pcwalton on Saturday June 15, 2024 @07:38PM (#40693499)
128-bit or 256-bit memsets via SIMD instructions are sufficient to saturate RAM bandwidth, so there wouldn't be much of a gain from having a dedicated instruction.

(By the way, x86 does have a dedicated instruction--rep stosb--but compilers differ as to how often they use it, for the reason cited above.)

Re:Leveraging Zig's Allocators by tubs on Sunday June 16, 2024 @12:49AM (#40694757)
The gain is in power efficiency.

Arm64 provides `dc zva` for this.

Re:Leveraging Zig's Allocators by anonymoushn on Sunday June 16, 2024 @06:47AM (#40696090)
Supposedly rep movsb is faster than SIMD stores on very recent chips, for cases where you aren't actually hitting RAM with all your writes.