• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Subclassing NSControl and inheritance of target, action properties
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Subclassing NSControl and inheritance of target, action properties


  • Subject: Re: Subclassing NSControl and inheritance of target, action properties
  • From: Greg Parker <email@hidden>
  • Date: Thu, 29 Jan 2015 19:47:44 -0800

> On Jan 29, 2015, at 5:29 PM, Quincey Morris <email@hidden> wrote:
>
> On Jan 29, 2015, at 17:18 , Roland King <email@hidden> wrote:
>>
>> I can find this http://lists.apple.com/archives/objc-language/2013/Apr/msg00119.html <http://lists.apple.com/archives/objc-language/2013/Apr/msg00119.html>, is that what you were remembering or is there something stronger my google-fu isn't finding, which wouldn't be for the first time?
>
> I think that’s it. A few months ago, as I said. ;)
>
> The only odd thing is “non-object”. Based on the rest of Greg’s statement, I think it’s a typo for “non-struct”. I can’t think of a reason why an 8-byte pointer would produce different results from an 8-byte int. But I don’t really know.

"Non-object" is correct. `atomic` makes a big difference for a strong or weak property of object type because objects have retain counts.

There is one exception to the "non-object scalar" claim. On 32-bit ARM non-object scalar properties that are larger than 4 bytes are slower when atomic. This includes types `double` and `long long`. The problem is that the 32-bit ARM ABI only aligns storage for those types at 4-byte boundaries, and the CPU does not guarantee atomicity for ordinary unaligned 8-byte memory access. Atomic accessors for those types need to do extra work.


--
Greg Parker     email@hidden     Runtime Wrangler



_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden


  • Follow-Ups:
    • Re: Subclassing NSControl and inheritance of target, action properties
      • From: Quincey Morris <email@hidden>
References: 
 >Subclassing NSControl and inheritance of target, action properties (From: Graham Cox <email@hidden>)
 >Re: Subclassing NSControl and inheritance of target, action properties (From: Roland King <email@hidden>)
 >Re: Subclassing NSControl and inheritance of target, action properties (From: Graham Cox <email@hidden>)
 >Re: Subclassing NSControl and inheritance of target, action properties (From: Quincey Morris <email@hidden>)
 >Re: Subclassing NSControl and inheritance of target, action properties (From: Roland King <email@hidden>)
 >Re: Subclassing NSControl and inheritance of target, action properties (From: Quincey Morris <email@hidden>)

  • Prev by Date: Re: Subclassing NSControl and inheritance of target, action properties
  • Next by Date: Modifying row rect indent in NSOutlineView
  • Previous by thread: Re: Subclassing NSControl and inheritance of target, action properties
  • Next by thread: Re: Subclassing NSControl and inheritance of target, action properties
  • Index(es):
    • Date
    • Thread