|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectat.dms.kjc.backendSupport.EmitCode
public class EmitCode
Takes a ComputeNode collection, a collection of Channel's, and a mapping from Channel x end -> ComputeNode and emits code for the ComputeNode. Inner class CodeGen is the visitor that emits the code for a JPhylum.
Nested Class Summary | |
---|---|
protected class |
EmitCode.CodeGen
Class to actually emit code. |
Field Summary | |
---|---|
protected static String |
ARRAY_COPY
|
protected BackEndFactory |
backendbits
|
protected EmitCode.CodeGen |
codegen
|
Constructor Summary | |
---|---|
EmitCode(BackEndFactory backendbits)
Constructor. |
Method Summary | |
---|---|
void |
emitCodeForComputeNode(ComputeNode n,
CodegenPrintWriter p)
|
void |
emitCodeForComputeNode(ComputeNode n,
CodegenPrintWriter p,
EmitCode.CodeGen codegen)
Given a ComputeNode and a CodegenPrintWrite, print all code for the ComputeNode. |
void |
emitCodeForComputeStore(SIRCodeUnit fieldsAndMethods,
ComputeNode n,
CodegenPrintWriter p,
EmitCode.CodeGen codegen)
|
void |
generateCHeader(CodegenPrintWriter p)
Standard code for front of a C file here. |
void |
generateMain(CodegenPrintWriter p)
Generate a "main" function. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected static final String ARRAY_COPY
protected BackEndFactory backendbits
protected EmitCode.CodeGen codegen
Constructor Detail |
---|
public EmitCode(BackEndFactory backendbits)
backendbits
- indicates BackEndFactory containing all useful info.Method Detail |
---|
public void emitCodeForComputeNode(ComputeNode n, CodegenPrintWriter p)
public void emitCodeForComputeNode(ComputeNode n, CodegenPrintWriter p, EmitCode.CodeGen codegen)
n
- The ComputeNode to emit code for.p
- The CodegenPrintWriter (left open on return).public void emitCodeForComputeStore(SIRCodeUnit fieldsAndMethods, ComputeNode n, CodegenPrintWriter p, EmitCode.CodeGen codegen)
public void generateCHeader(CodegenPrintWriter p)
public void generateMain(CodegenPrintWriter p)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |