- Feature Articles
- CodeSOD
- Error'd
- Forums
-
Other Articles
- Random Article
- Other Series
- Alex's Soapbox
- Announcements
- Best of…
- Best of Email
- Best of the Sidebar
- Bring Your Own Code
- Coded Smorgasbord
- Mandatory Fun Day
- Off Topic
- Representative Line
- News Roundup
- Editor's Soapbox
- Software on the Rocks
- Souvenir Potpourri
- Sponsor Post
- Tales from the Interview
- The Daily WTF: Live
- Virtudyne
Admin
Memcpy optimisation: On MacOS, at boot time the system determines the processor, and copies code for locking, atomic operations etc. and for memcpy, memmove and memset into a fixed location. The standard library functions just jump there.
Memset of a few megabytes has some very interesting code handling caches in the most efficient way possible. And memmove for small sizes was: slurp all the data into vector registers, then spit it out, without any loop. And without any check for overlaps.