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

SCM Repository

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

Diff of /sml/trunk/src/MLRISC/ra/ra.sml

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 576, Fri Mar 10 07:27:16 2000 UTC revision 705, Wed Sep 27 18:44:44 2000 UTC
# Line 132  Line 132 
132         val {build=buildMethod, spill=spillMethod, ...} = F.services flowgraph         val {build=buildMethod, spill=spillMethod, ...} = F.services flowgraph
133    
134         (* global spill location counter *)         (* global spill location counter *)
135         val spillLoc=ref ~256         (* Note: spillLoc cannot be zero as negative locations are
136            * returned to the client to indicate spill locations.
137            *)
138           val spillLoc=ref 1
139    
140         (* How to dump the flowgraph *)         (* How to dump the flowgraph *)
141         fun dumpFlowgraph(flag, title) =         fun dumpFlowgraph(flag, title) =
# Line 245  Line 248 
248              * Mark spill nodes              * Mark spill nodes
249              *)              *)
250             fun markSpillNodes nodesToSpill =             fun markSpillNodes nodesToSpill =
251             let val marker = SPILLED(~1)             let val marker = SPILLED
252                 fun loop [] = ()                 fun loop [] = ()
253                   | loop(NODE{color, ...}::ns) = (color := marker; loop ns)                   | loop(NODE{color, ...}::ns) = (color := marker; loop ns)
254             in  loop nodesToSpill end             in  loop nodesToSpill end
# Line 255  Line 258 
258              *)              *)
259             fun markMemRegs [] = ()             fun markMemRegs [] = ()
260               | markMemRegs(NODE{number=r, color as ref(ALIASED               | markMemRegs(NODE{number=r, color as ref(ALIASED
261                            (NODE{color=ref(col as SPILLED c), ...})), ...}::ns) =                            (NODE{color=ref(col as MEMREG _), ...})), ...}::ns) =
262                  (if c >= 0 then color := col else ();                  (color := col;
263                   markMemRegs ns)                   markMemRegs ns)
264               | markMemRegs(_::ns) = markMemRegs ns               | markMemRegs(_::ns) = markMemRegs ns
265    
# Line 276  Line 279 
279                 val _ = if isOn(mode,SPILL_PROPAGATION+SPILL_COALESCING) then                 val _ = if isOn(mode,SPILL_PROPAGATION+SPILL_COALESCING) then
280                            Core.initMemMoves G                            Core.initMemMoves G
281                         else ()                         else ()
                (*  
                val spills = if isOn(mode,SPILL_PROPAGATION) then  
                                Core.spillPropagation G spills else spills  
                val _ = if isOn(mode,SPILL_COALESCING) then  
                           Core.spillCoalescing G spills else ()  
                val _ = if isOn(mode,SPILL_COLORING) then  
                           Core.spillColoring G spills else ()  
                val _ = if isOn(mode,SPILL_COALESCING+SPILL_PROPAGATION) then  
                           markMemRegs spills else ()  
                 *)  
282                 val _ = logGraph("actual spill",G);                 val _ = logGraph("actual spill",G);
283                 val {simplifyWkl,freezeWkl,moveWkl,spillWkl} =                 val {simplifyWkl,freezeWkl,moveWkl,spillWkl} =
284                      Core.initWorkLists G                      Core.initWorkLists G

Legend:
Removed from v.576  
changed lines
  Added in v.705

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