/**
 * Measurement wrapper for MPI_Group_compare
 * @note Auto-generated by wrapgen from template: std.w
 * @note C interface
 * @note Introduced with MPI 1.0
 * @ingroup cg
 */
int MPI_Group_compare(MPI_Group group1,
                      MPI_Group group2,
                      int*      result)
{
  int return_val;

  if (IS_EVENT_GEN_ON_FOR(CG))
  {
    EVENT_GEN_OFF();
    esd_enter(epk_mpi_regid[EPK__MPI_GROUP_COMPARE]);

    return_val = PMPI_Group_compare(group1, group2, result);

    esd_exit(epk_mpi_regid[EPK__MPI_GROUP_COMPARE]);
    EVENT_GEN_ON();
  }
  else
  {
    return_val = PMPI_Group_compare(group1, group2, result);
  }

  return return_val;
}
Exemple #2
0
int PMPI_Comm_compare ( 
        MPI_Comm  comm1,
        MPI_Comm  comm2,
        int *result)
{
  int index1, index2;  /* treat an index as the MPI communicator "context" */
  MPI_Group group1, group2;
  int gcmp;
  _MPI_COVERAGE();
  *result = MPI_UNEQUAL;
  if (_MPI_CHECK_STATUS(&comm1) == _MPI_OK &&
      _MPI_CHECK_STATUS(&comm2) == _MPI_OK)
  {
    _MPI_COVERAGE();
    if  (_MPI_Comm_check_legal(comm1, &index1)==MPI_SUCCESS &&
         _MPI_Comm_check_legal(comm2, &index2)==MPI_SUCCESS)
    {
      _MPI_COVERAGE();
      if (comm1 == MPI_COMM_NULL || comm2 == MPI_COMM_NULL)
         return MPI_ERR_COMM;
      
      if ( index1 == index2 ) {
        _MPI_COVERAGE();
        *result = MPI_IDENT;
      }
      else
      {
        _MPI_COVERAGE();
        group1 = _MPI_COMM_LIST[index1].group;
        group2 = _MPI_COMM_LIST[index2].group;
        
        if ( PMPI_Group_compare( group1, group2, &gcmp ) != MPI_SUCCESS )
          return MPI_ERR_GROUP;
        
        if ( gcmp == MPI_IDENT )
          *result = MPI_CONGRUENT;
        
        if ( gcmp == MPI_SIMILAR )
          *result = MPI_SIMILAR;
      }
      
      return MPI_SUCCESS;
    }
  }
  return MPI_ERR_COMM;
}
Exemple #3
0
int MPI_Group_compare ( MPI_Group group1, MPI_Group group2, int *result )
{
  _MPI_COVERAGE();
  return PMPI_Group_compare (group1, group2, result);
}
Exemple #4
0
int MPI_Group_compare(MPI_Group group1, MPI_Group group2, int *result)
{
  return PMPI_Group_compare(group1, group2, result);
}