Generic Trace Generator (GTG)  0.1
Functions
Paje interface in C of the GTGBasic1 API

Functions

paje_color_t Paje_get_color (gtg_color_t p_color)
 Converts a GTG color into a PAJE color. More...
 
trace_return_t pajeInitTrace (const char *filename, int rank, gtg_flag_t flags, int fmt)
 Initialize a VITE trace ( *.ept) More...
 
char * pajeGetName (int rk)
 Function to get the name of the file containing all the data for the proc of rank rk. More...
 
trace_return_t pajeSetCompress (int val)
 Enable trace compression. More...
 
trace_return_t pajeAddContType (const char *alias, const char *contType, const char *name)
 Add a Container Type. More...
 
trace_return_t pajeAddStateType (const char *alias, const char *contType, const char *name)
 Add a State Type. More...
 
trace_return_t pajeAddEventType (const char *alias, const char *contType, const char *name)
 Add an Event Type. More...
 
trace_return_t pajeAddLinkType (const char *alias, const char *name, const char *contType, const char *srcContType, const char *destContType)
 Add a Link Type. More...
 
trace_return_t pajeAddVarType (const char *alias, const char *contType, const char *name)
 Add a Variable Type. More...
 
trace_return_t pajeAddEntityValue (const char *alias, const char *entType, const char *name, const char *color)
 Add an Entity Value. More...
 
trace_return_t pajeAddContainer (varPrec time, const char *alias, const char *type, const char *container, const char *name, const char *file)
 Add a Container (VITE format). More...
 
trace_return_t pajeSeqAddContainer (varPrec time, const char *alias, const char *type, const char *container, const char *name)
 Add a Container (PAJE format). More...
 
trace_return_t pajeDestroyContainer (varPrec time, const char *name, const char *type)
 Destroy a Container. More...
 
trace_return_t pajeSetState (varPrec time, const char *type, const char *cont, const char *val)
 Set the State of a Container. More...
 
trace_return_t pajePushState (varPrec time, const char *type, const char *cont, const char *val)
 Save the current State on a stack and change the State of a Container. More...
 
trace_return_t pajePopState (varPrec time, const char *type, const char *cont)
 Revert the State of a Container to its previous value. More...
 
trace_return_t pajeAddEvent (varPrec time, const char *type, const char *cont, const char *val)
 Add an Event. More...
 
trace_return_t pajeStartLink (varPrec time, const char *type, const char *cont, const char *src, const char *val, const char *key)
 Start a link. More...
 
trace_return_t pajeEndLink (varPrec time, const char *type, const char *cont, const char *dest, const char *val, const char *key)
 Start a link. More...
 
trace_return_t pajeSetVar (varPrec time, const char *type, const char *cont, varPrec val)
 Set a Variable value. More...
 
trace_return_t pajeAddVar (varPrec time, const char *type, const char *cont, varPrec val)
 Add a value to a Variable. More...
 
trace_return_t pajeSubVar (varPrec time, const char *type, const char *cont, varPrec val)
 Substract a value from a Variable. More...
 
trace_return_t pajeAddComment (const char *comment)
 Add some Comment in Trace file. More...
 
trace_return_t pajeEndTrace ()
 Finalize a PAJE trace. More...
 
trace_return_t viteEndTrace ()
 Finalize a VITE trace. More...
 

Detailed Description

Function Documentation

◆ Paje_get_color()

const paje_color_t Paje_get_color ( gtg_color_t  color)

Converts a GTG color into a PAJE color.

Parameters
colorGTG color to convert
Returns
The PAJE color

◆ pajeAddComment()

trace_return_t pajeAddComment ( const char *  comment)

Add some Comment in Trace file.

Parameters
commentComment to be added
Returns
TRACE_SUCCESS on success
An error code otherwise

◆ pajeAddContainer()

trace_return_t pajeAddContainer ( varPrec  time,
const char *  alias,
const char *  type,
const char *  container,
const char *  name,
const char *  file 
)

Add a Container (VITE format).

Parameters
timeTime at which the container is added
aliasAlias on the new container
typeType of the container
containerContainer parent
nameName of the variable type
fileFile containing the container trace
Returns
0 if success
An error code otherwise

◆ pajeAddContType()

trace_return_t pajeAddContType ( const char *  alias,
const char *  contType,
const char *  name 
)

Add a Container Type.

Parameters
aliasAlias on the container
contTypeType of container
nameName of the container type
Returns
0 if success
An error code otherwise

◆ pajeAddEntityValue()

trace_return_t pajeAddEntityValue ( const char *  alias,
const char *  entType,
const char *  name,
const char *  color 
)

Add an Entity Value.

Parameters
aliasAlias on the entity value
entTypeType of the entity
nameName of the variable type
colorColor of the entity
Returns
0 if success
An error code otherwise

◆ pajeAddEvent()

trace_return_t pajeAddEvent ( varPrec  time,
const char *  type,
const char *  cont,
const char *  val 
)

Add an Event.

Parameters
timeTime at which the event happens
typeType of the event
contContainer in this event
valEntity value of the event of the container
Returns
0 if success
An error code otherwise

◆ pajeAddEventType()

trace_return_t pajeAddEventType ( const char *  alias,
const char *  contType,
const char *  name 
)

Add an Event Type.

Parameters
aliasAlias on the event type
contTypeType of container
nameName of the event type
Returns
0 if success
An error code otherwise

◆ pajeAddLinkType()

trace_return_t pajeAddLinkType ( const char *  alias,
const char *  name,
const char *  contType,
const char *  srcContType,
const char *  destContType 
)

Add a Link Type.

Parameters
aliasAlias on the link type
nameName of the link type
contTypeType of container
srcContTypeType of the source container
destContTypeType of the destination container
Returns
0 if success
An error code otherwise

◆ pajeAddStateType()

trace_return_t pajeAddStateType ( const char *  alias,
const char *  contType,
const char *  name 
)

Add a State Type.

Parameters
aliasAlias on the state type
contTypeType of container
nameName of the state type
Returns
0 if success
An error code otherwise

◆ pajeAddVar()

trace_return_t pajeAddVar ( varPrec  time,
const char *  type,
const char *  cont,
varPrec  val 
)

Add a value to a Variable.

Parameters
timeTime at which the variable is incremented
typeType of the variable
contContainer containing the variable
valValue added
Returns
0 if success
An error code otherwise

◆ pajeAddVarType()

trace_return_t pajeAddVarType ( const char *  alias,
const char *  contType,
const char *  name 
)

Add a Variable Type.

Parameters
aliasAlias on the variable type
contTypeType of container
nameName of the variable type
Returns
0 if success
An error code otherwise

◆ pajeDestroyContainer()

trace_return_t pajeDestroyContainer ( varPrec  time,
const char *  name,
const char *  type 
)

Destroy a Container.

Parameters
timeTime at which the container is destroyed
nameName on the container to destroy
typeType of the container
Returns
0 if success
An error code otherwise

◆ pajeEndLink()

trace_return_t pajeEndLink ( varPrec  time,
const char *  type,
const char *  cont,
const char *  dest,
const char *  val,
const char *  key 
)

Start a link.

Parameters
timeTime at which the link starts
typeType of the link
contContainer parent of the source and destination containers containing the link
destSource container
valValue of the link
keyKey used to match start link with end link
Returns
0 if success
An error code otherwise

◆ pajeEndTrace()

pajeEndTrace ( )

Finalize a PAJE trace.

Returns
0 if success
An error code otherwise

◆ pajeGetName()

char * pajeGetName ( int  rk)

Function to get the name of the file containing all the data for the proc of rank rk.

Parameters
rkRank of the proc you want the filename containing it
Returns
Name of the file.

◆ pajeInitTrace()

trace_return_t pajeInitTrace ( const char *  filename,
int  rank,
gtg_flag_t  flags,
int  fmt 
)

Initialize a VITE trace ( *.ept)

Parameters
filenameRoot name of the file to create
rankRank of the processor
flagsOne of GTG_FLAG_NONE, GTG_FLAG_USE_MPI, GTG_FLAG_NOTBUF.
fmtFormat, paje or vite
Returns
0 if success An error code otherwise

◆ pajePopState()

trace_return_t pajePopState ( varPrec  time,
const char *  type,
const char *  cont 
)

Revert the State of a Container to its previous value.

Parameters
timeTime at which the state is poped
typeType of the state
contContainer in this state
Returns
0 if success
An error code otherwise

◆ pajePushState()

trace_return_t pajePushState ( varPrec  time,
const char *  type,
const char *  cont,
const char *  val 
)

Save the current State on a stack and change the State of a Container.

Parameters
timeTime at which the state is pushed
typeType of the state
contContainer in this state
valEntity value of the state of the container
Returns
0 if success
An error code otherwise

◆ pajeSeqAddContainer()

trace_return_t pajeSeqAddContainer ( varPrec  time,
const char *  alias,
const char *  type,
const char *  container,
const char *  name 
)

Add a Container (PAJE format).

Parameters
timeTime at which the container is added
aliasAlias on the new container
typeType of the container
containerContainer parent
nameName of the variable type
Returns
0 if success
An error code otherwise

◆ pajeSetCompress()

trace_return_t pajeSetCompress ( int  val)

Enable trace compression.

Parameters
val0 means no compression, otherwize the output files will be compressed.
Returns
0 if success
An error code otherwise

◆ pajeSetState()

trace_return_t pajeSetState ( varPrec  time,
const char *  type,
const char *  cont,
const char *  val 
)

Set the State of a Container.

Parameters
timeTime at which the state is set
typeType of the state
contContainer in this state
valEntity value of the state of the container
Returns
0 if success
An error code otherwise

◆ pajeSetVar()

trace_return_t pajeSetVar ( varPrec  time,
const char *  type,
const char *  cont,
varPrec  val 
)

Set a Variable value.

Parameters
timeTime at which the variable is set
typeType of the variable
contContainer containing the variable
valValue of the variable
Returns
0 if success
An error code otherwise

◆ pajeStartLink()

trace_return_t pajeStartLink ( varPrec  time,
const char *  type,
const char *  cont,
const char *  src,
const char *  val,
const char *  key 
)

Start a link.

Parameters
timeTime at which the link starts
typeType of the link
contContainer parent of the source and destination containers containing the link
srcSource container
valValue of the link
keyKey used to match start link with end link
Returns
0 if success
An error code otherwise

◆ pajeSubVar()

trace_return_t pajeSubVar ( varPrec  time,
const char *  type,
const char *  cont,
varPrec  val 
)

Substract a value from a Variable.

Parameters
timeTime at which the variable is incremented
typeType of the variable
contContainer containing the variable
valValue substracted
Returns
0 if success
An error code otherwise

◆ viteEndTrace()

viteEndTrace ( )

Finalize a VITE trace.

Returns
0 if success
An error code otherwise