Yet Another eXchange Tool 0.11.2
Loading...
Searching...
No Matches
xt_mpi.c File Reference
#include <assert.h>
#include <inttypes.h>
#include <limits.h>
#include <stdbool.h>
#include <stdlib.h>
#include <stdio.h>
#include <mpi.h>
#include "core/core.h"
#include "core/ppm_xfuncs.h"
#include "xt/xt_core.h"
#include "xt/xt_mpi.h"
#include "xt_mpi_internal.h"
Include dependency graph for xt_mpi.c:

Go to the source code of this file.

Classes

struct  xt_mpi_comm_internal_attr
 

Typedefs

typedef unsigned long used_map_elem
 

Enumerations

enum  { used_map_elem_bits = sizeof (used_map_elem) * CHAR_BIT }
 

Functions

void xt_mpi_error (int error_code, MPI_Comm comm)
 
size_t xt_disp2ext_count (size_t disp_len, const int *disp)
 
size_t xt_disp2ext (size_t disp_len, const int *disp, struct Xt_offset_ext *restrict v)
 
static int xt_mpi_comm_internal_keyval_copy (MPI_Comm XT_UNUSED(oldcomm), int XT_UNUSED(keyval), void *XT_UNUSED(extra_state), void *XT_UNUSED(attribute_val_in), void *attribute_val_out, int *flag)
 
static int xt_mpi_comm_internal_keyval_delete (MPI_Comm XT_UNUSED(comm), int XT_UNUSED(comm_keyval), void *attribute_val, void *XT_UNUSED(extra_state))
 
void xt_mpi_init (void)
 
void xt_mpi_finalize (void)
 
static struct xt_mpi_comm_internal_attrxt_mpi_comm_get_internal_attr (MPI_Comm comm)
 
static int ctzl (unsigned long v)
 
MPI_Comm xt_mpi_comm_smart_dup (MPI_Comm comm, int *tag_offset)
 
void xt_mpi_comm_smart_dedup (MPI_Comm *comm, int tag_offset)
 
void xt_mpi_comm_mark_exclusive (MPI_Comm comm)
 
bool xt_mpi_test_some (int *restrict num_req, MPI_Request *restrict req, int *restrict ops_completed, MPI_Comm comm)
 

Variables

static int xt_mpi_comm_internal_keyval = MPI_KEYVAL_INVALID
 
static int xt_mpi_tag_ub_val
 

Detailed Description

Author
Jörg Behrens behre.nosp@m.ns@d.nosp@m.krz.d.nosp@m.e Moritz Hanke hanke.nosp@m.@dkr.nosp@m.z.de Thomas Jahns jahns.nosp@m.@dkr.nosp@m.z.de

Definition in file xt_mpi.c.

Typedef Documentation

◆ used_map_elem

typedef unsigned long used_map_elem

Definition at line 197 of file xt_mpi.c.

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
used_map_elem_bits 

Definition at line 199 of file xt_mpi.c.

Function Documentation

◆ ctzl()

static int ctzl ( unsigned long v)
inlinestatic

Definition at line 304 of file xt_mpi.c.

Here is the caller graph for this function:

◆ xt_disp2ext()

size_t xt_disp2ext ( size_t disp_len,
const int * disp,
struct Xt_offset_ext *restrict v )

Definition at line 133 of file xt_mpi.c.

Here is the caller graph for this function:

◆ xt_disp2ext_count()

size_t xt_disp2ext_count ( size_t disp_len,
const int * disp )

Definition at line 92 of file xt_mpi.c.

Here is the caller graph for this function:

◆ xt_mpi_comm_get_internal_attr()

static struct xt_mpi_comm_internal_attr * xt_mpi_comm_get_internal_attr ( MPI_Comm comm)
static

Definition at line 268 of file xt_mpi.c.

Here is the caller graph for this function:

◆ xt_mpi_comm_internal_keyval_copy()

static int xt_mpi_comm_internal_keyval_copy ( MPI_Comm XT_UNUSEDoldcomm,
int XT_UNUSEDkeyval,
void * XT_UNUSEDextra_state,
void * XT_UNUSEDattribute_val_in,
void * attribute_val_out,
int * flag )
static

Definition at line 210 of file xt_mpi.c.

Here is the caller graph for this function:

◆ xt_mpi_comm_internal_keyval_delete()

static int xt_mpi_comm_internal_keyval_delete ( MPI_Comm XT_UNUSEDcomm,
int XT_UNUSEDcomm_keyval,
void * attribute_val,
void * XT_UNUSEDextra_state )
static

Definition at line 235 of file xt_mpi.c.

Here is the caller graph for this function:

◆ xt_mpi_comm_mark_exclusive()

void xt_mpi_comm_mark_exclusive ( MPI_Comm comm)

Annotate communicator that is for exclusive use by YAXT.

YAXT will trust communicators marked this way to not have active communications other than those initiated by YAXT functions. This is useful to prevent unnecessary MPI_Comm_dup() calls.

Parameters
[in,out]commcommunicator that will not be used by application code

Definition at line 403 of file xt_mpi.c.

Here is the caller graph for this function:

◆ xt_mpi_comm_smart_dedup()

void xt_mpi_comm_smart_dedup ( MPI_Comm * comm,
int tag_offset )
Examples
test_mpi_smartdedup.c.

Definition at line 386 of file xt_mpi.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ xt_mpi_comm_smart_dup()

MPI_Comm xt_mpi_comm_smart_dup ( MPI_Comm comm,
int * tag_offset )
Examples
test_mpi_smartdedup.c.

Definition at line 333 of file xt_mpi.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ xt_mpi_error()

void xt_mpi_error ( int error_code,
MPI_Comm comm )

report error return of MPI call

Parameters
[in]error_codereturn code of an MPI call
[in]commcommunicator which was used for the respective MPI call

Definition at line 75 of file xt_mpi.c.

◆ xt_mpi_finalize()

void xt_mpi_finalize ( void )
Examples
test_exchanger_parallel.c, and test_mpi_smartdedup.c.

Definition at line 261 of file xt_mpi.c.

Here is the caller graph for this function:

◆ xt_mpi_init()

void xt_mpi_init ( void )
Examples
test_exchanger_parallel.c, and test_mpi_smartdedup.c.

Definition at line 246 of file xt_mpi.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ xt_mpi_test_some()

bool xt_mpi_test_some ( int *restrict num_req,
MPI_Request *restrict req,
int *restrict ops_completed,
MPI_Comm comm )

Definition at line 415 of file xt_mpi.c.

Here is the caller graph for this function:

Variable Documentation

◆ xt_mpi_comm_internal_keyval

int xt_mpi_comm_internal_keyval = MPI_KEYVAL_INVALID
static

Definition at line 195 of file xt_mpi.c.

◆ xt_mpi_tag_ub_val

int xt_mpi_tag_ub_val
static

Definition at line 243 of file xt_mpi.c.