fn release(saved: LockState)
Record the release of a lock whose saved state was saved.
saved
Check that locks are being acquired in stacking order, and update the per-thread state accordingly.