|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object scale.backend.RegisterSet scale.backend.x86.X86RegisterSet
public class X86RegisterSet
This class describes the register set of the X86 architecture.
$Id: X86RegisterSet.java,v 1.1 2007-11-01 16:52:30 burrill Exp $
Copyright 2007 by the
Scale Compiler Group,
Department of Computer Science
University of Massachusetts,
Amherst MA. 01003, USA
All Rights Reserved.
This class represents the register set for the specific architecture. Most of the methods below generate a "not implemented error". These must be replaced with code that is specific to the register set of the architecture. The other methods may need to be modified. Use the register set classes from the other architectures to help you understand how to make changes for your architecture.
RegisterSet
,
AlphaRegisterSet
,
SparcRegisterSet
,
PPCRegisterSet
Field Summary | |
---|---|
static int |
AH
|
static int |
AL
|
static int |
AX
|
static int |
BH
|
static int |
BL
|
static int |
BP
|
static int |
BX
|
static int |
CH
|
static int |
CL
|
static int |
CR0
|
static int |
CR1
|
static int |
CR2
|
static int |
CR3
|
static int |
CS
|
static int |
CX
|
static int |
DH
|
static int |
DI
|
static int |
DL
|
static int |
DR0
|
static int |
DR1
|
static int |
DR2
|
static int |
DR3
|
static int |
DR4
|
static int |
DR5
|
static int |
DR6
|
static int |
DR7
|
static int |
DS
|
static int |
DX
|
static int |
EAX
|
static int |
EBP
|
static int |
EBX
|
static int |
ECX
|
static int |
EDI
|
static int |
EDX
|
static int |
EFLAGS
|
static int |
ES
|
static int |
ESI
|
static int |
ESP
|
static int |
FS
|
static int |
GS
|
static int |
SI
|
static int |
SP
|
static int |
SS
|
Fields inherited from class scale.backend.RegisterSet |
---|
ADRREG, AFIREG, AIREG, checkMask, CNTREG, DBLEREG, FIREG, FLTREG, INTREG, nextRegister, PAIRREG, QUADREG, RDREG, registers, sizeMask, SPCREG, typeMask |
Constructor Summary | |
---|---|
X86RegisterSet()
|
Method Summary | |
---|---|
int |
actualRegister(int reg)
For architecture where a pseudo register are mapped onto actual registers, return the actual register. |
short[] |
getCalleeSaves()
Return the callee saves registers. |
short[] |
getCalleeUses()
Return the callee uses registers. |
short[] |
getPreferredOrder()
Return a mapping from an order index to a real register number. |
int |
numAllocatableRegisters()
Return the number of unique registers that can hold programmer values. |
java.lang.String |
registerName(int reg)
Convert a register number into its assembly language form. |
int |
registerSize(int reg)
Return the size of the register in addressable memory units. |
int |
tempRegisterType(Type type,
long bs)
Return the register type with the size information added. |
boolean |
useContiguous()
Return true if virtual registers, that require more than one real register, must be allocated to contiguous real registers. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int EAX
public static final int AX
public static final int AH
public static final int AL
public static final int EBX
public static final int BX
public static final int BH
public static final int BL
public static final int ECX
public static final int CX
public static final int CH
public static final int CL
public static final int EDX
public static final int DX
public static final int DH
public static final int DL
public static final int EBP
public static final int BP
public static final int ESI
public static final int SI
public static final int EDI
public static final int DI
public static final int ESP
public static final int SP
public static final int CS
public static final int DS
public static final int SS
public static final int ES
public static final int FS
public static final int GS
public static final int CR0
public static final int CR1
public static final int CR2
public static final int CR3
public static final int DR0
public static final int DR1
public static final int DR2
public static final int DR3
public static final int DR4
public static final int DR5
public static final int DR6
public static final int DR7
public static final int EFLAGS
Constructor Detail |
---|
public X86RegisterSet()
Method Detail |
---|
public java.lang.String registerName(int reg)
RegisterSet
registerName
in class RegisterSet
public short[] getPreferredOrder()
RegisterSet
getPreferredOrder
in class RegisterSet
public boolean useContiguous()
RegisterSet
useContiguous
in class RegisterSet
public int registerSize(int reg)
RegisterSet
registerSize
in class RegisterSet
public int actualRegister(int reg)
RegisterSet
SparcV8RegisterSet
where a 64-bit long long
register
is mapped onto a set of two 32-bit registers.
actualRegister
in class RegisterSet
public short[] getCalleeSaves()
RegisterSet
getCalleeSaves
in class RegisterSet
public short[] getCalleeUses()
RegisterSet
getCalleeUses
in class RegisterSet
public int numAllocatableRegisters()
RegisterSet
numAllocatableRegisters
in class RegisterSet
public int tempRegisterType(Type type, long bs)
RegisterSet
tempRegisterType
in class RegisterSet
type
- is the type requiredbs
- is the size required
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |