org.jikesrvm.compilers.opt.ir.operand
Class AddressConstantOperand

java.lang.Object
  extended by org.jikesrvm.compilers.opt.ir.operand.Operand
      extended by org.jikesrvm.compilers.opt.ir.operand.ConstantOperand
          extended by org.jikesrvm.compilers.opt.ir.operand.AddressConstantOperand

public final class AddressConstantOperand
extends ConstantOperand

Represents an address constant operand.

See Also:
Operand

Field Summary
 Address value
          Value of this operand.
 
Fields inherited from class org.jikesrvm.compilers.opt.ir.operand.Operand
instruction
 
Constructor Summary
AddressConstantOperand(Address v)
          Constructs a new address constant operand with the specified value.
AddressConstantOperand(Extent v)
          Constructs a new address constant operand with the specified offset value.
AddressConstantOperand(Offset v)
          Constructs a new address constant operand with the specified offset value.
AddressConstantOperand(Word v)
          Constructs a new address constant operand with the specified offset value.
 
Method Summary
 Operand copy()
          Return a new operand that is semantically equivalent to this.
 boolean equals(Object o)
           
 TypeReference getType()
          Return the TypeReference of the value represented by the operand.
 int hashCode()
           
 boolean isAddress()
          Does the operand represent a value of the address data type?
 boolean similar(Operand op)
          Are two operands semantically equivalent?
 String toString()
          Returns the string representation of this operand.
 
Methods inherited from class org.jikesrvm.compilers.opt.ir.operand.Operand
asAddressConstant, asBlock, asBranch, asClassConstant, asCondition, asDoubleConstant, asFloatConstant, asIntConstant, asLocation, asLongConstant, asMemory, asMethod, asNullConstant, asObjectConstant, asRegister, asStackLocation, asStringConstant, asTIBConstant, asType, conservativelyApproximates, getIndexInInstruction, isAddressConstant, isBlock, isBranch, isClassConstant, isConstant, isDefinitelyNull, isDouble, isDoubleConstant, isFloat, isFloatConstant, isInt, isIntConstant, isIntLike, isLocation, isLong, isLongConstant, isMemory, isMethod, isMovableObjectConstant, isNullConstant, isObjectConstant, isRef, isRegister, isStackLocation, isStringConstant, isTIBConstant, isTrueGuard, isType, meet
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

value

public final Address value
Value of this operand.

Constructor Detail

AddressConstantOperand

public AddressConstantOperand(Address v)
Constructs a new address constant operand with the specified value.

Parameters:
v - value

AddressConstantOperand

public AddressConstantOperand(Offset v)
Constructs a new address constant operand with the specified offset value.

Parameters:
v - value TODO: make a separte OffsetConstantOperand

AddressConstantOperand

public AddressConstantOperand(Extent v)
Constructs a new address constant operand with the specified offset value.

Parameters:
v - value TODO: make a separate OffsetConstantOperand

AddressConstantOperand

public AddressConstantOperand(Word v)
Constructs a new address constant operand with the specified offset value.

Parameters:
v - value TODO: make a separate OffsetConstantOperand
Method Detail

copy

public Operand copy()
Description copied from class: Operand
Return a new operand that is semantically equivalent to this.

Specified by:
copy in class Operand
Returns:
a copy of this

getType

public TypeReference getType()
Description copied from class: Operand
Return the TypeReference of the value represented by the operand.

Overrides:
getType in class Operand
Returns:
TypeReference.Address

isAddress

public boolean isAddress()
Description copied from class: Operand
Does the operand represent a value of the address data type?

Overrides:
isAddress in class Operand
Returns:
true

similar

public boolean similar(Operand op)
Description copied from class: Operand
Are two operands semantically equivalent?

Specified by:
similar in class Operand
Parameters:
op - other operand
Returns:
true if this and op are semantically equivalent or false if they are not.

equals

public boolean equals(Object o)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object

toString

public String toString()
Returns the string representation of this operand.

Overrides:
toString in class Object
Returns:
a string representation of this operand.