Home My Page Projects Code Snippets Project Openings SML/NJ
Summary Activity Forums Tracker Lists Tasks Docs Surveys News SCM Files

SCM Repository

[smlnj] Annotation of /sml/trunk/src/MLRISC/ra/ra.sig
ViewVC logotype

Annotation of /sml/trunk/src/MLRISC/ra/ra.sig

Parent Directory Parent Directory | Revision Log Revision Log


Revision 467 - (view) (download) (as text)

1 : monnier 467 (*
2 :     * The interface to the new register allocator.
3 :     *
4 :     * -- Allen
5 :     *)
6 :     signature RA =
7 :     sig
8 :    
9 :     structure I : INSTRUCTIONS
10 :     structure C : CELLS
11 :     structure F : RA_FLOWGRAPH
12 :     sharing F.I = I
13 :     sharing I.C = C
14 :    
15 :     datatype mode = REGISTER_ALLOCATION | COPY_PROPAGATION
16 :    
17 :     datatype optimization = DEAD_COPY_ELIM
18 :     | SPILL_COALESCING
19 :     | SPILL_COLORING
20 :    
21 :     type getreg = { pref : C.cell list,
22 :     stamp : int,
23 :     proh : int Array.array
24 :     } -> C.cell
25 :    
26 :     (*
27 :     * Perform register allocation.
28 :     *
29 :     * spillProh is a list of register ranges (inclusive) that cannot be spilled.
30 :     *
31 :     *)
32 :     val ra : mode ->
33 :     { cellkind : C.cellkind, (* kind of register *)
34 :     spillProh : (C.cell * C.cell) list, (* don't spill these *)
35 :     K : int, (* number of colors *)
36 :     dedicated : bool Array.array, (* dedicated registers *)
37 :     getreg : getreg, (* how to find a color *)
38 :     copyInstr : F.Spill.copyInstr, (* how to make a copy *)
39 :     spill : F.Spill.spill, (* spill callback *)
40 :     reload : F.Spill.reload, (* reload callback *)
41 :     optimizations: optimization list (* optimizations *)
42 :     } list -> F.flowgraph -> F.flowgraph
43 :    
44 :     end

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