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/compiler/FLINT/clos/closure.sml
 [smlnj] / sml / trunk / compiler / FLINT / clos / closure.sml

# Diff of /sml/trunk/compiler/FLINT/clos/closure.sml

revision 773, Mon Jan 8 16:18:37 2001 UTC revision 898, Mon Aug 13 17:44:08 2001 UTC
# Line 1464  Line 1464
1464
1465          (* for recursive functions, always spill deeper level free variables *)          (* for recursive functions, always spill deeper level free variables *)
1466          val ((gpspill,gpfree),(fpspill,fpfree),nflag) = case lpv          val ((gpspill,gpfree),(fpspill,fpfree),nflag) = case lpv
1467            of SOME _ => (partition deep1 gpfree,partition deep1 fpfree,true)            of SOME _ =>
1468                   let fun h((v,_,_),l) =
1469                         case whatIs(initEnv,v)
1470                          of (Closure (CR(_,{free,...}))) => merge(rmv(v,free),l)
1471                           | _ => l
1472                       val gpfree = removeV(foldr h [] gpfree, gpfree)
1473                       val gpfreePart =
1474                             if length(gpfree) < numCSgpregs
1475                             then ([],gpfree)
1476                             else partition deep1 gpfree
1477                    in (gpfreePart, partition deep1 fpfree,true)
1478                   end
1479             | NONE => if ekfuns v then ((gpfree,[]),(fpfree,[]),flag)             | NONE => if ekfuns v then ((gpfree,[]),(fpfree,[]),flag)
1480                       else (partition deep2 gpfree,partition deep2 fpfree,flag)                       else (partition deep2 gpfree,partition deep2 fpfree,flag)
1481

Legend:
 Removed from v.773 changed lines Added in v.898