Twitter | Search | |
This is the legacy version of twitter.com. We will be shutting it down on 15 December 2020. Please switch to a supported browser or device. You can see a list of supported browsers in our Help Center.
David Smith
fun fact: retaining and releasing an NSObject takes ~30 nanoseconds on current gen Intel, and ~6.5 nanoseconds on an M1
Reply Retweet Like More
David Smith Nov 10
Replying to @Catfish_Man
…and ~14 nanoseconds on an M1 emulating an Intel πŸ˜‡
Reply Retweet Like
David Smith Nov 10
Replying to @Catfish_Man
(The price we pay for this is that certain kinds of multithreading bugs can remain dormant on Intel but become symptomatic on M1. Use Thread Sanitizer to test your apps!)
Reply Retweet Like
Ken Hates Software Nov 10
Replying to @Catfish_Man
Congrats to their hardware team, but as a developer, I can report that retain/release have never once been a bottleneck for me. At this point I'd buy a Mac that was half as fast as my old one, if only they finished writing some bleepin' documentation.
Reply Retweet Like
David Smith Nov 10
Replying to @KenHatesSoftwar
To a significant extent the reason it hasn’t been an issue is because of the work of people like me dealing with it at lower levels of the system.
Reply Retweet Like
Dad Nov 10
Replying to @Catfish_Man
That enhancement in the A12Z also?
Reply Retweet Like
Joe Groff Nov 10
The A12 generation might still have an edge over Intel because of weaker memory ordering, but the A14 and M1 are the first with the fast uncontended atomics
Reply Retweet Like
Thomas Burkhart πŸ’™πŸ¦„ Nov 10
Replying to @Catfish_Man
How do they achieve this extreme jump?
Reply Retweet Like
David Smith Nov 10
Replying to @ThomasBurkhartB
Weaker memory model makes acquire-release atomics possible to implement much more efficiently, in exchange for not hiding some classes of multithreading bugs
Reply Retweet Like
Glenda Adams Nov 10
Replying to @Catfish_Man
This means I can start using NSObject retain/release as a database, right? πŸ˜€
Reply Retweet Like
David Smith Nov 10
Replying to @glenda_atom
πŸ˜‚πŸ˜‚πŸ˜‚
Reply Retweet Like