My Project
programmer's documentation
Functions | Variables
cs_numbering.c File Reference
#include "cs_defs.h"
#include <stdio.h>
#include <string.h>
#include <assert.h>
#include "bft_mem.h"
#include "bft_error.h"
#include "bft_printf.h"
#include "cs_base.h"
#include "cs_log.h"
#include "cs_numbering.h"
Include dependency graph for cs_numbering.c:

Functions

cs_numbering_tcs_numbering_create_default (cs_lnum_t n_elts)
 Create a default numbering information structure. More...
 
cs_numbering_tcs_numbering_create_vectorized (cs_lnum_t n_elts, int vector_size)
 Create a default numbering information structure in case of vectorization. More...
 
cs_numbering_tcs_numbering_create_threaded (int n_threads, int n_groups, cs_lnum_t group_index[])
 Create a default numbering information structure in case of threading. More...
 
void cs_numbering_destroy (cs_numbering_t **numbering)
 Destroy a numbering information structure. More...
 
void cs_numbering_log_info (cs_log_t log, const char *description, const cs_numbering_t *numbering)
 Log information relative to a cs_numbering_t structure. More...
 
void cs_numbering_dump (const cs_numbering_t *numbering)
 Dump a cs_numbering_t structure. More...
 

Variables

const char * cs_numbering_type_name []
 

Detailed Description

Numbering information for vectorization or multithreading.

Function Documentation

◆ cs_numbering_create_default()

cs_numbering_t* cs_numbering_create_default ( cs_lnum_t  n_elts)

Create a default numbering information structure.

Parameters
[in]n_eltsnumber of associated elements
Returns
pointer to created cs_numbering_t structure

◆ cs_numbering_create_threaded()

cs_numbering_t* cs_numbering_create_threaded ( int  n_threads,
int  n_groups,
cs_lnum_t  group_index[] 
)

Create a default numbering information structure in case of threading.

Parameters
[in]n_groupsnumber of groups
[in]group_indexgroup_index[thread_id*group_id*2 + group_id*2] and group_index[thread_id*group_id*2 + group_id*2 +1] define the start and end ids for entities in a given group and thread; (size: n_groups *2 * n_threads)
Returns
pointer to created cs_numbering_t structure

◆ cs_numbering_create_vectorized()

cs_numbering_t* cs_numbering_create_vectorized ( cs_lnum_t  n_elts,
int  vector_size 
)

Create a default numbering information structure in case of vectorization.

Parameters
[in]n_eltsnumber of associated elements
[in]vector_sizevector size used for this vectorization
Returns
pointer to created cs_numbering_t structure

◆ cs_numbering_destroy()

void cs_numbering_destroy ( cs_numbering_t **  numbering)

Destroy a numbering information structure.

Parameters
[in,out]numberingpointer to cs_numbering_t structure pointer (or NULL)

◆ cs_numbering_dump()

void cs_numbering_dump ( const cs_numbering_t numbering)

Dump a cs_numbering_t structure.

Parameters
[in]numberingpointer to cs_numbering_t structure (or NULL)

◆ cs_numbering_log_info()

void cs_numbering_log_info ( cs_log_t  log,
const char *  description,
const cs_numbering_t numbering 
)

Log information relative to a cs_numbering_t structure.

Parameters
[in]loglog type
[in]descriptiondescription of numbering type
[in]numberingpointer to cs_numbering_t structure (or NULL)

Variable Documentation

◆ cs_numbering_type_name

const char* cs_numbering_type_name[]
Initial value:
= {N_("default"),
N_("vectorization"),
N_("threads")}
N_
#define N_(String)
Definition: cs_defs.h:56