Allow both single and multithreaded search