Comment by ncruces
13 hours ago
You do aligned reads, which can't crash.
Not even musl uses a scalar loop, if it can do aligned reads/writes: https://git.musl-libc.org/cgit/musl/tree/src/string/stpcpy.c
And you don't need to worry about C UB if you do it in ASM.
No comments yet
Contribute on Hacker News ↗