<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><br class=""><div><blockquote type="cite" class=""><div class="">On 5 Jul 2016, at 18:21, Jordan Rose &lt;<a href="mailto:jordan_rose@apple.com" class="">jordan_rose@apple.com</a>&gt; wrote:</div><br class="Apple-interchange-newline"><div class=""><meta http-equiv="Content-Type" content="text/html charset=utf-8" class=""><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div class="">Longstanding bug, <a href="rdar://problem/17277899" class="">rdar://problem/17277899</a>. Surprisingly few people have asked for it.</div><div class=""><br class=""></div><div class="">Jordan</div><br class=""></div></div></blockquote></div><br class=""><div class="">Good to know, thanks.</div><div class=""><br class=""></div><div class="">Maybe not enough people know/care about the overheads of weak references?</div><div class=""><br class=""></div><div class="">Since the WWDC Swift performance talk I’ve been more conscious of eliminating unnecessary retains/releases. That goes for weak references as well, as (certainly on Obj-C), accessing the value means acquiring a lock to ensure nobody is trying to zero that reference while you read it: <a href="http://opensource.apple.com//source/objc4/objc4-493.9/runtime/objc-arr.mm" class="">http://opensource.apple.com//source/objc4/objc4-493.9/runtime/objc-arr.mm</a>&nbsp;(see: objc_loadWeak). It’s basically never going to be in contention, but it’s still more overhead than a simple pointer.</div><div class=""><br class=""></div><div class="">Karl</div></body></html>