module PO: Cfgpropid.Create
(
CV
)
type
t_env = W.t_env
val new_env : Db_types.kernel_function -> W.t_env
type
description = Cfgpropid.dnode
type
t_goal = {
}
type
t_prop = t_goal list
val pp_goal : Format.formatter -> string -> t_goal -> unit
val pp_descr : Format.formatter -> t_goal -> unit
val iter_description : (Wpo.warning -> unit) -> (Wpo.dependency -> unit) -> Cfgpropid.dnode -> unit
val pp_goalx : Format.formatter -> t_goal -> unit
val pretty : Format.formatter -> t_goal list -> unit
val empty : 'a list
val dnode_cpt : int Pervasives.ref
val make_goal : WpAnnot.prop_id ->
(unit -> W.t_prop) -> Cfgpropid.dnode list -> t_goal
val merge : t_goal list ->
t_goal list -> t_goal list
val add_as_hyp : W.t_env ->
t_goal list ->
t_goal list -> t_goal list
val add_as_goal : 'a ->
t_goal list ->
t_goal list -> t_goal list
val add_hyp : W.t_env ->
WpAnnot.prop_id ->
Cil_types.predicate Cil_types.named ->
t_goal list -> t_goal list
val build_prop_of_from : W.t_env ->
WpAnnot.t_id_pred list ->
t_goal list -> t_goal list
val add_goal : W.t_env ->
WpAnnot.prop_id ->
Cil_types.predicate Cil_types.named ->
t_goal list -> t_goal list
val add_axiom : WpAnnot.prop_id ->
string ->
Cil_types.logic_label list -> Cil_types.predicate Cil_types.named -> unit
val add_assigns : W.t_env ->
WpAnnot.prop_id ->
Cil_types.logic_label ->
WpAnnot.a_kind ->
Cil_types.identified_term Cil_types.assigns list ->
t_goal list -> t_goal list
val assigns_method : unit -> Mcfg.assigns_method
val assign : W.t_env ->
Cil_types.lval ->
Cil_types.exp -> t_goal list -> t_goal list
val return : W.t_env ->
Cil_types.exp option ->
t_goal list -> t_goal list
val test : W.t_env ->
Cil_types.exp ->
t_goal list ->
t_goal list -> t_goal list
val switch : W.t_env ->
Cil_types.exp ->
(Cil_types.exp list * t_goal list) list ->
t_goal list -> t_goal list
merge the switch branches :
e
: : switch expression,
cases
: : a list of (case expression, wp for that case),
p_def
: : wp for the default branch.
Because each wp is a list, it is not so easy to merge.
So we decide to chose a simple, but not optimized, algorithm :
- we first collect a sorted list of all the ids in every branches,
- we then process each id but getting the wp for this id in each branch,
- and we then put back things together.
val call_normal : W.t_env ->
get_pre:(Db_types.kernel_function ->
(WpAnnot.prop_id * Cil_types.predicate Cil_types.named) list) ->
get_post:(Db_types.kernel_function ->
(WpAnnot.prop_id * Cil_types.predicate Cil_types.named) list) ->
get_assigns:(Db_types.kernel_function ->
Cil_types.identified_term Cil_types.assigns list) ->
Cil_types.stmt ->
Cil_types.lval option ->
Cil_types.exp ->
Cil_types.exp list ->
t_goal list -> t_goal list
val call_exit : W.t_env ->
get_pre:(Db_types.kernel_function ->
(WpAnnot.prop_id * Cil_types.predicate Cil_types.named) list) ->
get_exits:(Db_types.kernel_function ->
(WpAnnot.prop_id * Cil_types.predicate Cil_types.named) list) ->
get_assigns:(Db_types.kernel_function ->
Cil_types.identified_term Cil_types.assigns list) ->
Cil_types.stmt ->
Cil_types.exp ->
Cil_types.exp list ->
t_goal list -> t_goal list
val use_assigns : W.t_env ->
WpAnnot.prop_id ->
WpAnnot.a_kind ->
Cil_types.identified_term Cil_types.assigns list ->
t_goal list -> t_goal list
val label : W.t_env ->
Cil_types.logic_label ->
t_goal list -> t_goal list
val scope : W.t_env ->
Cil_types.varinfo list ->
Mcfg.scope -> t_goal list -> t_goal list
val close : W.t_env -> t_goal list -> t_goal list