Module Data_for_aorai

module Data_for_aorai: sig .. end
Return the buchi automata as stored after parsing

Module of data management used in all the plugin Aorai. Operations are mainly accessors for data. The use of this module is mainly done through the ltl_utils module.


module Aorai_state: Datatype.Make_with_collections(sig
type t = Promelaast.state 
val structural_descr : Structural_descr.t
val reprs : Promelaast.state list
val name : string
val equal : Promelaast.state -> Promelaast.state -> bool
val hash : Promelaast.state -> int
val rehash : 'a -> 'a
val compare : Promelaast.state -> Promelaast.state -> int
val copy : 'a -> 'a
val internal_pretty_code : 'a -> 'b
val pretty : Format.formatter -> Promelaast.state -> unit
val varname : 'a -> 'b
val mem_project : (Project_skeleton.t -> bool) -> 'a -> bool
end)
module Aorai_typed_trans: Datatype.Make_with_collections(sig
val name : string
type t = (Promelaast.typed_condition * Promelaast.action) Promelaast.trans 
val structural_descr : Structural_descr.t
val reprs : (Promelaast.typed_condition * Promelaast.single_action list) Promelaast.trans
list
val equal : 'a Promelaast.trans -> 'b Promelaast.trans -> bool
val hash : 'a Promelaast.trans -> int
val rehash : 'a -> 'a
val compare : 'a Promelaast.trans -> 'b Promelaast.trans -> int
val copy : 'a -> 'a
val internal_pretty_code : 'a -> 'b
val pretty : Format.formatter ->
(Promelaast.typed_condition * Promelaast.action) Promelaast.trans -> unit
val varname : 'a -> 'b
val mem_project : (Project_skeleton.t -> bool) -> 'a -> bool
end)
module State_var: State_builder.Hashtbl(Aorai_state.Hashtbl)(Cil_datatype.Varinfo)(sig
val name : string
val dependencies : State.t list
val size : int
end)
val get_state_var : State_var.key -> State_var.data
val get_state_logic_var : State_var.key -> Cil_types.logic_var
module Max_value_counter: State_builder.Hashtbl(Cil_datatype.Term.Hashtbl)(Cil_datatype.Term)(sig
val name : string
val dependencies : State.t list
val size : int
end)
val find_max_value : Max_value_counter.key ->
Max_value_counter.data option
val raise_error : string -> 'a
val por : Promelaast.condition -> Promelaast.condition -> Promelaast.condition
val pand : Promelaast.condition -> Promelaast.condition -> Promelaast.condition
val pnot : Promelaast.condition -> Promelaast.condition
val is_same_expression : Promelaast.expression -> Promelaast.expression -> bool
val declared_logics : (string, Cil_types.logic_info) Hashtbl.t
val add_logic : string -> Cil_types.logic_info -> unit
val get_logic : string -> Cil_types.logic_info
val declared_predicates : (string, Cil_types.logic_info) Hashtbl.t
val add_predicate : string -> Cil_types.logic_info -> unit
val get_predicate : string -> Cil_types.logic_info
val transStart : string
val transStop : string
val transCond : string
val transCondP : string
val loopInit : string
val curState : string
val curStateOld : string
val curTrans : string
val curOp : string
val curOpStatus : string
val acceptSt : string
val nbOp : string
val nbStates : string
val nbAcceptSt : string
val nbTrans : string
val macro_ligth : string
val macro_full : string
val macro_pure : string
val listOp : string
val listStatus : string
val callStatus : string
val termStatus : string
val states : string
val buch_sync : string
val automata : (Aorai_state.t list *
(Promelaast.typed_condition * Promelaast.action) Promelaast.trans list)
Pervasives.ref
val cond_of_parametrizedTransitions : '_a list list array Pervasives.ref
val variables_from_c : string list Pervasives.ref
val functions_from_c : string list Pervasives.ref
val ignored_functions : String.t list Pervasives.ref
val getAutomata : unit ->
Aorai_state.t list *
(Promelaast.typed_condition * Promelaast.action) Promelaast.trans list
Return the buchi automata as stored after parsing
val getNumberOfTransitions : unit -> int
Return the number of transitions of the automata
val getNumberOfStates : unit -> int
Return the number of states of the automata
val is_c_global : string -> bool
val get_fresh : string -> string
module AuxVariables: State_builder.List_ref(Cil_datatype.Varinfo)(sig
val name : string
val dependencies : State.t list
end)
module AbstractLogicInfo: State_builder.List_ref(Cil_datatype.Logic_info)(sig
val name : string
val dependencies : State.t list
end)
class change_var : Cil_datatype.Logic_var.t -> Cil_types.logic_var -> object .. end
val change_var_term : Cil_datatype.Logic_var.t ->
Cil_types.logic_var -> Cil_types.term -> Cil_types.term
val update_condition : Cil_datatype.Logic_var.t ->
Cil_types.logic_var ->
Promelaast.typed_condition -> Promelaast.typed_condition
val pebble_set_at : Cil_types.logic_info -> Cil_types.logic_label -> Cil_types.term
Given a logic info representing a set of pebbles and a label, returns the term corresponding to evaluating the set at the label.
val memo_multi_state : Promelaast.state -> Cil_types.logic_info * Cil_types.logic_var
val change_bound_var : Promelaast.state ->
Promelaast.state -> Promelaast.typed_condition -> Promelaast.typed_condition
val add_aux_variable : AuxVariables.data_in_list -> unit
val aux_variables : unit -> AuxVariables.data
Global auxiliary variables generated during type-checking of transitions
val abstract_logic_info : unit -> AbstractLogicInfo.data
Global logic info generated during type-checking (mostly encoding of ghost variables having a logic type)
module StateIndex: State_builder.Counter(sig
val name : string
end)
module TransIndex: State_builder.Counter(sig
val name : string
end)
val new_state : string -> Promelaast.state
val new_intermediate_state : unit -> Promelaast.state
val new_trans : Promelaast.state -> Promelaast.state -> 'a -> 'a Promelaast.trans
val check_states : string -> unit
val cst_one : Promelaast.expression
val cst_zero : Promelaast.expression
val is_cst_zero : Promelaast.expression -> bool
val is_cst_one : Promelaast.expression -> bool
val is_single : Promelaast.seq_elt -> bool
type eps_trans = 
| Normal of Promelaast.typed_condition * Promelaast.action
| Epsilon of Promelaast.typed_condition * Promelaast.action
val print_epsilon_trans : Format.formatter -> eps_trans -> unit
type current_event = 
| ECall of Cil_types.kernel_function
* Cil_types.logic_var Cil_datatype.Varinfo.Hashtbl.t
* eps_trans Promelaast.trans
| EReturn of Cil_types.kernel_function
| ECOR of Cil_types.kernel_function
| ENone
| EMulti
val add_current_event : current_event ->
current_event list ->
Promelaast.typed_condition ->
current_event list * Promelaast.typed_condition
val merge_current_event : current_event list ->
current_event list ->
Promelaast.typed_condition ->
Promelaast.typed_condition ->
current_event list * Promelaast.typed_condition
val get_bindings : Promelaast.state option -> Cil_types.logic_var -> Cil_types.term_lval
val get_bindings_term : Promelaast.state option ->
Cil_types.logic_var -> Cil_types.logic_type -> Cil_types.term
val memo_aux_variable : eps_trans Promelaast.trans ->
Promelaast.state option ->
Cil_types.logic_var Cil_datatype.Varinfo.Hashtbl.t ->
Cil_datatype.Varinfo.Hashtbl.key -> Cil_types.term
val check_one : bool ->
current_event ->
Promelaast.state option -> Datatype.String.t -> Cil_types.term option
val find_in_env : current_event list ->
Promelaast.state option -> Datatype.String.t -> Cil_types.term
val find_prm_in_env : current_event list ->
?tr:eps_trans Promelaast.trans ->
Promelaast.state option ->
string ->
Datatype.String.t ->
current_event list * Cil_types.term *
Promelaast.typed_condition
module C_logic_env: sig .. end
module LTyping: Logic_typing.Make(C_logic_env)
val type_expr : current_event list ->
?tr:eps_trans Promelaast.trans ->
?current:Promelaast.state ->
Promelaast.expression ->
current_event list * Cil_types.term *
Promelaast.typed_condition
val type_cond : bool ->
current_event list ->
eps_trans Promelaast.trans ->
Promelaast.condition ->
current_event list * Promelaast.typed_condition
module Reject_state: State_builder.Option_ref(Aorai_state)(sig
val name : string
val dependencies : State.t list
end)
val get_reject_state : unit -> Reject_state.data
val add_if_needed : Aorai_state.t list ->
Aorai_state.t -> Aorai_state.t list
val type_seq : bool ->
'a Promelaast.trans ->
current_event list ->
bool ->
Aorai_state.t ->
Aorai_state.t ->
Promelaast.sequence ->
current_event list * Aorai_state.t list *
eps_trans Promelaast.trans list *
Aorai_state.t * Aorai_state.t
val single_path : Promelaast.state list * 'a Promelaast.trans list ->
'b Promelaast.trans -> bool
val find_otherwise_trans : 'a * Promelaast.parsed_condition Promelaast.trans list ->
Promelaast.state -> Promelaast.state option
val type_trans : Promelaast.state list * Promelaast.parsed_condition Promelaast.trans list ->
current_event list ->
Promelaast.parsed_condition Promelaast.trans ->
Aorai_state.t list *
eps_trans Promelaast.trans list * bool
val add_reject_trans : Aorai_state.t list *
(Promelaast.typed_condition * 'a list) Promelaast.trans list ->
Promelaast.state list ->
Aorai_state.t list *
(Promelaast.typed_condition * 'a list) Promelaast.trans list
val propagate_epsilon_transitions : Promelaast.state list * eps_trans Promelaast.trans list ->
Promelaast.state list *
(Promelaast.typed_condition * Promelaast.single_action list) Promelaast.trans
list
val add_default_trans : 'a * (Promelaast.typed_condition * 'b list) Promelaast.trans list ->
'c Promelaast.trans list ->
'a * (Promelaast.typed_condition * 'b list) Promelaast.trans list
val type_cond_auto : Aorai_state.t list *
Promelaast.parsed_condition Promelaast.trans list ->
Aorai_state.t list *
(Promelaast.typed_condition * Promelaast.action) Promelaast.trans list
val setAutomata : Aorai_state.t list *
Promelaast.parsed_condition Promelaast.trans list -> unit
Stores the buchi automaton and its variables and functions as it is returned by the parsing
val getState : int -> Aorai_state.t
val getStateName : int -> string
val getTransition : int -> (Promelaast.typed_condition * Promelaast.action) Promelaast.trans
val setCData : unit -> unit
Initializes some tables according to data from Cil AST.

Initializes some tables according to data from Cil AST.

val getFunctions_from_c : unit -> string list
Return the list of all function name observed in the C file, except ignored functions.
val getVariables_from_c : unit -> string list
Return the list of all variables name observed in the C file.
val getIgnoredFunctions : unit -> String.t list
Return the list of names of all ignored functions. A function is ignored if it is used in C file and if its declaration is unavailable.
val addIgnoredFunction : String.t -> unit
Return the list of names of all ignored functions. A function is ignored if it is used in C file and if its declaration is unavailable.
val isIgnoredFunction : String.t -> bool
Return true if and only if the given string fname denotes an ignored function.
val is_reject_state : Aorai_state.t -> bool
val varinfos : (string, Cil_types.varinfo) Hashtbl.t
val paraminfos : (string * string, Cil_types.varinfo) Hashtbl.t
val set_varinfo : string -> Cil_types.varinfo -> unit
val get_varinfo : string -> Cil_types.varinfo
val get_logic_var : string -> Cil_types.logic_var
val get_varinfo_option : string -> Cil_types.varinfo option
val set_paraminfo : string -> string -> Cil_types.varinfo -> unit
val get_paraminfo : string -> string -> Cil_types.varinfo
val set_returninfo : string -> Cil_types.varinfo -> unit
val get_returninfo : string -> Cil_types.varinfo
type range = 
| Fixed of int (*constant value*)
| Interval of int * int (*range of values*)
| Bounded of int * Cil_types.term (*range bounded by a logic term (depending on program parameter).*)
| Unbounded of int (*only the lower bound is known, there is no upper bound*)
module Range: Datatype.Make_with_collections(sig
type t = Data_for_aorai.range 
val name : string
val rehash : 'a -> 'a
val structural_descr : Structural_descr.t
val reprs : Data_for_aorai.range list
val equal : 'a -> 'a -> bool
val compare : Data_for_aorai.range -> Data_for_aorai.range -> int
val hash : Data_for_aorai.range -> int
val copy : Data_for_aorai.range -> Data_for_aorai.range
val internal_pretty_code : 'a -> Format.formatter -> 'b -> unit
val pretty : Format.formatter -> Data_for_aorai.range -> unit
val varname : 'a -> string
val mem_project : (Project_skeleton.t -> bool) -> 'a -> bool
end)
module Intervals: Cil_datatype.Term.Map.Make(Range)
module Vals: Cil_datatype.Term.Map.Make(Intervals)
val absolute_range : Max_value_counter.key -> int -> range
val merge_range : Max_value_counter.key ->
Cil_types.term ->
range -> range -> range
val tlval : Cil_types.term_lval -> Cil_types.term
val included_range : range -> range -> bool
val unchanged : Cil_datatype.Term.Map.key -> range Cil_datatype.Term.Map.t
val merge_bindings : range Cil_datatype.Term.Map.t Cil_datatype.Term.Map.t ->
range Cil_datatype.Term.Map.t Cil_datatype.Term.Map.t ->
range Cil_datatype.Term.Map.t Cil_datatype.Term.Map.t
module End_state: Aorai_state.Map.Make(Datatype.Triple(Aorai_state.Set)(Aorai_state.Set)(Vals))
type end_state = End_state.t 
module Case_state: Aorai_state.Map.Make(End_state)
The data associated to each statement: We have a mapping from each possible state at the entrance to the function (before actual transition) to the current state possibles, associated to any action that has occured on that path.
type state = Case_state.t 
val pretty_state : Format.formatter ->
(Aorai_state.Set.t * Aorai_state.Set.t *
Range.t Cil_datatype.Term.Map.t Cil_datatype.Term.Map.t)
Aorai_state.Map.t Aorai_state.Map.t ->
unit
val included_state : (Aorai_state.Set.t * Aorai_state.Set.t *
range Cil_datatype.Term.Map.t Cil_datatype.Term.Map.t)
Aorai_state.Map.t Aorai_state.Map.t ->
(Aorai_state.Set.t * Aorai_state.Set.t *
range Cil_datatype.Term.Map.t Cil_datatype.Term.Map.t)
Aorai_state.Map.t Aorai_state.Map.t ->
bool
val merge_end_state : (Aorai_state.Set.t * Aorai_state.Set.t *
range Cil_datatype.Term.Map.t Cil_datatype.Term.Map.t)
Aorai_state.Map.t ->
(Aorai_state.Set.t * Aorai_state.Set.t *
range Cil_datatype.Term.Map.t Cil_datatype.Term.Map.t)
Aorai_state.Map.t ->
(Aorai_state.Set.t * Aorai_state.Set.t *
range Cil_datatype.Term.Map.t Cil_datatype.Term.Map.t)
Aorai_state.Map.t
val merge_state : (Aorai_state.Set.t * Aorai_state.Set.t *
range Cil_datatype.Term.Map.t Cil_datatype.Term.Map.t)
Aorai_state.Map.t Aorai_state.Map.t ->
(Aorai_state.Set.t * Aorai_state.Set.t *
range Cil_datatype.Term.Map.t Cil_datatype.Term.Map.t)
Aorai_state.Map.t Aorai_state.Map.t ->
(Aorai_state.Set.t * Aorai_state.Set.t *
range Cil_datatype.Term.Map.t Cil_datatype.Term.Map.t)
Aorai_state.Map.t Aorai_state.Map.t
module Pre_state: Kernel_function.Make_Table(Case_state)(sig
val name : string
val dependencies : State.t list
val size : int
end)
val set_kf_init_state : Pre_state.key -> Pre_state.data -> unit
val dkey : Aorai_option.category
val replace_kf_init_state : Kernel_function.t -> Pre_state.data -> unit
val get_kf_init_state : Pre_state.key -> Pre_state.data
module Post_state: Kernel_function.Make_Table(Case_state)(sig
val name : string
val dependencies : State.t list
val size : int
end)
val set_kf_return_state : Post_state.key -> Post_state.data -> unit
val replace_kf_return_state : Post_state.key -> Post_state.data -> unit
val get_kf_return_state : Post_state.key -> Post_state.data
module Loop_init_state: State_builder.Hashtbl(Cil_datatype.Stmt.Hashtbl)(Case_state)(sig
val name : string
val dependencies : State.t list
val size : int
end)
val set_loop_init_state : Loop_init_state.key ->
Loop_init_state.data -> unit
val replace_loop_init_state : Loop_init_state.key ->
Loop_init_state.data -> unit
val get_loop_init_state : Loop_init_state.key -> Loop_init_state.data
module Loop_invariant_state: State_builder.Hashtbl(Cil_datatype.Stmt.Hashtbl)(Case_state)(sig
val name : string
val dependencies : State.t list
val size : int
end)
val set_loop_invariant_state : Loop_invariant_state.key ->
Loop_invariant_state.data -> unit
val replace_loop_invariant_state : Loop_invariant_state.key ->
Loop_invariant_state.data -> unit
val get_loop_invariant_state : Loop_invariant_state.key ->
Loop_invariant_state.data
val pretty_pre_state : Format.formatter -> unit
val pretty_post_state : Format.formatter -> unit
val pretty_loop_init : Format.formatter -> unit
val pretty_loop_invariant : Format.formatter -> unit
val debug_computed_state : unit -> unit
val removeUnusedTransitionsAndStates : unit -> unit
val func_to_op_func : string -> string
val used_enuminfo : (string, Cil_types.enuminfo) Hashtbl.t
val set_usedinfo : string -> Cil_types.enuminfo -> unit
val get_usedinfo : string -> Cil_types.enuminfo
val get_cenum_option : string -> Cil_types.constant option
val func_enum_type : unit -> Cil_types.typ
val status_enum_type : unit -> Cil_types.typ
val func_to_cenum : string -> Cil_types.constant
val op_status_to_cenum : Promelaast.funcStatus -> Cil_types.constant