Add barrier for race condition from fix and print frequency being equal