Sequential Consistency

Result of the execution is as if all operations were executed in some order

Operations of each processor occured in the order of the prgram

Two requirements

  1. Maintaining program order on individual processors
  2. Ensuring write atomicity
    • If any processor reads the result of the write, all subsequent reads will be the same

Limitations

Hardware optimizations

Compiler optimizations

Example

for (i = 0; i<N; i += 2) {
  f(i);
  f(i+1);
  g(i);
  g(i+1);

}