comparison nworker.rhope @ 66:d4b44ae2e34a

New variant of C backend works now
author Mike Pavone <pavone@retrodev.com>
date Sun, 06 Jun 2010 20:29:10 -0400
parents 689fb73e7612
children d0ce696786cc
comparison
equal deleted inserted replaced
65:1db811fa4744 66:d4b44ae2e34a
1 Import extendlib.rhope 1 Import extendlib.rhope
2 Import cbackend.rhope 2 Import cbackend.rhope
3 3 Import number.rhope
4 Import boolean.rhope
4 5
5 Blueprint Condition Set 6 Blueprint Condition Set
6 { 7 {
7 Variables 8 Variables
8 Subsets 9 Subsets
1322 out <- [worker]Compile Worker[backend, name] 1323 out <- [worker]Compile Worker[backend, name]
1323 } 1324 }
1324 1325
1325 Compile Program@NProgram[prog, backend:out] 1326 Compile Program@NProgram[prog, backend:out]
1326 { 1327 {
1327 backend with bps <- Generate Number Methods[Fold["_Compile Program BP Special", Fold["_Compile Program BP", backend, [prog]Blueprints >>], [prog]Blueprints >>]] 1328 backend with bps <- Generate Boolean Methods[Generate Number Methods[Fold["_Compile Program BP Special", Fold["_Compile Program BP", backend, [prog]Blueprints >>], [prog]Blueprints >>]]]
1328 { Print["All blueprints added"] } 1329 { Print["All blueprints added"] }
1329 workers with infer <- SMap[[prog]Workers >>, ["Infer Types"]Set Input[1, prog]] 1330 workers with infer <- SMap[[prog]Workers >>, ["Infer Types"]Set Input[1, prog]]
1330 { Print["Type inference complete"] } 1331 { Print["Type inference complete"] }
1331 out <- Fold["_Compile Program", backend with bps, workers with infer] 1332 out <- Fold["_Compile Program", backend with bps, workers with infer]
1332 } 1333 }