package sail

  1. Overview
  2. Docs
type 'a array_graph
val make : initial_size:int -> unit -> 'a array_graph
module IntSet : sig ... end
val get_cond : 'a array_graph -> int -> Jib.cval
val get_vertex : 'a array_graph -> int -> ('a * IntSet.t * IntSet.t) option
val iter_graph : ('a -> IntSet.t -> IntSet.t -> unit) -> 'a array_graph -> unit
val add_vertex : 'a -> 'a array_graph -> int
val add_edge : int -> int -> 'a array_graph -> unit
exception Not_a_DAG of int
val topsort : 'a array_graph -> int list
type terminator =
  1. | T_undefined of Jib.ctyp
  2. | T_match_failure
  3. | T_end of Jib.name
  4. | T_goto of string
  5. | T_jump of int * string
  6. | T_label of string
  7. | T_none
type cf_node =
  1. | CF_label of string
  2. | CF_block of Jib.instr list * terminator
  3. | CF_guard of int
  4. | CF_start of Jib.ctyp Jib_util.NameMap.t
val control_flow_graph : Jib.instr list -> int * int list * ('a list * cf_node) array_graph
val immediate_dominators : 'a array_graph -> int -> int array
type ssa_elem =
  1. | Phi of Jib.name * Jib.ctyp * Jib.name list
  2. | Pi of Jib.cval list
val ssa : Jib.instr list -> int * (ssa_elem list * cf_node) array_graph
val make_dot : Stdlib.out_channel -> (ssa_elem list * cf_node) array_graph -> unit
val make_dominators_dot : Stdlib.out_channel -> int array -> (ssa_elem list * cf_node) array_graph -> unit
OCaml

Innovation. Community. Security.