root/oshmem/runtime/oshmem_shmem_exchange.c

/* [<][>][^][v][top][bottom][index][help] */

DEFINITIONS

This source file includes following definitions.
  1. oshmem_shmem_allgather
  2. oshmem_shmem_allgatherv
  3. oshmem_shmem_barrier

   1 /*
   2  * Copyright (c) 2013      Mellanox Technologies, Inc.
   3  *                         All rights reserved.
   4  * Copyright (c) 2015      Research Organization for Information Science
   5  *                         and Technology (RIST). All rights reserved.
   6  * $COPYRIGHT$
   7  *
   8  * Additional copyrights may follow
   9  *
  10  * $HEADER$
  11  */
  12 
  13 #include "oshmem_config.h"
  14 
  15 #include "oshmem/constants.h"
  16 #include "oshmem/runtime/runtime.h"
  17 #include "oshmem/runtime/params.h"
  18 
  19 int oshmem_shmem_allgather(void *send_buf, void *rcv_buf, int elem_size)
  20 {
  21     int rc;
  22 
  23     rc = PMPI_Allgather(send_buf, elem_size, MPI_BYTE,
  24                         rcv_buf, elem_size, MPI_BYTE, oshmem_comm_world);
  25 
  26     return rc;
  27 }
  28 
  29 int oshmem_shmem_allgatherv(void *send_buf, void* rcv_buf, int send_count,
  30                             int* rcv_size, int* displs)
  31 {
  32     int rc;
  33 
  34     rc = PMPI_Allgatherv(send_buf, send_count, MPI_BYTE,
  35                          rcv_buf, rcv_size, displs, MPI_BYTE, oshmem_comm_world);
  36 
  37     return rc;
  38 }
  39 
  40 void oshmem_shmem_barrier(void)
  41 {
  42     PMPI_Barrier(oshmem_comm_world);
  43 }

/* [<][>][^][v][top][bottom][index][help] */