diff --git a/input.cc b/input.cc index 4c3f1bdce..725efeb51 100644 --- a/input.cc +++ b/input.cc @@ -853,9 +853,7 @@ void read_phixs_data() { #ifdef MPI_ON // just in case the file system was faulty and the ranks disagree on the existence of the files - // broadcast the existence of the files to all ranks from rank 0 - - MPI_Bcast(phixs_file_version_exists.data(), sizeof(phixs_file_version_exists), MPI_BYTE, 0, MPI_COMM_WORLD); + MPI_Allreduce(MPI_IN_PLACE, phixs_file_version_exists.data(), 3, MPI_C_BOOL, MPI_LOR, MPI_COMM_WORLD); #endif assert_always(phixs_file_version_exists[1] || phixs_file_version_exists[2]); // at least one must exist if (phixs_file_version_exists[1] && phixs_file_version_exists[2]) {