[Gc] Major performance bug

Boehm, Hans hans.boehm at hp.com
Wed Feb 20 11:05:09 PST 2008


I finally got around to doing some profiling on the CVS version of the GC.  It turns out that a significant performance bug had crept in.  For multithreaded gctest (which may be unrealistically bad in this respect), the collector was often spending signiticantly over half of its time in the large block allocator.  The large block allocator should not be performance critical, but I once again managed to prove that you can make anything performance critical by using a sufficiently bad algorithm.

I think that matches some of the other observations I recall being posted here.  In particular, USE_MUNMAP more or less coincidentally avoided the problem.  The problem is a bit nasty in that it affected the running time in fairly random ways.  Some executions were slowed down only a little, while others where hugely affected.  In fact, it was the variability that originally caught my attention.

This is fixed in CVS, but it required more major changes than I had hoped to make at this stage.  Unfortunately, I think the problem was bad enough that it needs to be fixed now.  I will do more testing but, as always, help is appreciated.

Hans



More information about the Gc mailing list