[Gc] Turning off GC_parallel should be equivalent to ndef PARALLEL_MARK

Boehm, Hans hans.boehm at hp.com
Wed May 27 17:52:57 PDT 2009


Thanks.  Finally committed.

Hans 

> -----Original Message-----
> From: gc-bounces at napali.hpl.hp.com 
> [mailto:gc-bounces at napali.hpl.hp.com] On Behalf Of Ivan Maidanski
> Sent: Tuesday, October 28, 2008 11:34 AM
> To: gc at napali.hpl.hp.com
> Subject: [Gc] Turning off GC_parallel should be equivalent to 
> ndef PARALLEL_MARK
> 
> Hi!
> 
> Running GC with GC_markers == 1 is not the same (and a bit 
> slower) than running GC configured without PARALLEL_MARK. 
> Even more, in case of thread local allocations, it sometimes 
> waits (uselessly, though for short periods) in GC_acquire_mark_lock().
> 
> This patch does the following:
> - adds "if (GC_parallel)" statement in every "ifdef 
> PARALLEL_MARK" block;
> - replaces most "ifdef PARALLEL_MARK or THREAD_LOCAL_ALLOC" 
> with "ifdef PARALLEL_MARK" since GC_fl_builder_count, 
> GC_notify_all_builder(), GC_wait_for_reclaim(), 
> GC_acquire/release_mark_lock() are useless unless 
> PARALLEL_MARK (including HANDLE_FORK case);
> - also: the length "marker_[b]sp" (in "pthread_support.c" 
> file) is set to max-1 (since last element is unused) and the 
> looping conditions in 
> GC_segment_is_thread_stack/GC_greatest_stack_base_below() are 
> changed accordingly.
> 
> Bye.
> 
> 


More information about the Gc mailing list