Debian Codegraph @

lib/mlrisc-lib/MLRISC/ir-archive/idefs2.sig

raw
1 (*
2 * This is Reif and Tarjan's algorithm (SIAM J Computing 1981)
3 * for computing approximate birthpoints for expressions.
4 * For each basic block B,
5 * idef(x) = { defs(v_i) | i = 1 ... n in all paths
6 * idom(x) v_1 v_2 ... v_n x where n >= 1 and
7 * v_i <> idom(x) for all 1 <= i <= n
8 * }
9 * -- Allen
10 *)
11 signature IDEFS =
12 sig
13
14 type var = int
15
16 val compute_idefs :
17 {def_use : 'n Graph.node -> var list * var list,
18 cfg : ('n,'e,'g) Graph.graph
19 } ->
20 { idefuse : unit -> (int list * int list) Array.array,
21 ipostdefuse : unit -> (int list * int list) Array.array
22 }
23
24 end
25