Module Paje

module Paje: sig .. end
This module provides support for the Pajé tool (version 1.2.3).

Pajé (available at http://paje.sourceforge.net) is a graphical tool for the analysis of multithreads and/or multiprocesses programs.

Bolt can produce Pajé-compatible traces by using statements like:

LOG Paje.t WITH Paje.new_event ...;
more information can be found in the Bolt manual.


Definitions

val t : string
The identifier message for Pajé event.
type properties = (string * string) list 
The type of information to be recorded in a trace.
type name = string 
Synonym for names.
type alias = string 
Synonym for aliases.
type color = float * float * float 
The type of colors, as three red/green/blue components (each should be between 0.0 and 1.0).

Predefined events: type definitions

val define_container_type : name:name ->
?typ:string -> ?alias:alias -> properties -> properties
Defines a new type of container with name, optional parent type, optional alias, and a list of additional properties.
val define_state_type : name:name ->
typ:string -> ?alias:alias -> properties -> properties
Defines a new type of state with name, type, optional alias, and a list of additonnal properties.
val define_event_type : name:name ->
typ:string -> ?alias:alias -> properties -> properties
Defines a new type of event with name, type, optional alias, and a list of additional properties.
val define_variable_type : name:name ->
typ:string ->
color:color -> ?alias:alias -> properties -> properties
Defines a new type of variable with name, type, optional alias, and a list of additonnal properties.
val define_link_type : name:name ->
typ:string ->
start_container_type:string ->
end_container_type:string ->
?alias:alias -> properties -> properties
Defines a new type of link with name, type, start and end container types, optional alias, and a list of additonnal properties.
val define_entity_value : name:name ->
typ:string ->
color:color -> ?alias:alias -> properties -> properties
Defines a new value for an entity value with name, type, color, optional alias, and a list of additional properties.

Predefined events: trace recording

val create_container : name:name ->
typ:string ->
?container:name ->
?alias:alias -> properties -> properties
Creates a container with name, type, optional parent container, optional alias and a list of additional properties.
val destroy_container : name:name -> typ:string -> properties -> properties
Destroys a container with name, type, and a list of additional properties.
val set_state : typ:string ->
container:name -> value:string -> properties -> properties
Changes the state of a given container to a new value with passed type, and additional list of properties.
val push_state : typ:string ->
container:name -> value:string -> properties -> properties
Pushes the current state of a given container to its own stack, and changes its state to the passed type and value.
val pop_state : typ:string -> container:name -> properties -> properties
Changes the states of a given container by poping a previously pushed value from its own stack.
val reset_state : typ:string -> container:name -> properties -> properties
Clears all previously saved values for the type of a container.
val new_event : typ:string ->
container:name -> value:string -> properties -> properties
Records a new event with type, container, value, and additional list of properties.
val set_variable : typ:string ->
container:name -> value:float -> properties -> properties
Sets the value of a container variable.
val add_variable : typ:string ->
container:name -> value:float -> properties -> properties
Increases the value of a container variable by a given amount.
val sub_variable : typ:string ->
container:name -> value:float -> properties -> properties
Decreases the value of a container variable by a given amount.
val start_link : typ:string ->
container:name ->
start_container:name ->
value:string -> key:string -> properties -> properties
Records the start of a link occuring inside a container, from a start. The key/value pair is used to match with an associated end of link.
val end_link : typ:string ->
container:name ->
end_container:name ->
value:string -> key:string -> properties -> properties
Records the end of a link occuring inside a container, to an end. The key/value pair is used to match with an associated start of link.

Layout elements

val header : string list
The header defining Pajé events.
val render : Event.t -> string
The rendering function for Pajé format.
val layout : Layout.t
The layout supporting the "Pajé" trace format. The message of the event should match the name of an EventDef defined by the "Pajé trace file format" available at http://paje.sourceforge.net/download/publication/lang-paje.pdf. The values of the fields are taken from the event properties, the "Time" field being automatically set to the time elapsed since program start (unless explicitly set through a property).
val layout_noheader : Layout.t

Functorial interface

type type_kind = 
| Container
| State
| Event
| Variable
| Link
| Entity_value
exception Invalid_type of type_kind
module type Definitions = sig .. end
The input signature of Paje.Make, that is static definition of Pajé types.
module type S = sig .. end
The output signature of Paje.Make, that is type-safe interface to Pajé functions.
module Make: 
functor (D : Definitions) -> S with type container_type = D.container_type and type event_type = D.event_type and type state_type = D.state_type and type variable_type = D.variable_type and type link_type = D.link_type
Functor building a type-safe version of Pajé trace-recording functions.