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 TypeMethodDescriptionvoid
boolean
void
int
compareTo
(BasicBlock other) On an exception occurring in this block which BB should we go to?int
getID()
getLabel()
int
hashCode()
void
insertInstr
(int index, Instr i) void
insertInstr
(Instr i) boolean
isEmpty()
boolean
boolean
isExitBB()
boolean
void
boolean
removeInstr
(Instr i) void
replaceInstrs
(List<Instr> instrs) siteOf
(long callsiteId) What site object contains this callsiteId or die trying.splitAtInstruction
(Site splitPoint, Label newLabel, boolean includeSplitPointInstr) void
swallowBB
(BasicBlock foodBB) toString()
-
Constructor Details
-
BasicBlock
-
-
Method Details
-
getID
public int getID()- Specified by:
getID
in 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:
compareTo
in interfaceComparable<BasicBlock>
-
toString
-
toStringInstrs
-