Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Add multiple unimplemented calls in smpi.h
[simgrid.git] / src / smpi / bindings / smpi_pmpi_op.cpp
index 80886a914f5ae3218bb320259984a8650ffcc8d0..e90a6ba99b047943bb73250d86aeddb6f99447af 100644 (file)
@@ -22,6 +22,8 @@ int PMPI_Op_free(MPI_Op * op)
 {
   CHECK_NULL(1, MPI_ERR_ARG, op)
   CHECK_MPI_NULL(1, MPI_OP_NULL, MPI_ERR_OP, *op)
+  if((*op)->is_predefined())
+    return MPI_ERR_OP;
   simgrid::smpi::Op::unref(op);
   *op = MPI_OP_NULL;
   return MPI_SUCCESS;