added timing output for lock debugging

looks like the locks arent being held for too long
in api_test (less then 30000 microseconds). and
no thread is waiting more than 10000 microseconds
to aqcuire a lock.