Fault Tolerance Interface
stage.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  FTIT_StageHeadInfo
 
struct  FTIT_StageAppInfo
 

Macros

#define FTI_SI_NAVL   0x1
 
#define FTI_SI_IAVL   0x0
 
#define FTI_SI_IALL   0x1
 
#define FTI_SI_NALL   0x0
 
#define FTI_SI_APTR(ptr)   ((FTIT_StageAppInfo*)ptr)
 
#define FTI_SI_HPTR(ptr)   ((FTIT_StageHeadInfo*)ptr)
 
#define FTI_SI_MAX_ID   (0x7ffff)
 
#define FTI_DISABLE_STAGING   do{*enableStagingPtr = false;} while(0)
 
#define FTI_SI_ENABLED   (*(bool*)enableStagingPtr)
 

Typedefs

typedef struct FTIT_StageHeadInfo FTIT_StageHeadInfo
 Head rank staging meta info. More...
 
typedef struct FTIT_StageAppInfo FTIT_StageAppInfo
 Application rank staging meta info. More...
 

Enumerations

enum  FTIT_StatusField { FTI_SIF_AVL = 0, FTI_SIF_VAL }
 valid fields of 'status'. More...
 
enum  FTIT_RequestField { FTI_SIF_ALL = 0, FTI_SIF_IDX }
 valid fields of 'idxRequest'. More...
 

Functions

int FTI_GetRequestID (FTIT_execution *FTI_Exec, FTIT_topology *FTI_Topo)
 Returns unique 'ID' for staging request. More...
 
int FTI_InitStage (FTIT_execution *FTI_Exec, FTIT_configuration *FTI_Conf, FTIT_topology *FTI_Topo)
 Initializes the FTI staging feature. More...
 
int FTI_InitStageRequestApp (FTIT_execution *FTI_Exec, FTIT_topology *FTI_Topo, uint32_t ID)
 Initializes new stage meta info element (application rank) More...
 
int FTI_AsyncStage (char *lpath, char *rpath, FTIT_configuration *FTI_Conf, FTIT_execution *FTI_Exec, FTIT_topology *FTI_Topo, int ID)
 This function triggers the asynchronous stage. More...
 
int FTI_InitStageRequestHead (char *lpath, char *rpath, FTIT_execution *FTI_Exec, FTIT_topology *FTI_Topo, int source, uint32_t ID)
 Initializes new stage meta info element (head rank) More...
 
int FTI_SyncStage (char *lpath, char *rpath, FTIT_execution *FTI_Exec, FTIT_topology *FTI_Topo, FTIT_configuration *FTI_Conf, uint32_t ID)
 This function synchronously stages the local file to the PFS. More...
 
int FTI_HandleStageRequest (FTIT_configuration *FTI_Conf, FTIT_execution *FTI_Exec, FTIT_topology *FTI_Topo, FTIT_checkpoint *FTI_Ckpt, int source)
 This function asynchronously stages the local file to the PFS. More...
 
int FTI_GetStatusField (FTIT_execution *FTI_Exec, FTIT_topology *FTI_Topo, int ID, FTIT_StatusField val, int source)
 Returns value from the 'status' field array at 'ID'. More...
 
int FTI_SetStatusField (FTIT_execution *FTI_Exec, FTIT_topology *FTI_Topo, int ID, uint8_t entry, FTIT_StatusField val, int source)
 Sets value from the 'status' field array at 'ID'. More...
 
int FTI_GetRequestField (int ID, FTIT_RequestField val)
 Returns value from the 'idxRequest' field array at 'ID'. More...
 
int FTI_SetRequestField (int ID, uint32_t entry, FTIT_RequestField val)
 Sets value of the 'idxRequest' field array at 'ID'. More...
 
int FTI_FreeStageRequest (FTIT_execution *FTI_Exec, FTIT_topology *FTI_Topo, int ID, int source)
 frees stage meta info element (head/application rank) More...
 
void FTI_PrintStageStatus (FTIT_execution *FTI_Exec, FTIT_topology *FTI_Topo, int ID, int source)
 
int FTI_GetRequestIdx (int ID)
 returns the index of desired stage meta info element. More...
 
void FTI_FinalizeStage (FTIT_execution *FTI_Exec, FTIT_topology *FTI_Topo, FTIT_configuration *FTI_Conf)
 Finalizes staging feature. More...
 

Macro Definition Documentation

#define FTI_DISABLE_STAGING   do{*enableStagingPtr = false;} while(0)
#define FTI_SI_APTR (   ptr)    ((FTIT_StageAppInfo*)ptr)
#define FTI_SI_ENABLED   (*(bool*)enableStagingPtr)
#define FTI_SI_HPTR (   ptr)    ((FTIT_StageHeadInfo*)ptr)
#define FTI_SI_IALL   0x1
#define FTI_SI_IAVL   0x0
#define FTI_SI_MAX_ID   (0x7ffff)
#define FTI_SI_NALL   0x0
#define FTI_SI_NAVL   0x1

Typedef Documentation

Application rank staging meta info.

Head rank staging meta info.

Enumeration Type Documentation

valid fields of 'idxRequest'.

enum that keeps the particular field identifiers for the 'idxRequest' field.

Enumerator
FTI_SIF_ALL 
FTI_SIF_IDX 

valid fields of 'status'.

enum that keeps the particular field identifiers for the 'status' field.

Enumerator
FTI_SIF_AVL 
FTI_SIF_VAL 

Function Documentation

int FTI_AsyncStage ( char *  lpath,
char *  rpath,
FTIT_configuration FTI_Conf,
FTIT_execution FTI_Exec,
FTIT_topology FTI_Topo,
int  ID 
)

This function triggers the asynchronous stage.

Parameters
string'lpath', absolute path of local file
string'rpath', absolute path of remote file
FTI_ExecExecution metadata.
FTI_TopoTopology metadata.
FTI_ConfConfiguration metadata.
integer'ID' of staging request
Returns
'FTI_SCES' on success, 'FTI_NSCS' else.

This function uses a non-blocking send (MPI_Isend) in order to pass the information that is needed by the head process to perform an asynchronous staging of the local file to the PFS.

Here is the call graph for this function:

void FTI_FinalizeStage ( FTIT_execution FTI_Exec,
FTIT_topology FTI_Topo,
FTIT_configuration FTI_Conf 
)

Finalizes staging feature.

Parameters
FTI_ExecExecution metadata.
FTI_TopoTopology metadata.
FTI_ConfConfiguration metadata.

This function frees allocated ressources, removes local staging files and the staging directory and destroys the node communicator

Here is the call graph for this function:

int FTI_FreeStageRequest ( FTIT_execution FTI_Exec,
FTIT_topology FTI_Topo,
int  ID,
int  source 
)

frees stage meta info element (head/application rank)

Parameters
FTI_ExecExecution metadata.
FTI_TopoTopology metadata.
integer'ID' of staging request
integer'source', application rank of stage request

This function eliminates the 'ID' corresponding element from the stage meta info array and frees the corresponding memory. In the application ranks it also reorders the index information in the 'idxRequestÄ array corresponding to 'ID'.

Here is the call graph for this function:

int FTI_GetRequestField ( int  ID,
FTIT_RequestField  val 
)

Returns value from the 'idxRequest' field array at 'ID'.

Parameters
integer'ID' of staging request
FTIT_StatusFieldrequested field
Returns
Field value on success, 'FTI_NSCS' else.

Here is the call graph for this function:

int FTI_GetRequestID ( FTIT_execution FTI_Exec,
FTIT_topology FTI_Topo 
)

Returns unique 'ID' for staging request.

Parameters
FTI_ExecExecution metadata.
FTI_TopoTopology metadata.
Returns
'ID' on success, -1 else.

Here is the call graph for this function:

int FTI_GetRequestIdx ( int  ID)

returns the index of desired stage meta info element.

Parameters
integer'ID' of staging request
Returns
index if 'ID' corresponding meta info structure was allocated -1, else.

Here is the call graph for this function:

int FTI_GetStatusField ( FTIT_execution FTI_Exec,
FTIT_topology FTI_Topo,
int  ID,
FTIT_StatusField  val,
int  source 
)

Returns value from the 'status' field array at 'ID'.

Parameters
FTI_ExecExecution metadata.
FTI_TopoTopology metadata.
integer'ID' of staging request
FTIT_StatusFieldrequested field
integer'source', application rank of stage request.
Returns
Field value on success, 'FTI_NSCS' else.

Here is the call graph for this function:

int FTI_HandleStageRequest ( FTIT_configuration FTI_Conf,
FTIT_execution FTI_Exec,
FTIT_topology FTI_Topo,
FTIT_checkpoint FTI_Ckpt,
int  source 
)

This function asynchronously stages the local file to the PFS.

Parameters
string'lpath', absolute path of local file.
string'rpath', absolute path of remote file.
FTI_ExecExecution metadata.
FTI_TopoTopology metadata.
FTI_ConfConfiguration metadata.
integer'source', application rank of stage request.
Returns
'FTI_SCES' on success, 'FTI_NSCS' else.

Here is the call graph for this function:

int FTI_InitStage ( FTIT_execution FTI_Exec,
FTIT_configuration FTI_Conf,
FTIT_topology FTI_Topo 
)

Initializes the FTI staging feature.

Parameters
FTI_ExecExecution metadata.
FTI_ConfConfiguration metadata.
FTI_TopoTopology metadata.

This function allocates memory for the 'idxRequest' and 'status' fields, creates a node communicator and an MPI shared memory window.

Here is the call graph for this function:

int FTI_InitStageRequestApp ( FTIT_execution FTI_Exec,
FTIT_topology FTI_Topo,
uint32_t  ID 
)

Initializes new stage meta info element (application rank)

Parameters
FTI_ExecExecution metadata.
FTI_TopoTopology metadata.
integer'ID' of staging request

This function appends a new staging meta info element for the application ranks to 'FTI_Exec->stageInfo->request'. Beside that it also initializes the status field (status -> pending) corresponding to 'ID' and assigns the proper index of the meta info element to the 'ID' corresponding 'idxRequest' field.

Here is the call graph for this function:

int FTI_InitStageRequestHead ( char *  lpath,
char *  rpath,
FTIT_execution FTI_Exec,
FTIT_topology FTI_Topo,
int  source,
uint32_t  ID 
)

Initializes new stage meta info element (head rank)

Parameters
string'lpath', absolute path of local file
string'rpath', absolute path of remote file
FTI_ExecExecution metadata.
FTI_TopoTopology metadata.
integer'source', application rank of stage request
integer'ID' of staging request
Returns
'FTI_SCES' on success, 'FTI_NSCS' else.

This function appends a new staging meta info element for the head ranks to 'FTI_Exec->stageInfo->request'. Beside that it also changes the status field corresponding to 'ID' (status -> active).

Here is the call graph for this function:

void FTI_PrintStageStatus ( FTIT_execution FTI_Exec,
FTIT_topology FTI_Topo,
int  ID,
int  source 
)

Here is the call graph for this function:

int FTI_SetRequestField ( int  ID,
uint32_t  entry,
FTIT_RequestField  val 
)

Sets value of the 'idxRequest' field array at 'ID'.

Parameters
integer'ID' of staging request
integer'entry', new value of field
FTIT_StatusFieldrequested field
Returns
'entry' on success, 'FTI_NSCS' else.

Here is the call graph for this function:

int FTI_SetStatusField ( FTIT_execution FTI_Exec,
FTIT_topology FTI_Topo,
int  ID,
uint8_t  entry,
FTIT_StatusField  val,
int  source 
)

Sets value from the 'status' field array at 'ID'.

Parameters
FTI_ExecExecution metadata.
FTI_TopoTopology metadata.
integer'ID' of staging request
integer'entry', new value of field
FTIT_StatusFieldrequested field
integer'source', application rank of stage request.
Returns
'entry' value on success, 'FTI_NSCS' else.

Here is the call graph for this function:

int FTI_SyncStage ( char *  lpath,
char *  rpath,
FTIT_execution FTI_Exec,
FTIT_topology FTI_Topo,
FTIT_configuration FTI_Conf,
uint32_t  ID 
)

This function synchronously stages the local file to the PFS.

Parameters
string'lpath', absolute path of local file
string'rpath', absolute path of remote file
FTI_ExecExecution metadata.
FTI_TopoTopology metadata.
FTI_ConfConfiguration metadata.
integer'ID' of staging request
Returns
'FTI_SCES' on success, 'FTI_NSCS' else.

This function should be called only if the staging feature is enabled without the head process being enabled.

Here is the call graph for this function: