I'm implementing my path tracer using C++ and OpenMP partially based on the design of Small Paint (using a globally available RND function to generate random floats) and PBRTv2 (uses a single RNG across all threads). I notice that due to the fact there can can be multiple threads accessing the same RNG. Race condition and CPU cache invalidation will occur caused by the RNG writing to memory to store/update it's current state. Thus dragging the performance down and mess up the RNG(makes it unpredictable).
How come this is in one of the top grade educational renderer? Or it's just a minor issue that isn't important?
If it's important, is there a known good way to fix this without breaking PBRT's rendering/threading architecture?