News for hackers. Stuff that matters.
Re:5 Coding Hacks to Reduce GC Overhead by FreeFull on Thursday July 18, 2013 @08:59AM (#6063257)
I was hoping for something that would be general for most GC languages, but it seems to only talk about Java.
Re:5 Coding Hacks to Reduce GC Overhead by ryanpetrich on Thursday July 18, 2013 @09:28AM (#6063457)
The general advice is to produce less garbage. Strategies for doing so are specific to the language and APIs involved.
Re:5 Coding Hacks to Reduce GC Overhead by AlisdairO on Thursday July 18, 2013 @09:44AM (#6063558)
It's not just that you need to produce less garbage - you want to produce less live objects in general, as a large part of the cost during GC is determining which objects are live.
Re:5 Coding Hacks to Reduce GC Overhead by RyanZAG on Thursday July 18, 2013 @10:45AM (#6063953)
That depends - if your code is mostly single threaded, and you're using the concmarksweep collector on a multicore CPU, determinign which objects are live is basically 'free'. On machines with a high number of cores, have all cores on 100% is very rare.
Re:5 Coding Hacks to Reduce GC Overhead by zeroDivisible on Thursday July 18, 2013 @09:03AM (#6063277)
I might be wrong, but it might be a bit hard to write something general enough to be useful - as most of the items can be easily translated into other languages, it would still be mostly implementation-specific / language design specific.