Differences between revisions 6 and 7
Deletions are marked like this. | Additions are marked like this. |
Line 18: | Line 18: |
* fetrans15: * '''name''': remove lonely names (discarded expressions, particularly from '''instance''' fiddling in fetrans1). |
NOCC: Guppy Implementation
This page contains some notes about the Guppy implementation within NOCC. There is no formal language documentation, yet. There is some informal documentation here: http://frmb.org/guppy.html.
fetrans spaghetti
Guppy adds a couple of extra front-end passes to the compiler, that do much of the work of transforming the Guppy language structure into something that can be code-generated into C (assuming the default CCCSP back-end). All of the front-end transforms are done target-unaware. Back-end transforms are used in one or two places to handle things prior to name-mapping (where most of the target-dependent stuff happens).
- fetrans:
par: create process abstractions and instances for parallel processes.
fcndef: create process abstraction of function if needed (result-less processes only).
- fetrans1:
alt: create temporary to hold selected guard index.
fcndef: parameterise results.
instance: pull apart into temporaries and assignments.
cflow: turn return statements into assignments and return.
io: create temporaries for non-addressable things (typically constants and expressions).
litstring: create temporary.
- fetrans15:
name: remove lonely names (discarded expressions, particularly from instance fiddling in fetrans1).
- fetrans2:
assign: from instance, push LHS into result parameters.
- fetrans3:
io: dismantle complex outputs into sequenced events.
alt: breaks into alt then choice on selection.