Do I really need mutex lock in this case?
问题 Consider we have three thread, bool status_flag[500] array, and working situations as follow : Two threads only writing in status_flag array at different index . while third thread is only reading at any index. All three thread writing at different index. While all three threads reading at any index. In writing operation we are just setting the flag never reset it again. status_flag [i] = true; In reading operation we are doing something like that : for(;;){ //spinning to get flag true if