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/branches/idlbasis-devel/src/MLRISC/emit/cfgEmit.sml
ViewVC logotype

Diff of /sml/branches/idlbasis-devel/src/MLRISC/emit/cfgEmit.sml

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

revision 1231, Mon Jun 3 18:32:08 2002 UTC revision 1232, Tue Jun 4 21:11:15 2002 UTC
# Line 20  Line 20 
20    structure CFG = CFG    structure CFG = CFG
21    
22    fun asmEmit (Graph.GRAPH graph, blocks) = let    fun asmEmit (Graph.GRAPH graph, blocks) = let
23          val CFG.INFO{annotations=an, ...} = #graph_info graph          val CFG.INFO{annotations=an, data, decls, ...} = #graph_info graph
24          val E.S.STREAM{pseudoOp,defineLabel,emit,annotation,comment,...} =          val E.S.STREAM{pseudoOp,defineLabel,emit,annotation,comment,...} =
25               E.makeStream (!an)               E.makeStream (!an)
         fun emitAn a = if Annotations.toString a = "" then () else annotation(a)  
26          fun emitIt (id, CFG.BLOCK{labels, annotations=a, align, insns, ...}) = (          fun emitIt (id, CFG.BLOCK{labels, annotations=a, align, insns, ...}) = (
27                case !align of NONE => () | SOME p => (pseudoOp p);                case !align of NONE => () | SOME p => (pseudoOp p);
28                List.app defineLabel (!labels);                List.app defineLabel (!labels);
29                List.app emitAn (!a);                List.app emitAn (!a);
30                List.app emit (rev (!insns)))                List.app emit (rev (!insns)))
31            and emitAn a = if Annotations.toString a = "" then () else annotation(a)
32          in          in
33            List.app emitAn (!an);            List.app emitAn (!an);
34            List.app emitIt blocks            List.app pseudoOp (rev (!decls));
35              pseudoOp(PseudoOpsBasisTyp.TEXT);
36              List.app emitIt blocks;
37              List.app pseudoOp (rev (!data))
38    
39          end          end
40  end  end
41    

Legend:
Removed from v.1231  
changed lines
  Added in v.1232

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