moved locking out of extproc_pool_t into generic cross_thread_semaphore_t class