parallel.py: Move multiprocessing code to separate module, generalize it.
parallel.py: Move multiprocessing code to separate module, generalize it.

makrutenko/dunovo,makrutenko/dunovo,makrutenko/dunovo