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 4350, Tue Aug 2 19:20:11 2016 UTC revision 4351, Wed Aug 3 01:15:46 2016 UTC
# Line 251  Line 251 
251            val outS = openCxxOut baseName            val outS = openCxxOut baseName
252            val ppDecl = Out.decl outS            val ppDecl = Out.decl outS
253            val fragment = Out.fragment substitutions outS            val fragment = Out.fragment substitutions outS
254              val {preWorld, postWorld} = GenTysAndOps.gen (env, CollectInfo.collect prog)
255            in            in
256              ppDecl (CL.verbatimDcl [CxxFragments.execHead] substitutions);              ppDecl (CL.verbatimDcl [CxxFragments.execHead] substitutions);
257              List.app ppDecl (GenTysAndOps.gen (env, CollectInfo.collect prog));              List.app ppDecl preWorld;
258              ppDecl (CL.verbatimDcl [CxxFragments.namespaceOpen] substitutions);              ppDecl (CL.verbatimDcl [CxxFragments.namespaceOpen] substitutions);
259              ppDecl (CL.verbatimDcl [CxxFragments.nrrdSaveHelper] substitutions);              ppDecl (CL.verbatimDcl [CxxFragments.nrrdSaveHelper] substitutions);
260              outputSrc (outS, env, spec, prog, strand, substitutions,              outputSrc (outS, env, spec, prog, strand, substitutions,
261                fn () => (                fn () => (
262                    postWorld @
263                  GenInputs.genInputsStruct (env, inputs) @                  GenInputs.genInputsStruct (env, inputs) @
264                  GenInputs.genExecInputFuns (env, prog) @                  GenInputs.genExecInputFuns (env, prog) @
265                  GenOutputsUtil.genRegisterOutputOpts (env, OutputUtil.gatherOutputs prog)));                  GenOutputsUtil.genRegisterOutputOpts (env, OutputUtil.gatherOutputs prog)));
# Line 280  Line 282 
282            val fragment = Out.fragment substitutions outS            val fragment = Out.fragment substitutions outS
283          (* gather the outputs *)          (* gather the outputs *)
284            val outputs = OutputUtil.gatherOutputs prog            val outputs = OutputUtil.gatherOutputs prog
285              val {preWorld, postWorld} = GenTysAndOps.gen (env, CollectInfo.collect prog)
286            in            in
287            (* generate the library .h file *)            (* generate the library .h file *)
288              GenLibraryInterface.gen {              GenLibraryInterface.gen {
# Line 290  Line 293 
293                  outputs = outputs                  outputs = outputs
294                };                };
295              ppDecl (CL.verbatimDcl [CxxFragments.libCXXHead] substitutions);              ppDecl (CL.verbatimDcl [CxxFragments.libCXXHead] substitutions);
296              List.app ppDecl (GenTysAndOps.gen (env, CollectInfo.collect prog));              List.app ppDecl preWorld;
297              ppDecl (CL.verbatimDcl [CxxFragments.namespaceOpen] substitutions);              ppDecl (CL.verbatimDcl [CxxFragments.namespaceOpen] substitutions);
298              ppDecl (CL.verbatimDcl [CxxFragments.nrrdSaveHelper] substitutions);              ppDecl (CL.verbatimDcl [CxxFragments.nrrdSaveHelper] substitutions);
299              List.app ppDecl (GenInputs.genDefinedInpStruct inputs);              List.app ppDecl (GenInputs.genDefinedInpStruct inputs);
300              outputSrc (outS, env, spec, prog, strand, substitutions,              outputSrc (outS, env, spec, prog, strand, substitutions,
301                fn () => (GenInputs.genLibraryInputFuns (env, prog)));                fn () => (postWorld @ GenInputs.genLibraryInputFuns (env, prog)));
302              ppDecl (CL.verbatimDcl [CxxFragments.namespaceClose] substitutions);              ppDecl (CL.verbatimDcl [CxxFragments.namespaceClose] substitutions);
303              ppDecl (CL.verbatimDcl [CPUFragments.cWrappers] substitutions);              ppDecl (CL.verbatimDcl [CPUFragments.cWrappers] substitutions);
304              Out.closeOut outS;              Out.closeOut outS;

Legend:
Removed from v.4350  
changed lines
  Added in v.4351

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