2.5.2.2 Memory System Ordering of Memory Accesses
For most memory accesses caused by explicit memory access instructions, the memory system does not ensure that the order in which the accesses complete matches the program order of the instructions, providing this does not affect the behavior of the instruction sequence. Normally, if correct program execution depends on two memory accesses completing in program order, software must insert a memory barrier instruction between the memory access instructions.
However, the memory system does ensure some ordering of accesses to Device and Strongly-ordered memory. The following figure shows the ordering of the memory accesses caused by two instructions A1 and A2 if A1 occurs before A2 in program order.
Where:
- - Means that the memory system does not ensure the ordering of the accesses.
- < Means that accesses are observed in program order, that is, A1 is always observed before A2.