[concurrency-interest] RFR  optimization of CopyOnWriteArrayList.addIfAbsent()
martinrb at google.com
Tue Apr 2 17:17:25 EDT 2013
Have you benchmarked the case where the element is never present?
(with the usual caveats about micro-benchmarking - perhaps use google
On Tue, Apr 2, 2013 at 2:11 PM, Ivan Gerasimov <ivan.gerasimov at oracle.com>wrote:
> I've done a little testing on my side.
> I used Integer as an underlying type and set length of the array to the
> values from 1 to 100.
> My code shows a little performance gain - approximately 9%.
> I understand it may not be there for all cases, but at least for some
> cases it is there.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Concurrency-interest