v.io/x/lib/nsync: An implementation of mutex and condition variables

The nsync package provides a mutex Mu and a Mesa-style condition
variable CV.

The nsync primitives differ from those in sync in that nsync provides
timed wait on CV and try-lock on Mu, CV's wait primitives take the mutex
as an explicit argument to remind the reader that they have a side
effect on the mutex, the zero value CV can be used without further
initialization, and Mu forbids a lock acquired by one thread to be
released by another.

As well as Mu and CV being usable with one another, an nsync,Mu can be
used with a sync.Cond, and an nsync.CV can be used with a sync.Mutex.

Change-Id: Id6a14ebcf007bd4cb33dcc7b138d35f61db9546a
10 files changed