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/emit/asmUtil.sml
ViewVC logotype

Annotation of /sml/trunk/src/MLRISC/emit/asmUtil.sml

Parent Directory Parent Directory | Revision Log Revision Log


Revision 796 - (view) (download)

1 : monnier 427 (*
2 :     * This is a helper module for assemblers.
3 :     *)
4 :     signature ASM_FORMAT_UTIL =
5 :     sig
6 : leunga 744 structure C : CELLS_BASIS
7 : george 545 val reginfo :
8 : leunga 744 (string -> unit) * Annotations.annotations ->
9 : leunga 775 (C.cell -> unit)
10 : leunga 796 val emit_cutsTo : (string -> unit) -> Label.label list -> unit
11 : monnier 427 end
12 :    
13 :     structure AsmFormatUtil : ASM_FORMAT_UTIL =
14 :     struct
15 :    
16 : leunga 744 structure C = CellsBasis
17 : leunga 775 fun reginfo(emit,an) =
18 :     case #get MLRiscAnnotations.PRINT_CELLINFO an of
19 :     SOME f => (fn c => emit(f c))
20 :     | NONE => (fn _ => ())
21 : leunga 796 fun emit_cutsTo emit [] = ()
22 :     | emit_cutsTo emit labels =
23 :     emit("\n\t/* cuts to:"^
24 :     List.foldr
25 :     (fn (l,"") => Label.nameOf l
26 :     | (l,s) => Label.nameOf l^","^s)
27 :     "" labels^" */\n")
28 : monnier 427 end

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