I have a following program which uses std::atomic_thread_fences: int data1 = 0; std::atomic<int> data2 = 0; std::atomic<int> state; int main() {
I know store buffer and invalidate queues are reasons that cause memory reordering. What I don't know is if Out-of-Order-Execution can cause memory reordering.
I'm reading the mail list about LKMM: Add volatile_if(). The control dependency is somewhat subtle since it is easily forgotten by us developers. So I wonder i