Home My Page Projects Code Snippets Project Openings diderot
Summary Activity Tracker Tasks SCM

SCM Repository

[diderot] Diff of /branches/vis15/src/compiler/target-cpu/gen.sml
ViewVC logotype

Diff of /branches/vis15/src/compiler/target-cpu/gen.sml

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

revision 3994, Sat Jun 18 18:41:33 2016 UTC revision 3995, Sat Jun 18 20:00:19 2016 UTC
# Line 132  Line 132 
132    (* generate source code that is common to both libraries and standalone executables *)    (* generate source code that is common to both libraries and standalone executables *)
133      fun outputSrc (outS, env, spec, prog, strand, substitutions, genInputCode) = let      fun outputSrc (outS, env, spec, prog, strand, substitutions, genInputCode) = let
134            val IR.Program{            val IR.Program{
135                    consts, inputs, globals, globalInit, create as IR.Create{dim, ...}, ...                    consts, inputs, globals, globInit, create as IR.Create{dim, ...},
136                      init, update, ...
137                  } = prog                  } = prog
138            val IR.Strand{name=strandName, ...} = strand            val IR.Strand{name=strandName, ...} = strand
139            val ppDecl = Out.decl outS            val ppDecl = Out.decl outS
# Line 156  Line 157 
157              ppDecl (GenWorld.genStruct(spec, strandName, Option.getOpt(dim, 1)));              ppDecl (GenWorld.genStruct(spec, strandName, Option.getOpt(dim, 1)));
158              List.app ppDecl (genInputCode());              List.app ppDecl (genInputCode());
159              if #hasGlobals spec              if #hasGlobals spec
160                then ppDecl (genInitGlobals (env, globalInit))                then ppDecl (genInitGlobals (env, globInit))
161                else ();                else ();
162              List.app ppDecl methods;              List.app ppDecl methods;
163              List.app ppDecl (GenOutputs.gen (env, dim, outputs));              List.app ppDecl (GenOutputs.gen (env, dim, outputs));
164              ppDecl (CL.verbatimDcl [Fragments.worldMethods] substitutions);              ppDecl (CL.verbatimDcl [Fragments.worldMethods] substitutions);
165              ppDecl (GenWorld.genInitiallyFun (env, strand, create));              ppDecl (GenWorld.genInitiallyFun (env, strand, create));
166              ppDecl (runFrag (spec, substitutions))              ppDecl (runFrag (spec, substitutions))
167    (* FIXME: what about the global initially and update code? *)
168            end            end
169    
170      fun exec (spec : TargetSpec.t, prog) = let      fun exec (spec : TargetSpec.t, prog) = let

Legend:
Removed from v.3994  
changed lines
  Added in v.3995

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