[tz] [PROPOSED 1/2] Optionally use read-write locks instead of mutexes