Package org.jruby.ir.representations
Class BasicBlock
java.lang.Object
org.jruby.ir.representations.BasicBlock
- All Implemented Interfaces:
Comparable<BasicBlock>,org.jruby.dirgra.ExplicitVertexID
public class BasicBlock
extends Object
implements org.jruby.dirgra.ExplicitVertexID, Comparable<BasicBlock>
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidbooleanvoidintcompareTo(BasicBlock other) On an exception occurring in this block which BB should we go to?intgetID()getLabel()inthashCode()voidinsertInstr(int index, Instr i) voidinsertInstr(Instr i) booleanisEmpty()booleanbooleanisExitBB()booleanvoidbooleanremoveInstr(Instr i) voidreplaceInstrs(List<Instr> instrs) siteOf(long callsiteId) What site object contains this callsiteId or die trying.splitAtInstruction(Site splitPoint, Label newLabel, boolean includeSplitPointInstr) voidswallowBB(BasicBlock foodBB) toString()
-
Constructor Details
-
BasicBlock
-
-
Method Details
-
getID
public int getID()- Specified by:
getIDin interfaceorg.jruby.dirgra.ExplicitVertexID
-
getLabel
-
hashCode
public int hashCode() -
canRaiseExceptions
public boolean canRaiseExceptions() -
exceptionBB
On an exception occurring in this block which BB should we go to?- Returns:
- BB of exception handling or null if none.
-
isEntryBB
public boolean isEntryBB() -
isExitBB
public boolean isExitBB() -
markRescueEntryBB
public void markRescueEntryBB() -
isRescueEntry
public boolean isRescueEntry() -
replaceInstrs
-
addInstr
-
insertInstr
-
insertInstr
-
getInstrs
-
getLastInstr
-
removeInstr
-
isEmpty
public boolean isEmpty() -
siteOf
What site object contains this callsiteId or die trying.- Parameters:
callsiteId- to be found- Returns:
- the Site instance (CallBase or YieldInstr)
-
splitAtInstruction
public BasicBlock splitAtInstruction(Site splitPoint, Label newLabel, boolean includeSplitPointInstr) -
swallowBB
-
clone
-
cloneInstrs
-
cloneForInlining
-
compareTo
- Specified by:
compareToin interfaceComparable<BasicBlock>
-
toString
-
toStringInstrs
-