Initial snarf.
[shack.git] / arch / x86 / util / x86_mir_env.ml
blob8f2e3de3df75fedb54c3d29e2b08943bbef23eb9
1 (*
2 Environment for MIR->x86 conversion
3 Copyright (C) 2001 Justin David Smith, Caltech
5 This program is free software; you can redistribute it and/or
6 modify it under the terms of the GNU General Public License
7 as published by the Free Software Foundation; either version 2
8 of the License, or (at your option) any later version.
10 This program is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU General Public License for more details.
15 You should have received a copy of the GNU General Public License
16 along with this program; if not, write to the Free Software
17 Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
21 (* Useful modules *)
22 open X86_frame
23 open Sizeof_const
24 open Symbol
25 open Mir
26 open Mir_arity_map
29 (*** Generic codegen environment ***)
31 type esc_funs = (var * int32 * var) SymbolTable.t
32 type fun_args = ((var * atom_class) list) SymbolTable.t
34 type codegen =
35 { cg_fun_args : fun_args;
36 cg_esc_funs : esc_funs;
37 cg_reg64 : reg64_map;
38 cg_fvals : fval_map;
39 cg_arity : (symbol * int32) ArityTable.t;