[concurrency-interest] good design vs performance (object creation)

Doug Lea dl at cs.oswego.edu
Sun Dec 27 09:58:29 EST 2009


Peter Veentjer wrote:
>  I found out that eventually object creation and/or cas 
> communication caused the bottleneck and not the rest of the code.

Since creation vs sync usually trade off against each
other, there's no good general rule of thumb about it.
You need to consider issues such as whether
the sync is usually localized and uncontended, whether
garbage nodes etc are cheap to collect (usually die fast
and/or no circular or linear pointer chains), and so on.

-Doug



More information about the Concurrency-interest mailing list