Remove some uses of Thread.holdsLock for correctness checking, it's too slow.

Signed-off-by: Ross Allan <rallanpcl@gmail.com>