usable_lock_implementation_with_sx-semantics

Usable lock implementation with SX-semantics

The current sx(9) implementation has several problems that make it unusable in many areas:

  • Might sleep (cv_wait) on the shared lock acquisition
  • implicit, hardcoded priority order without starvation protection
  • …

Things to look at:

  • Solaris' rwlock
  • Use turnstiles instead of conditional variables
    • Priority propagation
    • No longer just one owner
    • shared/read locks might be acquired recursively

TBD

  • usable_lock_implementation_with_sx-semantics.txt
  • Last modified: 2008/06/17 21:37
  • by 127.0.0.1