.. java:import:: fr.inria.tapenade.analysis DataFlowAnalyzer .. java:import:: fr.inria.tapenade.ir2tree ControlStruct Block ===== .. java:package:: fr.inria.tapenade.representation :noindex: .. java:type:: public class Block One Block of a Flow Graph. Blocks contain sequences of elementary instructions that are executed always in sequence from the first to the last. The last instruction may be a test which decides which Flow Arrow (FGArrow) is taken after the end of the Block's execution. If the last instruction is not a test, then there may be only one flow arrow leaving from the Block. Fields ------ analysisIsOutOfDate ^^^^^^^^^^^^^^^^^^^ .. java:field:: public boolean analysisIsOutOfDate :outertype: Block Mark useful in any Data Flow analysis to write whether this Block must be analyzed again at next analysis sweep. backReachDown ^^^^^^^^^^^^^ .. java:field:: public boolean backReachDown :outertype: Block True iff the exit of this Block can reach exit backReachUp ^^^^^^^^^^^ .. java:field:: public boolean backReachUp :outertype: Block True iff the entry of this Block can reach exit constantZones ^^^^^^^^^^^^^ .. java:field:: public BoolVector constantZones :outertype: Block The zones that are constant from the beginning of this Block till the exit of the containing Unit. This info is filled by InOutAnalyzer. controllers ^^^^^^^^^^^ .. java:field:: public TapList controllers :outertype: Block The list of blocks controlling this block, from the most deeply nested up. controllersZone ^^^^^^^^^^^^^^^ .. java:field:: public TapIntList controllersZone :outertype: Block The list of the control zones controlling this block. dominator ^^^^^^^^^ .. java:field:: public BoolVector dominator :outertype: Block Vector of the ranks of the Blocks that are certainly executed before this one. immediateDominator ^^^^^^^^^^^^^^^^^^ .. java:field:: protected Block immediateDominator :outertype: Block The closest Block certainly executed before this one. immediatePostDominator ^^^^^^^^^^^^^^^^^^^^^^ .. java:field:: protected Block immediatePostDominator :outertype: Block The closest Block certainly executed after this one. instructions ^^^^^^^^^^^^ .. java:field:: public TapList instructions :outertype: Block The ordered list of all instructions in this Block. isFGCycleHead ^^^^^^^^^^^^^ .. java:field:: public boolean isFGCycleHead :outertype: Block True if this Block has an incoming backFlow FGArrow that comes from a Block later or equal (i.e. with a greater or equal rank) in the DFST order. isFGCycleTail ^^^^^^^^^^^^^ .. java:field:: public boolean isFGCycleTail :outertype: Block True if this Block has an exiting flow FGArrow that goes to a Block earlier or equal (i.e. with a lower or equal rank) in the DFST order. parallelControls ^^^^^^^^^^^^^^^^ .. java:field:: public TapList parallelControls :outertype: Block The controlling parallel instructions for this Block. pointerInfosIn ^^^^^^^^^^^^^^ .. java:field:: public BoolMatrix pointerInfosIn :outertype: Block The matrix of pointer destinations at the begining of the block. postDominator ^^^^^^^^^^^^^ .. java:field:: public BoolVector postDominator :outertype: Block Vector of the ranks of the Blocks that are certainly executed after this one. predecessor ^^^^^^^^^^^ .. java:field:: public BoolVector predecessor :outertype: Block Vector of the ranks of the Blocks that are possibly executed before this one. rank ^^^^ .. java:field:: public int rank :outertype: Block A unique rank of this Block. -1 is for the EntryBlock. Other Blocks are numbered from 0 up, in DFST order. reachDown ^^^^^^^^^ .. java:field:: public boolean reachDown :outertype: Block True iff the exit of this Block can be reached from entry reachUp ^^^^^^^ .. java:field:: public boolean reachUp :outertype: Block True iff the entry of this Block can be reached from entry reachable ^^^^^^^^^ .. java:field:: protected boolean reachable :outertype: Block True if this Block is reachable from the Unit's entry. [llh 9Nov2023]: this info is apparently not used and is different from the info stored in "reachUp" and "reachDown". Maybe we could use the methods from Unit.computeReachability() to refine our "reachUp" and "reachDown", then remove computeReachability(). successor ^^^^^^^^^ .. java:field:: public BoolVector successor :outertype: Block Vector of the ranks of the Blocks that are possibly executed after this one. symbolTable ^^^^^^^^^^^ .. java:field:: public SymbolTable symbolTable :outertype: Block The SymbolTable of symbols visible from this Block. symbolicRk ^^^^^^^^^^ .. java:field:: public String symbolicRk :outertype: Block May be used to give a symbolic name to this Block. This name will be used when toString() shows this Block. testZone ^^^^^^^^ .. java:field:: public int testZone :outertype: Block When this Blocks end with a test, the associated test zone. unusedZones ^^^^^^^^^^^ .. java:field:: public BoolVector unusedZones :outertype: Block The zones that are unused from the beginning of this Block till the exit of the containing Unit. This info is filled by InOutAnalyzer. visit ^^^^^ .. java:field:: protected int visit :outertype: Block CLEAR, VISITING or VISITED. Constructors ------------ Block ^^^^^ .. java:constructor:: public Block(SymbolTable symbolTable, TapList parallelControls, TapList allBlocks) :outertype: Block Create an empty Block, set its SymbolTable, and register it into the list of created Blocks "allBlocks" (if nonempty). Methods ------- addBackFlow ^^^^^^^^^^^ .. java:method:: protected void addBackFlow(FGArrow arrow) :outertype: Block Adds the given arrow into the flow to this Block. addFlow ^^^^^^^ .. java:method:: protected void addFlow(FGArrow arrow) :outertype: Block Adds the given arrow into the flow from this Block. addInstrDeclTl ^^^^^^^^^^^^^^ .. java:method:: public void addInstrDeclTl(TapList decls) :outertype: Block Adds instructions "decls" after the declarations in this Block. addInstrDeclTlBeforeUse ^^^^^^^^^^^^^^^^^^^^^^^ .. java:method:: public int addInstrDeclTlBeforeUse(Instruction instr, TapList symbolDecls, TapList usageInstructions, SymbolTable declST, boolean strict) :outertype: Block Adds instruction "instr" after the declarations in this Block BUT before the declarations that depend on this declaration. :param symbolDecls: the symbols that the given "instr" declares or defines. :param declST: The SymbolTable where the new "symbolDecls" will be. :param strict: when true, vars in a COMMON must be declared before the COMMON. :return: when the instruction was moved some lines before its original location, to be before using declarations or computation instructions, returns the number of locations moved up. Otherwise returns 0. addInstrHd ^^^^^^^^^^ .. java:method:: public void addInstrHd(Tree tree) :outertype: Block Adds a new Instruction with "tree" at the head of this Block. addInstrHd ^^^^^^^^^^ .. java:method:: public void addInstrHd(Instruction instr) :outertype: Block Adds instruction "instr" at the head of this Block. addInstrHdAfterDecls ^^^^^^^^^^^^^^^^^^^^ .. java:method:: public Instruction addInstrHdAfterDecls(Tree tree) :outertype: Block Adds a new Instruction with "tree" at the head of this Block BUT after the declarations. :return: the new Instruction created. addInstrHdAfterDecls ^^^^^^^^^^^^^^^^^^^^ .. java:method:: public void addInstrHdAfterDecls(Instruction instr) :outertype: Block Adds instruction "instr" at the head of this Block BUT after the declarations. addInstrHdIfNotPresent ^^^^^^^^^^^^^^^^^^^^^^ .. java:method:: public void addInstrHdIfNotPresent(Instruction instr) :outertype: Block Adds a new use statement Instruction at the head of this Block. :param instr: fortran use statement. addInstrTl ^^^^^^^^^^ .. java:method:: public void addInstrTl(Tree instr) :outertype: Block Adds instruction tree "instr" at the end of this Block. addInstrTl ^^^^^^^^^^ .. java:method:: public void addInstrTl(Instruction instr) :outertype: Block Adds instruction "instr" at the end of this Block. addInstructionAt ^^^^^^^^^^^^^^^^ .. java:method:: public void addInstructionAt(Tree tree, int place) :outertype: Block Add inside this Block a new Instruction containing the given tree, at a location given by "place". If place is positive or 0, location is counted from the head down, and 0 means before the 1st instruction. Too large place inserts at the tail. If place is negative, location is counted from the tail up, and -1 means after the last instruction. Too large (-)place inserts at head. addTreeDeclTl ^^^^^^^^^^^^^ .. java:method:: public static TapList addTreeDeclTl(TapList trees, TapList decls) :outertype: Block Adds trees "decls" after the declarations in the list trees. addUseDecl ^^^^^^^^^^ .. java:method:: public void addUseDecl(Tree tree) :outertype: Block Adds use declaration. alreadyPresent ^^^^^^^^^^^^^^ .. java:method:: public boolean alreadyPresent(Instruction instr) :outertype: Block :return: true if instr is already in this Block and is not in an include. backFlow ^^^^^^^^ .. java:method:: public TapList backFlow() :outertype: Block :return: the list of all Flow Arrows arriving to this Block. For a LoopBlock, returns all FGArrows that leave some Block outside the LoopBlock to some Block inside the LoopBlock. buildTemporaryVariable ^^^^^^^^^^^^^^^^^^^^^^ .. java:method:: public Tree buildTemporaryVariable(String name, Tree expr, SymbolTable targetSymbolTable, ToObject toNSH, boolean reuse, TapList excludedReuse, boolean declare, FunctionTypeSpec functionTypeSpec, int argRank, Tree refForHint) :outertype: Block Returns a temporary variable usable to split expression "expr" from this Instruction. This variable should be named after the given "name" (possibly extended as usual if conflicts with some existing variable). It is meant to contain the result of "expr". This either reuses an existing temporary variable if available, or creates a new one and takes care of its declaration. :param name: The suggested name for the returned temporary variable. :param expr: The expression that should be precomputed and assigned to the temporary variable. :param targetSymbolTable: The SymbolTable where the future temporary variable will live. :param toNSH: When passed non-null, a container that will contain upon return the NewSymbolHolder of the temporary variable. :param reuse: If passed true, may return an already created temporary variable of same name and type. :param excludedReuse: when reuse==true, a list of NewSymbolHolder's that must not be reused here. :param declare: If passed false, assume the variable is not yet used and needs no declaration. In doubt, pass true. :param functionTypeSpec: In the case where "expr" is the actual argument or result of some procedure call, the type of this procedure. Else null. :param argRank: When "expr" is the actual argument or result of some procedure call, the rank of this argument (from 1 up) or 0 when result. Else -1. :param refForHint: When given non-null, some ref-expression whose dimensions are the same as "expr", that can be useful to get better hints about the values of ISIZEnOF... dimension sizes. :return: The ref-expression Tree of the temporary variable. checkUnusedDeclaration ^^^^^^^^^^^^^^^^^^^^^^ .. java:method:: public void checkUnusedDeclaration(Unit unit) :outertype: Block Remove instructions containing declaration of unused NewSymbolHolder. :param unit: current Unit. cite ^^^^ .. java:method:: public void cite() throws java.io.IOException :outertype: Block Prints a short reference to this Block onto TapEnv.curOutputStream(). :throws java.io.IOException: if an output error is detected. citeFlowShort ^^^^^^^^^^^^^ .. java:method:: protected String citeFlowShort() :outertype: Block coherence ^^^^^^^^^ .. java:method:: protected void coherence() :outertype: Block containsInstructionTree ^^^^^^^^^^^^^^^^^^^^^^^ .. java:method:: public boolean containsInstructionTree(Tree tree) :outertype: Block True if this Block already contains an Instruction with the given tree containsNoCode ^^^^^^^^^^^^^^ .. java:method:: public boolean containsNoCode() :outertype: Block Returns true if this block contains no meaningful code, and therefore can be skipped See for instance in FlowGraphDifferentiator.allExitsTurn() copyInstructions ^^^^^^^^^^^^^^^^ .. java:method:: public void copyInstructions(Block modelBlock, TapList> copiedIncludes) :outertype: Block Fills this Block with a copy of the modelBlock instructions. Instruction's are copied too. Tree's are copied. copyIntoWithoutArrows ^^^^^^^^^^^^^^^^^^^^^ .. java:method:: protected void copyIntoWithoutArrows(Block newBlock, TapList> alreadyCopiedMasks) :outertype: Block Places most elements of this Block into "newBlock". Copies instructions, labels, rank, and where masks Doesn't copy Flow Graph arrows. Uses "alreadyCopiedMasks" to make sure that copied whereMask's keep equal (==) tests. dump ^^^^ .. java:method:: public void dump(int indent) throws java.io.IOException :outertype: Block Prints in detail the contents of this Block, onto TapEnv.curOutputStream(). :param indent: the amount of indentation to be used for this printing. :throws java.io.IOException: if an output error is detected. dumpInstructions ^^^^^^^^^^^^^^^^ .. java:method:: protected final void dumpInstructions(int indent) throws java.io.IOException :outertype: Block Dumps instructions of this Block. :param indent: indentation. :throws java.io.IOException: if an output error is detected. enclosedIn ^^^^^^^^^^ .. java:method:: public boolean enclosedIn(LoopBlock loopBlock) :outertype: Block enclosingBlock ^^^^^^^^^^^^^^ .. java:method:: protected Block enclosingBlock() :outertype: Block Very temporarily during FlowGraph building, enclosing may be only a Block. enclosingLoop ^^^^^^^^^^^^^ .. java:method:: public LoopBlock enclosingLoop() :outertype: Block :return: the container Block in the hierarchy of nested loop Blocks. enclosingLoops ^^^^^^^^^^^^^^ .. java:method:: public TapList enclosingLoops() :outertype: Block :return: the list of all enclosing LoopBlock's, from the inside out. exchangeFlowArrowsTo ^^^^^^^^^^^^^^^^^^^^ .. java:method:: protected void exchangeFlowArrowsTo(Block dest1, Block dest2) :outertype: Block Exchanges the arrows that flow from current Block to Blocks "dest1" and "dest2". This only affects operations that sweep all destinations from a block, that would now encounter the two destinations in the other order. findRankToInsert ^^^^^^^^^^^^^^^^ .. java:method:: public int findRankToInsert(Tree fileTree, Tree tree) :outertype: Block :return: rank to insert the declaration Tree "tree" after the declarations in this fileTree BUT before the declarations that depends on this declaration. [llh] TODO: I'm not sure this code is right, e.g. dependsOn() test wrongly ordered? firstInstrAfterDecls ^^^^^^^^^^^^^^^^^^^^ .. java:method:: public Instruction firstInstrAfterDecls() :outertype: Block :return: the first instruction of this Block which is not a declaration. flow ^^^^ .. java:method:: public TapList flow() :outertype: Block :return: the list of all Flow Arrows leaving from this Block. For a LoopBlock, returns all FGArrows that leave some Block inside the LoopBlock to some Block outside the LoopBlock. flowsOutOfScope ^^^^^^^^^^^^^^^ .. java:method:: public boolean flowsOutOfScope(SymbolTable symbolTable) :outertype: Block :return: true when this block flows to a Block that cannot see scope SymbolTable flowsTo ^^^^^^^ .. java:method:: public boolean flowsTo(Block dest) :outertype: Block :return: true when there is a FGArrow from this Block to dest getAssGotoInfoDone ^^^^^^^^^^^^^^^^^^ .. java:method:: public TapList getAssGotoInfoDone() :outertype: Block Gets the list of AssGotoInfo's that have already been propagated through this Block. getControlStruct ^^^^^^^^^^^^^^^^ .. java:method:: public ControlStruct getControlStruct() :outertype: Block Gets this Block's Tree regeneration ControlStruct (using field "tmp1"). getDominatorArrows ^^^^^^^^^^^^^^^^^^ .. java:method:: public BoolVector getDominatorArrows() :outertype: Block Gets this Block's BoolVector of dominating FGArrow's (using field "tmp3"). getFGArrowTestCase ^^^^^^^^^^^^^^^^^^ .. java:method:: public FGArrow getFGArrowTestCase(int test, int oneCase) :outertype: Block :return: the FGArrow from this Block and with the given test and case. getFGArrowTo ^^^^^^^^^^^^ .. java:method:: public FGArrow getFGArrowTo(Block nextBlock) :outertype: Block :return: the FGArrow from this Block to the given "nextBlock". getFinalGotoRank ^^^^^^^^^^^^^^^^ .. java:method:: public int getFinalGotoRank() :outertype: Block Gets the rank of the variable in the computed GOTO that terminates this block (using field "tmp2"). Must be -1 if no GOTO. getLabelVariablesEffect ^^^^^^^^^^^^^^^^^^^^^^^ .. java:method:: public Block[] getLabelVariablesEffect() :outertype: Block :return: the effect of this Block with respect to AssGotoInfo's. getOperatorDeclarationInstruction ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ .. java:method:: public Instruction getOperatorDeclarationInstruction(SymbolDecl symbolDecl, int operator, SymbolTable symbolTable) :outertype: Block :param operator: == op_varDeclaration or op_typeDeclaration or op_interfaceDecl. :return: the varDeclaration or typeDeclaration or interfaceDecl Instruction that declares this symbolDecl in this Block. getPosition ^^^^^^^^^^^ .. java:method:: protected int getPosition() :outertype: Block :return: the position of this Block in its textual file. getStaticIterationIndices ^^^^^^^^^^^^^^^^^^^^^^^^^ .. java:method:: public TapList getStaticIterationIndices() :outertype: Block Same as Block.hasStaticIterationSpace(). For future use. :return: the TapList of all the loop indexes of the surrounding loops, which are all assumed of static length. getStaticIterationSpace ^^^^^^^^^^^^^^^^^^^^^^^ .. java:method:: public TapList getStaticIterationSpace() :outertype: Block Same as Block.hasStaticIterationSpace(). For future use. :return: the TapList of all the enclosing iteration lengths, which are all assumed static. hasCommentWith ^^^^^^^^^^^^^^ .. java:method:: public boolean hasCommentWith(String someText) :outertype: Block Returns true if this Block contains a comment with the given "someText" hasDeclarationCommentStartingWith ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ .. java:method:: public String hasDeclarationCommentStartingWith(String startString) :outertype: Block If this Block contains declarations and contains inside the declarations part a comment starting with startString, then returns the remaining of the comment. Otherwise returns null. hasStaticIterationSpace ^^^^^^^^^^^^^^^^^^^^^^^ .. java:method:: public boolean hasStaticIterationSpace() :outertype: Block For future use. :return: true if the control context of this block allows for a static saving of the tape, i.e. this block is either in the main stream, of inside a nest of loops that all have a static iteration space. headInstr ^^^^^^^^^ .. java:method:: public Instruction headInstr() :outertype: Block :return: the first instruction in this Block. insertBlockBefore ^^^^^^^^^^^^^^^^^ .. java:method:: public void insertBlockBefore(Block block) :outertype: Block Inserts the given "block" before this Block in the Flow Graph. This requires that the given "block" does not end with a test. isACleanDoLoop ^^^^^^^^^^^^^^ .. java:method:: public boolean isACleanDoLoop() :outertype: Block :return: true if this Block "isALoop" and is the HeaderBlock of a normal DO-loop, which has no dirty jumps in or out of the loop. isADoLoop ^^^^^^^^^ .. java:method:: public boolean isADoLoop() :outertype: Block :return: true if this block "isALoop" and is the Header of a DO-loop. isALoop ^^^^^^^ .. java:method:: public boolean isALoop() :outertype: Block :return: true if this Block has a unique instruction which is an op_loop, used to control other Blocks. In particular returns false if it is an op_loop that already contains a body, which means it is a closed instruction that is equivalent in this Flow Graph to an atomic, simple instruction. isANameSpace ^^^^^^^^^^^^ .. java:method:: public boolean isANameSpace() :outertype: Block :return: true if the block terminates with a nameSpace, which is a "true" analyzed nameSpace, meaning that its contents are in the next Block(s). isATimesLoop ^^^^^^^^^^^^ .. java:method:: public boolean isATimesLoop() :outertype: Block :return: true if this block "isALoop" and is the Header of a TIMES-loop. isAnIf ^^^^^^ .. java:method:: public boolean isAnIf() :outertype: Block :return: true if the block terminates with an if test, which is a real "if" that controls the next choice in the control flow. isControl ^^^^^^^^^ .. java:method:: public boolean isControl() :outertype: Block :return: true if this is a control block, i.e a block terminated by a control flow instruction. When this Block is a header, it is a control even if it has no LOOP:exit arrow. isDoWithIndexUnusedAfterLoop ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ .. java:method:: public boolean isDoWithIndexUnusedAfterLoop() :outertype: Block :return: true if this is a standard DO loop HeaderBlock, marked as loopIndexUnusedAfterLoop. Do not test on the "enclosing" field, as this method is called on differentiated Blocks, for which the "enclosing" field has not been conputed isOutsideFlow ^^^^^^^^^^^^^ .. java:method:: public boolean isOutsideFlow() :outertype: Block :return: true if this block that contains sub-units definitions is outside of the notion of control flow. isParallelController ^^^^^^^^^^^^^^^^^^^^ .. java:method:: public boolean isParallelController() :outertype: Block :return: true if this Block is the controller of a parallel region or loop e.g. $OMP PARALLEL. isVarDeclaredInBlock ^^^^^^^^^^^^^^^^^^^^ .. java:method:: public boolean isVarDeclaredInBlock(SymbolDecl symbolDecl) :outertype: Block lastInstr ^^^^^^^^^ .. java:method:: public Instruction lastInstr() :outertype: Block :return: the last instruction in this Block. lastTest ^^^^^^^^ .. java:method:: public int lastTest() :outertype: Block :return: the op_code of the tail test of this Block If the last instruction of this block is a test, returns its op_code, otherwise returns -1. listOfStatements ^^^^^^^^^^^^^^^^ .. java:method:: public TapList listOfStatements() :outertype: Block :return: an ordered list of all statements in this Block. mergeWithSuccessor ^^^^^^^^^^^^^^^^^^ .. java:method:: protected void mergeWithSuccessor(Block nextBlock) :outertype: Block Merges current Block with successor "nextBlock". The result is in the modified current Block. newDeclarationsBlock ^^^^^^^^^^^^^^^^^^^^ .. java:method:: protected void newDeclarationsBlock(Block modelBlock) :outertype: Block When necessary, makes this current Block the new declarationsBlock of its SymbolTable. When "modelBlock" was the declarationsBlock of its own symbolTable, and assuming that "this" new Block is in fact a copy of "modelBlock", then fills the "declarationsBlock" field of their symbolTable so that it points to "this" new block instead of to the old "modelBlock". origLabel ^^^^^^^^^ .. java:method:: public String origLabel() :outertype: Block :return: the label that may be attached to the first instruction of this Block. removeAndShunt ^^^^^^^^^^^^^^ .. java:method:: public void removeAndShunt() :outertype: Block Removes this Block from its containing Flow Graph, redirecting all arrows flowing to it towards its unique flow destination. This requires that this Block has only one exiting flow arrow. removeExternalInstr ^^^^^^^^^^^^^^^^^^^ .. java:method:: protected void removeExternalInstr(SymbolDecl symbolDecl) :outertype: Block Removes external symbolDecl's declaration-instruction from this Block. removeInstr ^^^^^^^^^^^ .. java:method:: public void removeInstr(Instruction instr) :outertype: Block Removes "instr" from this Block. replaceInFlowGraph ^^^^^^^^^^^^^^^^^^ .. java:method:: protected final void replaceInFlowGraph(Block oldBlock) :outertype: Block Replaces oldBlock with this Block and updates all arrows. :param oldBlock: Block to replace. seesAsShared ^^^^^^^^^^^^ .. java:method:: public boolean seesAsShared(String varName) :outertype: Block For future use. :param varName: setAssGotoInfoDone ^^^^^^^^^^^^^^^^^^ .. java:method:: public void setAssGotoInfoDone(TapList assGotoInfoDone) :outertype: Block Sets the list of AssGotoInfo's that have already been propagated through this Block. setBackFlow ^^^^^^^^^^^ .. java:method:: protected final void setBackFlow(TapList backFlow) :outertype: Block Set the list of all Flow Arrows arriving to this Block. :param backFlow: TapList of FGArrow. setControlStruct ^^^^^^^^^^^^^^^^ .. java:method:: public void setControlStruct(ControlStruct controlStruct) :outertype: Block Sets this Block's Tree regeneration ControlStruct (using field "tmp1"). setDominatorArrows ^^^^^^^^^^^^^^^^^^ .. java:method:: protected void setDominatorArrows(BoolVector dominators) :outertype: Block Sets this Block's BoolVector of dominating FGArrow's (using field "tmp3"). setEnclosingBlock ^^^^^^^^^^^^^^^^^ .. java:method:: protected void setEnclosingBlock(Block enclosingBlock) :outertype: Block Very temporarily during FlowGraph building, enclosing may be only a Block. setEnclosingBlockProtected ^^^^^^^^^^^^^^^^^^^^^^^^^^ .. java:method:: protected void setEnclosingBlockProtected(Block enclosingBlock) :outertype: Block Sets "enclosingBlock" as the header of the loop directly enclosing this Block. "enclosingBlock" may be a HeaderBlock or a BasicBlock. Protection: this setting is not done if the Block already has an enclosing loop and the new enclosing is not contained in the old enclosing. setEnclosingLoop ^^^^^^^^^^^^^^^^ .. java:method:: public void setEnclosingLoop(LoopBlock enclosingLoop) :outertype: Block Sets the container Block in the hierarchy of nested loop Blocks. setFinalGotoRank ^^^^^^^^^^^^^^^^ .. java:method:: public void setFinalGotoRank(int rank) :outertype: Block Sets the rank of the variable in the computed GOTO that terminates this block (using field "tmp2"). Must be -1 if no GOTO. setFlow ^^^^^^^ .. java:method:: protected final void setFlow(TapList flow) :outertype: Block Set the list of all Flow Arrows leaving from this Block. :param flow: TapList of FGArrow. setLabelVariablesEffect ^^^^^^^^^^^^^^^^^^^^^^^ .. java:method:: public void setLabelVariablesEffect(Block[] effectAssGoto) :outertype: Block Sets the effect of this Block with respect to AssGotoInfo's. setOrigLabel ^^^^^^^^^^^^ .. java:method:: public void setOrigLabel(String label) :outertype: Block Set the label attached to the first instruction of this Block. skipEmpty ^^^^^^^^^ .. java:method:: protected void skipEmpty() :outertype: Block Removes current Block, because we assume it is empty. All flow arrows jump over it. sortDeclarationsAndOperations ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ .. java:method:: public void sortDeclarationsAndOperations() :outertype: Block splitInstructions ^^^^^^^^^^^^^^^^^ .. java:method:: protected void splitInstructions(TapList beforeEntry, TapList beforeCycle) :outertype: Block Split instructions of this Block, e.g. to isolate subroutine and function calls. symbolDeclDeclared ^^^^^^^^^^^^^^^^^^ .. java:method:: public TapList symbolDeclDeclared(Instruction instruction) :outertype: Block :return: the list of all SymbolDecl's defined in Instruction. symbolDeclDeclared ^^^^^^^^^^^^^^^^^^ .. java:method:: public TapList symbolDeclDeclared(Tree tree, SymbolTable inSymbolTable) :outertype: Block :return: the list of all SymbolDecl's defined in Tree. toString ^^^^^^^^ .. java:method:: @Override public String toString() :outertype: Block typeCheck ^^^^^^^^^ .. java:method:: protected void typeCheck(SymbolTable definitionSymbolTable) :outertype: Block TypeChecks this Block. :param definitionSymbolTable: SymbolTable used to typecheck this Block. unit ^^^^ .. java:method:: public Unit unit() :outertype: Block :return: the enclosingOrigUnit of this Block. May return null if Flow Graph is not finished building.