-DPARALLEL_MARK and GC_enable_incremental()

View: New views
2 Messages — Rating Filter:   Alert me  

-DPARALLEL_MARK and GC_enable_incremental()

by Jonathan Gagnon-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi,
 
I wanted to know how the mono GC behaves on multiprocessor machines.  After reading some documentation on the Boehm GC, I'm wondering if mono compiles the GC with -DPARALLEL_MARK.  This allows the collector to run the mark phase in parallel, and thus use all the available processors on a multi-processor machine (instead of using just one).  More details can be found here :
 
 
It seems like they also have generational collection, that can be enable by calling GC_enable_incremental.  It doesn't seem to be called anywhere in the mono sources, so I assume it is not used.  Is there a reason why?
 
Thanks,
 
Jonathan
 

_______________________________________________
Mono-gc-list maillist  -  Mono-gc-list@...
http://lists.ximian.com/mailman/listinfo/mono-gc-list

Re: -DPARALLEL_MARK and GC_enable_incremental()

by Paolo Molaro-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

On 03/19/08 Jonathan Gagnon wrote:
> I wanted to know how the mono GC behaves on multiprocessor machines.  After
> reading some documentation on the Boehm GC, I'm wondering if mono compiles
> the GC with -DPARALLEL_MARK.  This allows the collector to run the mark
> phase in parallel, and thus use all the available processors on a
> multi-processor machine (instead of using just one).  More details can be
> found here :
>  
> http://www.hpl.hp.com/personal/Hans_Boehm/gc/scale.html

Some time ago I tested a mono version enabled with -DPARALLEL_MARK
on a workload that should have benefited from it and I saw basiccally no
performance improvement on my core 2 duo (there was a slight regression).
For kicks I just tested another case and with parallel marking
enabled performance is orrible (twice as slow).
You can easily test your workload configuring mono with the
--enable-parallel-mark option.
I didn't investigate the cause of the slowdown.

> It seems like they also have generational collection, that can be enable by
> calling GC_enable_incremental.  It doesn't seem to be called anywhere in the
> mono sources, so I assume it is not used.  Is there a reason why?

GC_enable_incremental has a number of issues that are detailed in the
documentation (mainly unexpected interrupted syscalls: we could deal
with them in the runtime, but the p/invoke code of many programs would
break unless we copy potentially lots of data around: not practical).

lupus

--
-----------------------------------------------------------------
lupus@...                                     debian/rules
lupus@...                             Monkeys do it better
_______________________________________________
Mono-gc-list maillist  -  Mono-gc-list@...
http://lists.ximian.com/mailman/listinfo/mono-gc-list