|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectat.dms.kjc.cluster.TapeBase
at.dms.kjc.cluster.TapeFixedBase
public abstract class TapeFixedBase
Class of tapes with fixed size buffers. Common elements go here, the rest in subclasses.
Field Summary | |
---|---|
protected String |
bufferName
Name of buffer containing tape items |
protected int |
extra
(Maximum) number of unpopped items left on tape for next iteration. |
protected String |
headName
Name of variable with offset for push onto tape |
protected int |
items
Maximum number of items ever on the tape: for buffer size. |
protected String |
popArrayRefPrefix
in pop / peek refer to scalar as buffer[offset] but refer to array as &buffer[offset][0]...[0] |
protected String |
popArrayRefSuffix
|
protected String |
tailName
Name of variable with offset for pop from tape |
Fields inherited from class at.dms.kjc.cluster.TapeBase |
---|
dst, peek_name, pop_name, push_name, src, type, typeString |
Constructor Summary | |
---|---|
TapeFixedBase(int source,
int dest,
CType type)
|
Method Summary | |
---|---|
String |
assignPeekToVar(String varName,
String offset)
Assign the result of peeking. |
String |
assignPopToVar(String varName)
Statement, but no ";" to pop an item into a variable. |
String |
downstreamCleanup()
Any cleanup needed before exit for downstream end of tape. |
String |
downstreamDeclaration()
Data declaration: for code doing downstream processing. |
String |
downstreamDeclarationExtern()
Data declaration: following "extern" if needed else noop. |
String |
getBufferName()
|
int |
getExtra()
for debugginf only |
String |
getHeadName()
|
int |
getItems()
for debugging only |
String |
getTailName()
|
protected abstract String |
headIncrementStmts()
|
String |
pushbackCleanup()
|
String |
pushbackInit(int numberToPushBack)
|
String |
pushbackPrefix()
|
String |
pushbackSuffix()
|
protected abstract String |
tailIncrementStmts()
|
protected abstract String |
tailIncrementStmts(String numExpression)
|
protected abstract String |
tailOffsetExpr(String offset)
|
String |
upstreamCleanup()
Any cleanup needed before exit for upstream end of tape. |
String |
upstreamDeclaration()
Data declaration: for code doing upstream processing. |
String |
upstreamDeclarationExtern()
Data declaration: following "extern" if needed else noop. |
Methods inherited from class at.dms.kjc.cluster.TapeBase |
---|
dataDeclaration, dataDeclarationH, getDest, getPeekName, getPopName, getPushName, getSource, getType, newTape, peekPrefix, peekSuffix, popExpr, popExprCleanup, popExprNoCleanup, popManyItems, popNStmt, pushManyItems, pushPrefix, pushSuffix, topOfWorkIteration |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface at.dms.kjc.cluster.Tape |
---|
dataDeclaration, dataDeclarationH, getDest, getPeekName, getPopName, getPushName, getSource, getType, peekPrefix, peekSuffix, popExpr, popExprCleanup, popExprNoCleanup, popManyItems, popNStmt, pushManyItems, pushPrefix, pushSuffix, topOfWorkIteration |
Field Detail |
---|
protected int items
protected int extra
protected String bufferName
protected String headName
protected String tailName
protected String popArrayRefPrefix
protected String popArrayRefSuffix
Constructor Detail |
---|
public TapeFixedBase(int source, int dest, CType type)
source
- dest
- type
- Method Detail |
---|
public int getItems()
public int getExtra()
public String upstreamDeclarationExtern()
Tape
upstreamDeclarationExtern
in interface Tape
upstreamDeclarationExtern
in class TapeBase
public String upstreamDeclaration()
Tape
upstreamDeclaration
in interface Tape
upstreamDeclaration
in class TapeBase
public String downstreamDeclarationExtern()
Tape
downstreamDeclarationExtern
in interface Tape
downstreamDeclarationExtern
in class TapeBase
public String downstreamDeclaration()
Tape
downstreamDeclaration
in interface Tape
downstreamDeclaration
in class TapeBase
protected abstract String tailOffsetExpr(String offset)
protected abstract String tailIncrementStmts(String numExpression)
protected abstract String tailIncrementStmts()
protected abstract String headIncrementStmts()
public String upstreamCleanup()
Tape
upstreamCleanup
in interface Tape
upstreamCleanup
in class TapeBase
public String downstreamCleanup()
Tape
downstreamCleanup
in interface Tape
downstreamCleanup
in class TapeBase
public String pushbackInit(int numberToPushBack)
pushbackInit
in interface Tape
pushbackInit
in class TapeBase
public String pushbackPrefix()
pushbackPrefix
in interface Tape
pushbackPrefix
in class TapeBase
public String pushbackSuffix()
pushbackSuffix
in interface Tape
pushbackSuffix
in class TapeBase
public String pushbackCleanup()
pushbackCleanup
in interface Tape
pushbackCleanup
in class TapeBase
public String assignPopToVar(String varName)
Tape
assignPopToVar
in interface Tape
assignPopToVar
in class TapeBase
public String assignPeekToVar(String varName, String offset)
Tape
assignPeekToVar
in interface Tape
assignPeekToVar
in class TapeBase
public String getBufferName()
public String getHeadName()
public String getTailName()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |