package goblint-cil

  1. Overview
  2. Docs

compute use/def information

module VS : sig ... end
val getUseDefFunctionRef : (GoblintCil.exp -> GoblintCil.exp list -> VS.t * VS.t * GoblintCil.exp list) Stdlib.ref

Set this global to how you want to handle function calls. This also returns a modified argument list which will be used for the purpose of Use analysis, in case you have a function that needs special treatment of its args.

val considerVariableUse : (GoblintCil.varinfo -> bool) Stdlib.ref

Say if you want to consider a variable use. This applies to variable reads only; see also considerVariableAddrOfAsUse

val considerVariableDef : (GoblintCil.varinfo -> bool) Stdlib.ref

Say if you want to consider a variable def

val considerVariableAddrOfAsUse : (GoblintCil.varinfo -> bool) Stdlib.ref

Say if you want to consider a variable addrof as a use

val considerVariableAddrOfAsDef : (GoblintCil.varinfo -> bool) Stdlib.ref

Say if you want to consider a variable addrof as a def

val extraUsesOfExpr : (GoblintCil.exp -> VS.t) Stdlib.ref

Return any vars that should be considered "used" by an expression, other than the ones it refers to directly. Deputy uses this for variables in Cast annotations.

val onlyNoOffsetsAreDefs : bool Stdlib.ref
val ignoreSizeof : bool Stdlib.ref

Should we ignore the contents of sizeof and alignof?

val varUsed : VS.t Stdlib.ref
val varDefs : VS.t Stdlib.ref
val useDefVisitor : useDefVisitorClass
val computeUseExp : ?acc:VS.t -> GoblintCil.exp -> VS.t

Compute the use information for an expression (accumulate to an existing set)

val computeUseDefInstr : ?acc_used:VS.t -> ?acc_defs:VS.t -> GoblintCil.instr -> VS.t * VS.t

Compute the use/def information for an instruction

val computeUseDefStmtKind : ?acc_used:VS.t -> ?acc_defs:VS.t -> GoblintCil.stmtkind -> VS.t * VS.t

Compute the use/def information for a statement kind. Do not descend into the nested blocks.

val computeDeepUseDefStmtKind : ?acc_used:VS.t -> ?acc_defs:VS.t -> GoblintCil.stmtkind -> VS.t * VS.t
val computeUseLocalTypes : ?acc_used:VS.t -> GoblintCil.fundec -> VS.t
OCaml

Innovation. Community. Security.