Multithreading in A*
Merged.