cfg
Class InDirCallInst
java.lang.Object
cfg.TACInst
cfg.CallInst
cfg.InDirCallInst
public class InDirCallInst
- extends CallInst
A class representing a three-address code indirect call instruction
(InDirCallInst).
An indirect call instruction consists of a target variable holding the
address to
jump to (inherited from CallInst), an optional destination variable to assign
the
result of the call to (inherited from CallInst), and the number of parameters
(ref. and standard) used by the call (inherited from CallInst). From TACInst
it
also inherits an opcode (INDIRCALL).
- Author:
- Marc Corliss and Lori Pietraszek
Fields inherited from class cfg.TACInst |
BINADD, BINAND, BINDIV, BINMOD, BINMUL, BINOR, BINSUB, comments, DIRCALL, ERRPARAM, IF, INDIRCALL, LDADDR, LDCONST, LDENTRY, LDVAR, NUM_INSN_TYPES, opcode, PHI, REFPARAM, RETN, STDPARAM, STENTRY, UNNEG, UNNOT |
Constructor Summary |
InDirCallInst(java.lang.String targVar,
java.lang.String destVar,
int numParams)
InDirCallInst constructor |
Method Summary |
<ReturnType,ArgumentType>
ReturnType |
|
accept(TACInstVisitor<ReturnType,ArgumentType> visitor,
ArgumentType o)
Abstract visitor method. |
void |
setTarget(java.lang.String target)
Set the target of the call |
Methods inherited from class cfg.TACInst |
addComment, checkBoolConst, checkConst, checkIntConst, checkLabel, checkStrConst, checkVar, getBinaryOpcode, getComments, getOp, getOpcode, getUnaryOpcode, isBinary, isCall, isIf, isLoad, isParam, isReturn, isStore, isUnary, isValidID, removeComments, toString |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
InDirCallInst
public InDirCallInst(java.lang.String targVar,
java.lang.String destVar,
int numParams)
- InDirCallInst constructor
- Parameters:
targVar
- target variable holding address to jump todestVar
- (Optional) destination variable to assign result of call
(null if none)numParams
- number of parameters (both ref. and standard but not
error)
setTarget
public void setTarget(java.lang.String target)
- Set the target of the call
- Specified by:
setTarget
in class CallInst
- Parameters:
target
- new target
accept
public <ReturnType,ArgumentType> ReturnType accept(TACInstVisitor<ReturnType,ArgumentType> visitor,
ArgumentType o)
- Description copied from class:
TACInst
- Abstract visitor method.
- Specified by:
accept
in class TACInst
- Parameters:
visitor
- TACInstVisitor.o
- Data to pass down.
- Returns:
- return value of visitor.