Module Monitoring_context

module Monitoring_context: sig .. end

type query_phase = 
| Parsing_Phase
| Normalization_Phase
| Rewriting_Phase
| Factorization_Phase
| Compile_Phase
| Optimization_Phase
| Selection_Phase
| Evaluation_Phase
type phase = 
| PQuery of query_phase
| Document_Serialization_Phase
| Document_Toplevel_ParsingLoading_Phase of string
| Document_ParsingLoading_Phase of string
| External_Phase
val increment_node_count : unit -> unit
val get_node_count : unit -> int
type call_kind = 
| Prolog
| Statement
| Serialization
type stats_item = {
   glx_total_memory : float;
   glx_live_memory : float;
   glx_time : float;
   glx_node_count : int;
}
type stats_point = {
   mutable relative_stats : stats_item;
   mutable absolute_stats : stats_item;
}
type call_stat_summary = {
   mutable call_name : string;
   mutable call_kind : call_kind;
   mutable current_phase : phase option;
   query_toplevel_phase : stats_point;
   query_parsing_phase : stats_point;
   query_normalization_phase : stats_point;
   query_rewriting_phase : stats_point;
   query_factorization_phase : stats_point;
   query_compile_phase : stats_point;
   query_optimization_phase : stats_point;
   query_selection_phase : stats_point;
   query_evaluation_phase : stats_point;
   query_serialization_phase : stats_point;
   mutable document_toplevel_parsingloading_phase : (string, stats_point) Hashtbl.t;
   mutable document_parsingloading_phase : (string, stats_point) Hashtbl.t;
   external_phase : stats_point;
}
type monitor_context 
val default_monitor_context : unit -> monitor_context
val set_monitor_mem : monitor_context -> bool -> unit
val set_monitor_time : monitor_context -> bool -> unit
val get_monitor_mem : monitor_context -> bool
val get_monitor_time : monitor_context -> bool
val set_monitor_output : monitor_context -> Galax_io.output_spec -> unit
val get_monitor_output : monitor_context -> Galax_io.output_spec
val set_current_call : monitor_context ->
call_stat_summary option -> unit
val get_current_call : monitor_context ->
call_stat_summary option
val push_resume_call : monitor_context ->
call_stat_summary -> unit
val pop_resume_call : monitor_context ->
call_stat_summary option
val add_completed_call : monitor_context ->
call_stat_summary -> unit
val get_last_call : monitor_context ->
call_stat_summary option
val get_all_calls : monitor_context ->
call_stat_summary list
val string_of_call_kind : call_kind -> string
val string_of_phase : phase -> string