Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

People in 2011 lose weeks to tuning allocators and collectors in real high level languages. C programmers take a memory profile, deploy the appropriate pool/arena allocator, and get on with their job, comfortable with the fact that their former allocation bottleneck is now in the average case register-fast.

ARC fits better with the C world of quickly tuning bottlenecks to register speed. Have you ever debugged C code with custom object lifetimes under a garbage collector? It's a nightmare.



People in 2011 lose weeks to tuning allocators and collectors in real high level languages.

But that's, statistically, almost no people out of 'people who use GC'. There aren't that many allocators in common use that even have much in the way of tunable parameters (I can only think of the JVM ones, offhand), the people who spend weeks tuning them have very particular needs - high throughput, low latency, high-enough complexity to warrant a high-level language. These are the sort of people who also do things like start at a PHP page and end up chasing performance improvements in the bowels of a network kernel driver. It's done, but it's unrepresentative.

ARC fits better with the C world

It seems like a much more central reason ARC is more suitable than a GC for Objective C than 'GC tuning is occasionally a dark art'.


What can I tell you here? You're right, of course: most apps don't care about performance at all, either in space efficiency or time efficiency. Those apps shouldn't use C, and should certainly use a GC'd language.

I'm only reacting to the idea that (pp) "because it's 2011, nobody should be using ARC". Well, a statistically tiny number of apps may require the bare-metal performance that hand allocation provides, but they're also disproportionately important apps.


Ah, I read it more as 'It's 2011, where's my flying car/why aren't just about all apps running in managed environments'. Sort of like one says, 'It's 2011, why did syslogd just brick my server'. And it's not a completely lisp-machiny, neckbeardy sentiment, 10 odd years ago everyone was telling us the flying car was just around the corner - Apple was busily trying to bridge Java into Rhapsody, Microsoft was working on .NET/CLR. And yet, and yet...


The last years I thought that Objective-C was perhaps not future-proof enough when MS pushed .Net more and more into being desktop class.

And now MS shows WinRT that is not .Net. Hmmm... :)


I think eropple's point was that ARC is not a very high-level sort of approach to GC, i.e., not Lisp-style exact GC.


That's right (sorry, forgot about this thread). Not saying that ARC is bad, for where it's used--but it doesn't strike me as terribly "high-level".

(Neither, though, does C++, and smart pointers don't help there either. ;) )




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: