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

SCM Repository

[smlnj] View of /sml/trunk/src/compiler/CodeGen/cpscompile/invokegc.sig
ViewVC logotype

View of /sml/trunk/src/compiler/CodeGen/cpscompile/invokegc.sig

Parent Directory Parent Directory | Revision Log Revision Log


Revision 984 - (download) (as text) (annotate)
Wed Nov 21 19:00:08 2001 UTC (18 years, 7 months ago) by george
File size: 1635 byte(s)
  Implemented a complete redesign of MLRISC pseudo-ops. Now there
  ought to never be any question of incompatabilities with
  pseudo-op syntax expected by host assemblers.

  For now, only modules supporting GAS syntax are implemented
  but more should follow, such as MASM, and vendor assembler
  syntax, e.g. IBM as, Sun as, etc.
(*
 * This is an alternative module for generating GC code.
 * There are a few improvements.
 *
 * All code to invoke GC is generated once at the end of the
 * compilation unit---with one exception. For each cluster, a 
 * call to GC is a jump  to the end of the cluster  where there 
 * is another jump.
 * Code to invoke GC for known functions is generated at the end of
 * the cluster. This is important as there may be spilling across
 * gc invocation calls.
 *)

signature INVOKE_GC =
sig
   structure TS    : MLTREE_STREAM
   structure CFG   : CONTROL_FLOW_GRAPH 
		      where P = TS.S.P
				

   type t = { maxAlloc : int,
              regfmls  : TS.T.mlrisc list,
	      regtys   : CPS.cty list,
	      return   : TS.T.stm
            }
   type stream = (TS.T.stm, TS.T.mlrisc list, CFG.cfg) TS.stream

      (* initialize the state before compiling a module *)
   val init : unit -> unit

      (* generate a check limit for standard function *)
   val stdCheckLimit : stream -> t -> unit

      (* generate a check limit for known function *)
   val knwCheckLimit : stream -> t -> unit

      (* generate a check limit for optimized, known function *)
   val optimizedKnwCheckLimit : stream -> t -> unit

      (* generate a long jump to call gc *)
   val emitLongJumpsToGCInvocation : stream -> unit

      (* generate all GC invocation code in a module *)
   val emitModuleGC : stream -> unit

      (* generate the actual GC invocation code *)
   val callGC : stream ->
                {regfmls : TS.T.mlrisc list, 
                 regtys : CPS.cty list,
                 ret : TS.T.stm
                }  -> unit

end

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