What is the Shared Memory Machine Model?
Also called Dance Hall Architecture
Each CPU has a cache and its own memory
What is a Symmetric Memory Processor Model?
Each CPU has its own cache, but memory is shared by all CPUs
What is the Distributed Shared Memory Model?
Each CPU has its own cache and local memory, but can access other CPU’s memory via the network
How long does it take the SMP model to access main memory and cache?
- ~2 cycles to access cache
What happens on update to a shared cache entry?
- Can invalidate other pages on change OR update all
What is the memory consistency model?
What is memory consistency?
What is the model presented to the programmer
What is cache coherence?
How is the system implementing the model in the presence of private caches?
Shared address space + cache coherence
What is NCC?
Non cache coherence
Shared address space
What are the operations associated with hardware cache coherence?
- Write update: send updated value to update cache entries
What is the issue with scalability?
Can exploit parallelism though
What are synchronization primitives for shared memory programming?
- Barriers
What are atomic operations?
What are examples of atomic operations?
Basically Read Modify Write
Are atomic operations sufficient to ensure synchronization?
- Don’t look at the cache, just go straight to memory
What are the issues with scalability with synchronization?
What are the goals of spin locks?
What are spin locks?
- Waiting processes spin on cached copy of lock
What are the issues with spin locks?
- Takes N^2 operations to invalidate and update
What are spin locks with delay?
What is ticket lock?
What are the issues with ticket lock?
- Invalidate based protocol will cause contention
What are array based queueing locks?
What is false sharing?
- Variable appears shared due to cache layout/how data is stored in the cache