no OMP in this code...
test correctness and other improvements