YetAnotherCoupler 3.5.2
Loading...
Searching...
No Matches
io_utils.c File Reference
#include <string.h>
#include "yac_mpi_internal.h"
#include "io_utils.h"
#include "math.h"
Include dependency graph for io_utils.c:

Go to the source code of this file.

Macros

#define IO_RANK_LIST_STR   "YAC_IO_RANK_LIST"
 
#define IO_MAX_NUM_RANKS_STR   "YAC_IO_MAX_NUM_RANKS"
 
#define IO_RANK_EXCLUDE_LIST_STR   "YAC_IO_RANK_EXCLUDE_LIST"
 
#define IO_MAX_NUM_RANKS_PER_NODE   "YAC_IO_MAX_NUM_RANKS_PER_NODE"
 
#define DEFAULT_MAX_NUM_IO_RANK_PER_NODE   (1);
 

Functions

static int compare_int (const void *a, const void *b)
 
static void read_rank_list (char const *env_name, MPI_Comm comm, size_t *num_ranks_, int **ranks_)
 
static void read_io_rank_list (MPI_Comm comm, size_t *num_io_ranks, int **io_ranks)
 
static void check_io_max_num_ranks_per_node (MPI_Comm comm, size_t *num_io_ranks_, int **io_ranks_)
 
static void check_io_max_num_ranks (MPI_Comm comm, size_t *num_io_ranks, int **io_ranks)
 
static void check_io_rank_exclude_list (MPI_Comm comm, size_t *num_io_ranks, int **io_ranks)
 
void yac_get_io_ranks (MPI_Comm comm, int *local_is_io_, int **io_ranks_, int *num_io_ranks_)
 
void yac_nc_open (const char *path, int omode, int *ncidp)
 
void yac_nc_create (const char *path, int cmode, int *ncidp)
 
void yac_nc_inq_dimid (int ncid, char const *name, int *dimidp)
 
void yac_nc_inq_varid (int ncid, char const *name, int *varidp)
 

Macro Definition Documentation

◆ DEFAULT_MAX_NUM_IO_RANK_PER_NODE

#define DEFAULT_MAX_NUM_IO_RANK_PER_NODE   (1);

Definition at line 14 of file io_utils.c.

◆ IO_MAX_NUM_RANKS_PER_NODE

#define IO_MAX_NUM_RANKS_PER_NODE   "YAC_IO_MAX_NUM_RANKS_PER_NODE"

Definition at line 13 of file io_utils.c.

◆ IO_MAX_NUM_RANKS_STR

#define IO_MAX_NUM_RANKS_STR   "YAC_IO_MAX_NUM_RANKS"

Definition at line 11 of file io_utils.c.

◆ IO_RANK_EXCLUDE_LIST_STR

#define IO_RANK_EXCLUDE_LIST_STR   "YAC_IO_RANK_EXCLUDE_LIST"

Definition at line 12 of file io_utils.c.

◆ IO_RANK_LIST_STR

#define IO_RANK_LIST_STR   "YAC_IO_RANK_LIST"

Definition at line 10 of file io_utils.c.

Function Documentation

◆ check_io_max_num_ranks()

static void check_io_max_num_ranks ( MPI_Comm comm,
size_t * num_io_ranks,
int ** io_ranks )
static

Definition at line 229 of file io_utils.c.

Here is the caller graph for this function:

◆ check_io_max_num_ranks_per_node()

static void check_io_max_num_ranks_per_node ( MPI_Comm comm,
size_t * num_io_ranks_,
int ** io_ranks_ )
static

Definition at line 132 of file io_utils.c.

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

◆ check_io_rank_exclude_list()

static void check_io_rank_exclude_list ( MPI_Comm comm,
size_t * num_io_ranks,
int ** io_ranks )
static

Definition at line 269 of file io_utils.c.

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

◆ compare_int()

static int compare_int ( const void * a,
const void * b )
inlinestatic

Definition at line 16 of file io_utils.c.

Here is the caller graph for this function:

◆ read_io_rank_list()

static void read_io_rank_list ( MPI_Comm comm,
size_t * num_io_ranks,
int ** io_ranks )
static

Definition at line 126 of file io_utils.c.

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

◆ read_rank_list()

static void read_rank_list ( char const * env_name,
MPI_Comm comm,
size_t * num_ranks_,
int ** ranks_ )
static

Definition at line 23 of file io_utils.c.

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

◆ yac_get_io_ranks()

void yac_get_io_ranks ( MPI_Comm comm,
int * local_is_io_,
int ** io_ranks_,
int * num_io_ranks_ )

Definition at line 309 of file io_utils.c.

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

◆ yac_nc_create()

void yac_nc_create ( const char * path,
int cmode,
int * ncidp )
Examples
test_interp_method_spmap_parallel.c, test_read_fesom.c, test_read_icon_parallel.c, test_read_scrip.c, test_read_woa_data.c, and test_weights2vtk.c.

Definition at line 367 of file io_utils.c.

Here is the caller graph for this function:

◆ yac_nc_inq_dimid()

void yac_nc_inq_dimid ( int ncid,
char const * name,
int * dimidp )
Examples
test_dist_grid_pair_parallel.c, and test_interp_weights_parallel.c.

Definition at line 385 of file io_utils.c.

Here is the caller graph for this function:

◆ yac_nc_inq_varid()

void yac_nc_inq_varid ( int ncid,
char const * name,
int * varidp )

Definition at line 411 of file io_utils.c.

Here is the caller graph for this function:

◆ yac_nc_open()

void yac_nc_open ( const char * path,
int omode,
int * ncidp )
Examples
test_dist_grid_pair_parallel.c, test_interp_weights_parallel.c, and test_weights2vtk.c.

Definition at line 350 of file io_utils.c.

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