• 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: ARC vs Manual Reference Counting
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: ARC vs Manual Reference Counting


  • Subject: Re: ARC vs Manual Reference Counting
  • From: Jean-Daniel Dupas <email@hidden>
  • Date: Mon, 09 Sep 2013 10:18:44 +0200

Le 9 sept. 2013 à 09:58, Tom Davie <email@hidden> a écrit :

>
> On 9 Sep 2013, at 09:44, Kyle Sluder <email@hidden> wrote:
>
>> Thirded. I thought I wouldn't like it. As soon as I didn't have to manage retains and releases of temporary objects, the discipline completely left my mind. Now whenever I go back to non-ARC code I invariably make a ton of memory management errors, most of which are caught by the analyzer.
>>
>> --Kyle Sluder
>>
>> On Sep 8, 2013, at 11:18 PM, Alex Kac <email@hidden> wrote:
>>
>>> Bingo. We’ve been working with Cocoa/Obj-C for many years, and still we’d find weird errors that would be caused by some over-released object. We cut a ton of code with ARC, and in the end we saw reliability go up and actually even some performance.
>>>
>>> ARC is a win. The only place it really got a bit hairy was CF objects. I wish ARC would work with them a bit more.
>>>
>>> On September 8, 2013 at 11:56:10 PM, Jens Alfke (email@hidden) wrote:
>>>
>>> They’re a _lot_ easier. It might not look that way when you’re reading about all the details, or converting existing code, because then you’re focusing on the rare edge cases. But for the most part when actually coding you can simply ignore ref-counting. Your code becomes more compact and readable, and you’re less likely to make mistakes.
>
> I *completely* agree with you with regards to memory management being hard to get reliably right (not hard to get right, hard to get reliably right), and weird errors all the time caused by memory management going wrong.  ARC is a major boon in this regard.
>
> However, I have to say, I have had the complete opposite experience with regards to performance.  Having measured various projects before and after converting to ARC, I have seen numbers between 30% and 100% slowdown with ARC.  The average is probably around 50%.  I have never seen performance improve when using ARC.


And does the profiler explicitly shows that ARC runtime code is the culprit ?

-- Jean-Daniel





_______________________________________________

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: ARC vs Manual Reference Counting
      • From: Tom Davie <email@hidden>
    • Re: ARC vs Manual Reference Counting
      • From: Kevin Meaney <email@hidden>
References: 
 >ARC vs Manual Reference Counting (From: email@hidden)
 >Re: ARC vs Manual Reference Counting (From: Patrick Cusack <email@hidden>)
 >Re: ARC vs Manual Reference Counting (From: Jens Alfke <email@hidden>)
 >Re: ARC vs Manual Reference Counting (From: Alex Kac <email@hidden>)
 >Re: ARC vs Manual Reference Counting (From: Kyle Sluder <email@hidden>)
 >Re: ARC vs Manual Reference Counting (From: Tom Davie <email@hidden>)

  • Prev by Date: Re: Unicode chars in string
  • Next by Date: Re: ARC vs Manual Reference Counting
  • Previous by thread: Re: ARC vs Manual Reference Counting
  • Next by thread: Re: ARC vs Manual Reference Counting
  • Index(es):
    • Date
    • Thread