I know atomic variable is lock-free!!
It doesn't lock thread, but I have one question..
Read-Modify-Store operation like std::atomic::fetch_add is also executed atomically???
I think this operation isn't just a one instruction.
It need multiple cycle... So If i doesn't lock memory bus ( Actually i don't know if mutex locking contain memory bus lock), Other thread can make memory operation between Read and Store.
So I think it require locking even if atomic variable...
Am i knowing well???