<p dir="ltr">On 6 Jun 2014 17:07, "Sturla Molden" <<a href="mailto:sturla.molden@gmail.com">sturla.molden@gmail.com</a>> wrote:<br>
> We would in total need two mutexes, one condition variable, a pthread, and<br>
> a heap.</p>
<p dir="ltr">The proposal in my initial email requires zero pthreads, and is substantially more effective. (Your proposal reduces only the alloc overhead for large arrays; mine reduces both alloc and memory access overhead for boyh large and small arrays.)</p>

<p dir="ltr">-n</p>