[concurrency-interest] WeakReference overhead

Joseph Seigh jseigh_cp00 at xemaps.com
Tue Jan 1 10:12:46 EST 2008


On a hunch, I replaced the WeakReference PDR hack in my experimental STM 
implementation
with reference counting.  It knocked down the GC times by about 2/3's.  
So it would seem that
the Java Reference implementation has lots of GC overhead and should not 
be used on short
lived objects.  Overall the reduction in STM runtime was about 1/3.

The next experiment would probably be using hazard pointers instead of 
reference counting
(which is a huge pain to do in Java) and maybe object recycling since 
explicit PDR is being
used.  Kind of interesting that even though Java has GC,  explicit 
memory management can
still be useful in some situations.

--
Joe Seigh


More information about the Concurrency-interest mailing list