Home My Page Projects Code Snippets Project Openings diderot
Summary Activity Tracker Tasks SCM

SCM Repository

[diderot] Annotation of /trunk/src/compiler/codegen/codegen-fn.sml
ViewVC logotype

Annotation of /trunk/src/compiler/codegen/codegen-fn.sml

Parent Directory Parent Directory | Revision Log Revision Log


Revision 454 - (view) (download)

1 : jhr 454 (* codegen-fn.sml
2 :     *
3 :     * COPYRIGHT (c) 2010 The Diderot Project (http://diderot-language.cs.uchicago.edu)
4 :     * All rights reserved.
5 :     *)
6 :    
7 :     functor CodeGenFn (T : TARGET) : sig
8 :    
9 :     val generate : LowIL.program -> T.program
10 :    
11 :     end = struct
12 :    
13 :     structure Src = LowIL
14 :     structure SrcV = LowIL.Var
15 :    
16 :     (* a mapping from LowIL variables to target expressions. Variables get
17 :     * removed when the expressions are used as arguments.
18 :     *)
19 :     structure VDefTbl : sig
20 :     type tbl
21 :    
22 :     val newTbl : unit -> tbl
23 :     val getDefOf : tbl -> SrcV.var -> T.exp
24 :     val useDefOf : tbl -> SrcV.var -> T.exp
25 :     val setDefOf : tbl -> (SrcV.var * T.exp) -> unit
26 :    
27 :     val clear : tbl -> unit
28 :    
29 :     val bind : var_def_tbl -> (CFG.var * MTy.mlrisc_tree) -> MTy.T.stm list
30 :    
31 :     (* force all pending expressions into registers *)
32 :     val flushLoads : var_def_tbl -> MTy.T.stm list
33 :     end = struct
34 :    
35 :     end (* VDefTbl *)
36 :    
37 :     end
38 :    
39 :     end
40 :    

root@smlnj-gforge.cs.uchicago.edu
ViewVC Help
Powered by ViewVC 1.0.0