4.A.4 Strong Sequential Equivalence: rules
- Control data scope with the base language
- Avoid the data scope clauses.
- Only use private for scratch variables local to a block (eg. temporaries or loop control variables) whose global initializes don’t matter.
- Locate all cases where a shared variable can be written by multiple threads.
- The access to the variable must be protected.
- If multiple threads combine results into a single value, enforce sequential order.