Antoine JEGO 4 years ago
parent
commit
678d19c0a6
1 changed files with 2 additions and 2 deletions
  1. 2 2
      mpi/src/starpu_mpi_task_insert.c

+ 2 - 2
mpi/src/starpu_mpi_task_insert.c

@@ -807,9 +807,9 @@ void starpu_mpi_redux_data_prio_tree(MPI_Comm comm, starpu_data_handle_t data_ha
 		_STARPU_MPI_DEBUG(5, "mpi_data->redux_map[%d] = %d\n", i, mpi_data->redux_map[i]);
 		if (mpi_data->redux_map[i]) nb_contrib++;
 	}
-	if (arity < 2 || (arity==1 && nb_contrib == 1))
+	if (arity < 2 || !(arity==1 && nb_contrib == 1))
 	{
-		_STARPU_ERROR("StarPU reduction tree should be at least a binary tree for a reduction to take place.\n");
+		_STARPU_ERROR("StarPU reduction tree should be at least a binary tree for a reduction to take place (or only one contributor in a unary tree) ; asked for %d-ary tree with %d contributors\n", arity, nb_contrib);
 	}
 	_STARPU_MPI_DEBUG(5, "There is %d contributors\n", nb_contrib);
 	int contributors[nb_contrib];