...
>
> I've also checked the bugs list for any known bugs, fixed or
> otherwise, to do with threading and I haven't found anything. I'm not
> sure what I'm doing wrong.
The problem is here:
You declare _barrier first and numCPU second, so in your constructor, _barrier will be initialized first, using the value of numCPU, which hasn't been initialized yet.
Just change the order of the declarations. Declare _barrier below numNPU.
By the way, compiling with -Wall catches all these errors.
Regards,
Ignacio Burgueño