ArrayDomain.S
Abstract domains representing arrays.
include S0
include Lattice.S
include Lattice.PO
widen x y
assumes leq x y
. Solvers guarantee this by calling widen old (join old new)
.
val bot : unit -> t
val is_bot : t -> bool
val top : unit -> t
val is_top : t -> bool
Returns a new abstract value, where the given index is replaced with the * given element.
val make :
?varAttr:GoblintCil.Cil.attributes ->
?typAttr:GoblintCil.Cil.attributes ->
idx ->
value ->
t
make l e
creates an abstract representation of an array of length l
* containing the element e
.
val move_if_affected :
?replace_with_const:bool ->
VDQ.t ->
t ->
GoblintCil.Cil.varinfo ->
(GoblintCil.Cil.exp -> int option) ->
t
changes the way in which the array is partitioned if this is necessitated by a change * to the variable *
val get_vars_in_e : t -> GoblintCil.Cil.varinfo list
returns the variables occuring in the expression according to which the * array was partitioned (if any)
Left fold (like List.fold_left) over the arrays elements
val smart_join :
(GoblintCil.Cil.exp -> IntOps.BigIntOps.t option) ->
(GoblintCil.Cil.exp -> IntOps.BigIntOps.t option) ->
t ->
t ->
t
val smart_widen :
(GoblintCil.Cil.exp -> IntOps.BigIntOps.t option) ->
(GoblintCil.Cil.exp -> IntOps.BigIntOps.t option) ->
t ->
t ->
t
val smart_leq :
(GoblintCil.Cil.exp -> IntOps.BigIntOps.t option) ->
(GoblintCil.Cil.exp -> IntOps.BigIntOps.t option) ->
t ->
t ->
bool
val invariant :
value_invariant:
(offset:GoblintCil.Cil.offset ->
lval:GoblintCil.Cil.lval ->
value ->
Invariant.t) ->
offset:GoblintCil.Cil.offset ->
lval:GoblintCil.Cil.lval ->
t ->
Invariant.t
val get :
?checkBounds:bool ->
VDQ.t ->
t ->
(Basetype.CilExp.t option * idx) ->
value
Returns the element residing at the given index.