Added mutex lock around threaded performance counters.
Added continuous run option (-D).