public class VariableElement extends Object
Modifier and Type | Field and Description |
---|---|
private boolean |
kind
the kind of this element : LOCAL or STACK
|
private char |
num
the number of element, e.g., with kind we
can know it is L0 or S1.
|
private Object |
ref
for reference type value
|
private byte |
tcode
type code, can only be INT, FLOAT, LONG, DOUBLE, RET_ADDR, WORD or REF
|
private long |
value
The value of this element.
|
Constructor and Description |
---|
VariableElement(boolean what_kind,
int which_num,
byte type,
int ibits)
Constructor for 32-bit value.
|
VariableElement(boolean what_kind,
int which_num,
byte type,
long lbits)
Constructor for 64-bit value.
|
VariableElement(boolean what_kind,
int which_num,
byte type,
Object ref)
Constructor for reference type.
|
VariableElement(boolean what_kind,
int which_num,
byte type,
Word word)
Constructor for word type.
|
Modifier and Type | Method and Description |
---|---|
(package private) int |
getIntBits() |
(package private) long |
getLongBits() |
(package private) char |
getNumber() |
(package private) Object |
getObject() |
(package private) byte |
getTypeCode() |
(package private) Word |
getWord() |
(package private) static boolean |
isIBitsType(int tcode) |
(package private) static boolean |
isLBitsType(int tcode) |
(package private) boolean |
isLocal() |
(package private) boolean |
isRefType() |
(package private) static boolean |
isRefType(int tcode) |
(package private) boolean |
isWordType() |
(package private) static boolean |
isWordType(int tcode) |
String |
toString() |
private final boolean kind
private final char num
private final byte tcode
private final long value
public VariableElement(boolean what_kind, int which_num, byte type, int ibits)
what_kind
- OSRConstants.LOCAL
or OSRConstants.STACK
which_num
- the variable's numbertype
- the variable's type codeibits
- the variable's valuepublic VariableElement(boolean what_kind, int which_num, byte type, long lbits)
what_kind
- OSRConstants.LOCAL
or OSRConstants.STACK
which_num
- the variable's numbertype
- the variable's type codelbits
- the variable's valuepublic VariableElement(boolean what_kind, int which_num, byte type, Object ref)
what_kind
- OSRConstants.LOCAL
or OSRConstants.STACK
which_num
- the variable's numbertype
- the variable's type coderef
- the referencepublic VariableElement(boolean what_kind, int which_num, byte type, Word word)
what_kind
- OSRConstants.LOCAL
or OSRConstants.STACK
which_num
- the variable's numbertype
- the variable's type codeword
- the wordstatic boolean isIBitsType(int tcode)
static boolean isLBitsType(int tcode)
static boolean isRefType(int tcode)
static boolean isWordType(int tcode)
boolean isLocal()
byte getTypeCode()
char getNumber()
boolean isRefType()
boolean isWordType()
int getIntBits()
long getLongBits()