remove duplicated statements + fix openmp compilation