module Rtltree:sig
..end
typeregister =
Register.t
typelabel =
Label.t
type
instr =
| |
Econst of |
|||
| |
Eload of |
|||
| |
Estore of |
|||
| |
Emunop of |
|||
| |
Embinop of |
(* | attention au sens : | *) |
| |
Emubranch of |
|||
| |
Embbranch of |
(* | attention au sens : | *) |
| |
Ecall of |
|||
| |
Egoto of |
Les différents instructions RTL. Chaque instruction contient la ou les étiquettes suivantes dans le graphe de flot de contrôle.
typecfg =
instr Label.map
Un graphe de flot de contrôle est un dictionnaire associant à des étiquettes des instructions RTL.
type
deffun = {
|
fun_name : |
|||
|
fun_formals : |
|||
|
fun_result : |
|||
|
fun_locals : |
(* | toutes les variables locales de la fonction maintenant regroupées ici | *) |
|
fun_entry : |
|||
|
fun_exit : |
|||
|
fun_body : |
Une fonction RTL.
type
file = {
|
funs : |
Un programme RTL.
val print_instr : Stdlib.Format.formatter -> instr -> unit
val print_graph : Stdlib.Format.formatter -> cfg -> Label.t -> Label.t -> unit
val print_deffun : Stdlib.Format.formatter -> deffun -> unit
val print_file : Stdlib.Format.formatter -> file -> unit