Csound Csound-dev Csound-tekno Search About

[Cs-dev] No false sharing

Date2010-08-21 22:16
FromMichael Gogins
Subject[Cs-dev] No false sharing
Threading overhead in Csound apparently has little to do with false
sharing. I padded spout so that each sample takes up 2 times the space
of the cache lines. Thiss did speed up multi-threaded rendering for
multiple threads at smaller ksmps, but also increased overhead with
large ksmps and with single threaded performance, so no net gain.

Summing to a shared output buffer is exactly the sort of operation
that risks false sharing, so the explanation probably is that the
timing between concurrent buffer writes is sufficiently variable that
the cache lines would usually be invalidated anyway (or flushed) in
the normal course of business.

-- 
Michael Gogins
Irreducible Productions
http://www.michael-gogins.com
Michael dot Gogins at gmail dot com

------------------------------------------------------------------------------
This SF.net email is sponsored by 

Make an app they can't live without
Enter the BlackBerry Developer Challenge
http://p.sf.net/sfu/RIM-dev2dev 
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net