|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | ENUM CONSTANTS | FIELD | METHOD | DETAIL: ENUM CONSTANTS | FIELD | METHOD |
java.lang.Object java.lang.Enum<KangaReg> kanga.meta.KangaReg
public enum KangaReg
This enum class represents a Reg object (immutable) that can be used in the creation of Kanga syntaxtree node.
Enum Constant Summary | |
---|---|
A0
the a0 register |
|
A1
the a1 register |
|
A2
the a2 register |
|
A3
the a3 register |
|
S0
the s0 register |
|
S1
the s1 register |
|
S2
the s2 register |
|
S3
the s3 register |
|
S4
the s4 register |
|
S5
the s5 register |
|
S6
the s6 register |
|
S7
the s7 register |
|
T0
the t0 register |
|
T1
the t1 register |
|
T2
the t2 register |
|
T3
the t3 register |
|
T4
the t4 register |
|
T5
the t5 register |
|
T6
the t6 register |
|
T7
the t7 register |
|
T8
the t8 register |
|
T9
the t9 register |
|
V0
the v0 register |
|
V1
the v1 register |
Field Summary | |
---|---|
static KangaReg[] |
ARGUMENTS
The designated registers to store arguments to procedure calls. |
static java.util.Set<KangaReg> |
CALLEE_SAVED
Defines the set of registers that, by convention, are "callee-saved." These include all of the s registers. |
static java.util.Set<KangaReg> |
CALLER_SAVED
Defines the set of registers that, by convention, are "caller-saved." These include all of the t registers and a registers . |
static KangaReg |
SCRATCH_0
The designated "scratch" register. |
static KangaReg |
SCRATCH_1
The designated "scratch" register. |
Method Summary | |
---|---|
static Reg |
createRegNode(KangaReg reg)
Creates and return a Kanga syntaxtree node that represents a Reg. |
java.lang.String |
getName()
Returns the register name. |
boolean |
isCalleeSaved()
Returns true if this register is a callee-saved register. |
boolean |
isCallerSaved()
Returns true if this register is a caller-saved register. |
static KangaReg |
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. |
static KangaReg[] |
values()
Returns an array containing the constants of this enum type, in the order they're declared. |
Methods inherited from class java.lang.Enum |
---|
clone, compareTo, equals, getDeclaringClass, hashCode, name, ordinal, toString, valueOf |
Methods inherited from class java.lang.Object |
---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
Enum Constant Detail |
---|
public static final KangaReg A0
a0
register
public static final KangaReg A1
a1
register
public static final KangaReg A2
a2
register
public static final KangaReg A3
a3
register
public static final KangaReg T0
t0
register
public static final KangaReg T1
t1
register
public static final KangaReg T2
t2
register
public static final KangaReg T3
t3
register
public static final KangaReg T4
t4
register
public static final KangaReg T5
t5
register
public static final KangaReg T6
t6
register
public static final KangaReg T7
t7
register
public static final KangaReg S0
s0
register
public static final KangaReg S1
s1
register
public static final KangaReg S2
s2
register
public static final KangaReg S3
s3
register
public static final KangaReg S4
s4
register
public static final KangaReg S5
s5
register
public static final KangaReg S6
s6
register
public static final KangaReg S7
s7
register
public static final KangaReg T8
t8
register
public static final KangaReg T9
t9
register
public static final KangaReg V0
v0
register
public static final KangaReg V1
v1
register
Field Detail |
---|
public static final KangaReg SCRATCH_0
v0
register).
public static final KangaReg SCRATCH_1
v1
register).
public static final KangaReg[] ARGUMENTS
a
registers).
public static final java.util.Set<KangaReg> CALLER_SAVED
t
registers and a registers
.
public static final java.util.Set<KangaReg> CALLEE_SAVED
s
registers.
Method Detail |
---|
public static final KangaReg[] values()
for(KangaReg c : KangaReg.values()) System.out.println(c);
public static KangaReg valueOf(java.lang.String name)
name
- the name of the enum constant to be returned.
java.lang.IllegalArgumentException
- if this enum type has no constant
with the specified namepublic java.lang.String getName()
public boolean isCallerSaved()
true
if this register is a caller-saved register.
true
if this register is a caller-saved registerpublic boolean isCalleeSaved()
true
if this register is a callee-saved register.
true
if this register is a callee-saved registerpublic static Reg createRegNode(KangaReg reg)
reg
- the Reg object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | ENUM CONSTANTS | FIELD | METHOD | DETAIL: ENUM CONSTANTS | FIELD | METHOD |