GTGPaje_Basic.h
Go to the documentation of this file.
#ifndef _GTG_PAJE_BASIC_H_
#define _GTG_PAJE_BASIC_H_
#include "GTGBasic.h"
#define FMT_PAJE 0
#define FMT_VITE 1
trace_return_t pajeInitTrace (const char* filename, int rank, gtg_flag_t flags, int fmt);
char* pajeGetName (int rk);
trace_return_t pajeSetCompress(int val);
trace_return_t pajeAddContType (const char* alias, const char* contType,
const char* name);
trace_return_t pajeAddStateType (const char* alias, const char* contType,
const char* name);
trace_return_t pajeAddEventType (const char* alias, const char* contType,
const char* name);
trace_return_t pajeAddLinkType (const char* alias , const char* name,
const char* contType, const char* srcContType,
const char* destContType);
trace_return_t pajeAddVarType (const char* alias , const char* contType,
const char* name);
trace_return_t pajeAddEntityValue (const char* alias, const char* entType,
const char* name , const char* color);
trace_return_t pajeAddContainer (varPrec time, const char* alias ,
const char* type, const char* container,
const char* name, const char* file);
trace_return_t pajeSeqAddContainer (varPrec time, const char* alias ,
const char* type, const char* container,
const char* name);
trace_return_t pajeDestroyContainer (varPrec time, const char* name,
const char* type);
trace_return_t pajeSetState (varPrec time, const char* type,
const char* cont, const char* val);
trace_return_t pajePushState (varPrec time, const char* type,
const char* cont, const char* val);
trace_return_t pajePopState (varPrec time, const char* type,
const char* cont);
trace_return_t pajeAddEvent (varPrec time, const char* type,
const char* cont, const char* val);
trace_return_t pajeStartLink (varPrec time, const char* type,
const char* cont, const char* src,
const char* val , const char* key);
trace_return_t pajeEndLink (varPrec time, const char* type,
const char* cont, const char* dest,
const char* val , const char* key);
trace_return_t pajeSetVar (varPrec time, const char* type,
const char* cont, varPrec val);
trace_return_t pajeAddVar (varPrec time, const char* type,
const char* cont, varPrec val);
trace_return_t pajeSubVar (varPrec time, const char* type,
const char* cont, varPrec val);
trace_return_t pajeAddComment (const char* comment);
trace_return_t pajeEndTrace ();
trace_return_t viteEndTrace ();
/*
* Functions to handle extra-parameters in the Paje Definitions
* This will need to be cleaned to be closer to OTF interface
*/
enum gtg_paje_evtdef_e {
GTG_PAJE_EVTDEF_DefineContainerType,
GTG_PAJE_EVTDEF_DefineStateType,
GTG_PAJE_EVTDEF_DefineEventType,
GTG_PAJE_EVTDEF_DefineVariableType,
GTG_PAJE_EVTDEF_DefineLinkType,
GTG_PAJE_EVTDEF_DefineEntityValue,
GTG_PAJE_EVTDEF_CreateContainer,
GTG_PAJE_EVTDEF_DestroyContainer,
GTG_PAJE_EVTDEF_SetState,
GTG_PAJE_EVTDEF_PushState,
GTG_PAJE_EVTDEF_PopState,
GTG_PAJE_EVTDEF_ResetState,
GTG_PAJE_EVTDEF_NewEvent,
GTG_PAJE_EVTDEF_SetVariable,
GTG_PAJE_EVTDEF_AddVariable,
GTG_PAJE_EVTDEF_SubVariable,
GTG_PAJE_EVTDEF_StartLink,
GTG_PAJE_EVTDEF_EndLink,
GTG_PAJE_EVTDEF_NBR
};
enum gtg_paje_fieldtype_e {
GTG_PAJE_FIELDTYPE_Int,
GTG_PAJE_FIELDTYPE_Hex,
GTG_PAJE_FIELDTYPE_Date,
GTG_PAJE_FIELDTYPE_Double,
GTG_PAJE_FIELDTYPE_String,
GTG_PAJE_FIELDTYPE_Color,
GTG_PAJE_FIELDTYPE_NBR
};
struct gtg_paje_edp_s {
struct gtg_paje_edp_s *next;
char *name;
enum gtg_paje_fieldtype_e type;
};
typedef struct gtg_paje_edp_s gtg_paje_edp_t;
struct gtg_paje_eventdef_s {
char *name;
int id;
gtg_paje_edp_t *first;
gtg_paje_edp_t *last;
};
typedef struct gtg_paje_eventdef_s gtg_paje_eventdef_t;
extern gtg_paje_eventdef_t paje_eventdefs[GTG_PAJE_EVTDEF_NBR];
void pajeEventDefAddParam( enum gtg_paje_evtdef_e event, const char *name,
enum gtg_paje_fieldtype_e type );
#endif /* _GTG_PAJE_BASIC_H_ */
GTGBasic.h
GTGBasic is a basic interface to generate trace in various formats.
gtg_flag_t
uint8_t gtg_flag_t
Flags that can be specified to GTG.
Definition GTGBasic.h:56
pajeAddVarType
trace_return_t pajeAddVarType(const char *alias, const char *contType, const char *name)
pajeAddEntityValue
trace_return_t pajeAddEntityValue(const char *alias, const char *entType, const char *name, const char *color)
pajeEndTrace
trace_return_t pajeEndTrace()
pajeAddEvent
trace_return_t pajeAddEvent(varPrec time, const char *type, const char *cont, const char *val)
pajeInitTrace
trace_return_t pajeInitTrace(const char *filename, int rank, gtg_flag_t flags, int fmt)
pajeSetVar
trace_return_t pajeSetVar(varPrec time, const char *type, const char *cont, varPrec val)
pajeEndLink
trace_return_t pajeEndLink(varPrec time, const char *type, const char *cont, const char *dest, const char *val, const char *key)
viteEndTrace
trace_return_t viteEndTrace()
pajeAddContType
trace_return_t pajeAddContType(const char *alias, const char *contType, const char *name)
pajeAddLinkType
trace_return_t pajeAddLinkType(const char *alias, const char *name, const char *contType, const char *srcContType, const char *destContType)
pajePopState
trace_return_t pajePopState(varPrec time, const char *type, const char *cont)
pajeAddVar
trace_return_t pajeAddVar(varPrec time, const char *type, const char *cont, varPrec val)
pajeSetState
trace_return_t pajeSetState(varPrec time, const char *type, const char *cont, const char *val)
pajeStartLink
trace_return_t pajeStartLink(varPrec time, const char *type, const char *cont, const char *src, const char *val, const char *key)
pajeAddContainer
trace_return_t pajeAddContainer(varPrec time, const char *alias, const char *type, const char *container, const char *name, const char *file)
pajeGetName
char * pajeGetName(int rk)
paje_eventdefs
gtg_paje_eventdef_t paje_eventdefs[GTG_PAJE_EVTDEF_NBR]
pajeSetCompress
trace_return_t pajeSetCompress(int val)
pajeDestroyContainer
trace_return_t pajeDestroyContainer(varPrec time, const char *name, const char *type)
pajeAddComment
trace_return_t pajeAddComment(const char *comment)
pajeEventDefAddParam
void pajeEventDefAddParam(enum gtg_paje_evtdef_e event, const char *name, enum gtg_paje_fieldtype_e type)
pajeAddStateType
trace_return_t pajeAddStateType(const char *alias, const char *contType, const char *name)
pajeSeqAddContainer
trace_return_t pajeSeqAddContainer(varPrec time, const char *alias, const char *type, const char *container, const char *name)
pajeSubVar
trace_return_t pajeSubVar(varPrec time, const char *type, const char *cont, varPrec val)
gtg_paje_evtdef_e
gtg_paje_evtdef_e
Definition GTGPaje_Basic.h:418
GTG_PAJE_EVTDEF_DefineVariableType
@ GTG_PAJE_EVTDEF_DefineVariableType
Definition GTGPaje_Basic.h:422
GTG_PAJE_EVTDEF_DefineEntityValue
@ GTG_PAJE_EVTDEF_DefineEntityValue
Definition GTGPaje_Basic.h:424
GTG_PAJE_EVTDEF_CreateContainer
@ GTG_PAJE_EVTDEF_CreateContainer
Definition GTGPaje_Basic.h:426
GTG_PAJE_EVTDEF_EndLink
@ GTG_PAJE_EVTDEF_EndLink
Definition GTGPaje_Basic.h:437
GTG_PAJE_EVTDEF_SetVariable
@ GTG_PAJE_EVTDEF_SetVariable
Definition GTGPaje_Basic.h:433
GTG_PAJE_EVTDEF_AddVariable
@ GTG_PAJE_EVTDEF_AddVariable
Definition GTGPaje_Basic.h:434
GTG_PAJE_EVTDEF_DefineLinkType
@ GTG_PAJE_EVTDEF_DefineLinkType
Definition GTGPaje_Basic.h:423
GTG_PAJE_EVTDEF_PushState
@ GTG_PAJE_EVTDEF_PushState
Definition GTGPaje_Basic.h:429
GTG_PAJE_EVTDEF_NBR
@ GTG_PAJE_EVTDEF_NBR
Definition GTGPaje_Basic.h:438
GTG_PAJE_EVTDEF_ResetState
@ GTG_PAJE_EVTDEF_ResetState
Definition GTGPaje_Basic.h:431
GTG_PAJE_EVTDEF_SetState
@ GTG_PAJE_EVTDEF_SetState
Definition GTGPaje_Basic.h:428
GTG_PAJE_EVTDEF_NewEvent
@ GTG_PAJE_EVTDEF_NewEvent
Definition GTGPaje_Basic.h:432
GTG_PAJE_EVTDEF_DestroyContainer
@ GTG_PAJE_EVTDEF_DestroyContainer
Definition GTGPaje_Basic.h:427
GTG_PAJE_EVTDEF_DefineEventType
@ GTG_PAJE_EVTDEF_DefineEventType
Definition GTGPaje_Basic.h:421
GTG_PAJE_EVTDEF_SubVariable
@ GTG_PAJE_EVTDEF_SubVariable
Definition GTGPaje_Basic.h:435
GTG_PAJE_EVTDEF_DefineStateType
@ GTG_PAJE_EVTDEF_DefineStateType
Definition GTGPaje_Basic.h:420
GTG_PAJE_EVTDEF_DefineContainerType
@ GTG_PAJE_EVTDEF_DefineContainerType
Definition GTGPaje_Basic.h:419
GTG_PAJE_EVTDEF_PopState
@ GTG_PAJE_EVTDEF_PopState
Definition GTGPaje_Basic.h:430
GTG_PAJE_EVTDEF_StartLink
@ GTG_PAJE_EVTDEF_StartLink
Definition GTGPaje_Basic.h:436
pajeAddEventType
trace_return_t pajeAddEventType(const char *alias, const char *contType, const char *name)
gtg_paje_fieldtype_e
gtg_paje_fieldtype_e
Definition GTGPaje_Basic.h:441
GTG_PAJE_FIELDTYPE_Date
@ GTG_PAJE_FIELDTYPE_Date
Definition GTGPaje_Basic.h:444
GTG_PAJE_FIELDTYPE_Color
@ GTG_PAJE_FIELDTYPE_Color
Definition GTGPaje_Basic.h:447
GTG_PAJE_FIELDTYPE_Hex
@ GTG_PAJE_FIELDTYPE_Hex
Definition GTGPaje_Basic.h:443
GTG_PAJE_FIELDTYPE_Double
@ GTG_PAJE_FIELDTYPE_Double
Definition GTGPaje_Basic.h:445
GTG_PAJE_FIELDTYPE_NBR
@ GTG_PAJE_FIELDTYPE_NBR
Definition GTGPaje_Basic.h:448
GTG_PAJE_FIELDTYPE_Int
@ GTG_PAJE_FIELDTYPE_Int
Definition GTGPaje_Basic.h:442
GTG_PAJE_FIELDTYPE_String
@ GTG_PAJE_FIELDTYPE_String
Definition GTGPaje_Basic.h:446
pajePushState
trace_return_t pajePushState(varPrec time, const char *type, const char *cont, const char *val)
trace_return_t
trace_return_t
Definition GTGTypes.h:35
varPrec
double varPrec
Use the double precision type for time and value.
Definition GTGTypes.h:28
gtg_paje_edp_s
Definition GTGPaje_Basic.h:451
gtg_paje_edp_s::next
struct gtg_paje_edp_s * next
Definition GTGPaje_Basic.h:452
gtg_paje_edp_s::type
enum gtg_paje_fieldtype_e type
Definition GTGPaje_Basic.h:454
gtg_paje_edp_s::name
char * name
Definition GTGPaje_Basic.h:453
gtg_paje_eventdef_s
Definition GTGPaje_Basic.h:458
gtg_paje_eventdef_s::name
char * name
Definition GTGPaje_Basic.h:459
gtg_paje_eventdef_s::last
gtg_paje_edp_t * last
Definition GTGPaje_Basic.h:462
gtg_paje_eventdef_s::id
int id
Definition GTGPaje_Basic.h:460
gtg_paje_eventdef_s::first
gtg_paje_edp_t * first
Definition GTGPaje_Basic.h:461