Synchronization and Memory Consistency