# Shared Memory

- ## Multi-Process Shared Memory

  - shmget, shmat
  - Synchronization via UNIX semaphores

- ## Threads

  - Compiler-generated “automatic” parallelism
  - Thread libraries - CPSlib, Solaris, Windows NT, Pthreads

- ## Multi-process vs. Threads

  - Threads are created more quickly and are “lighter”
  - Threads can ignore data ownership - risk of corruption
  - Multi-process ensures automatic data localization
  - Debugging probably easier with MP

Previous slide | Next slide | Back to first slide | View graphic version