public class SPARCHotSpotRegisterConfig extends Object implements RegisterConfig
| Modifier and Type | Field and Description |
|---|---|
private Register[] |
allocatable |
private Architecture |
architecture |
private RegisterAttributes[] |
attributesMap |
private Register[] |
calleeSaveRegisters
Registers saved by the callee.
|
private Register[] |
callerSaveRegisters |
private Register[] |
cpuCalleeParameterRegisters |
private Register[] |
cpuCallerParameterRegisters |
private CalleeSaveLayout |
csl |
private Register[] |
fpuDoubleParameterRegisters |
private Register[] |
fpuParameterRegisters |
| Constructor and Description |
|---|
SPARCHotSpotRegisterConfig(TargetDescription target,
HotSpotVMConfig config) |
SPARCHotSpotRegisterConfig(TargetDescription target,
Register[] allocatable) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
areAllAllocatableRegistersCallerSaved()
Determines if all
allocatable registers are
caller saved. |
private CallingConvention |
callingConvention(Register[] generalParameterRegisters,
JavaType returnType,
JavaType[] parameterTypes,
CallingConvention.Type type,
TargetDescription target,
boolean stackOnly) |
Register[] |
filterAllocatableRegisters(PlatformKind kind,
Register[] registers)
Filters a set of registers and returns only those that can be used by the register allocator
for a value of a particular kind.
|
Register[] |
getAllocatableRegisters()
Gets the set of all registers that might be used by the register allocator.
|
RegisterAttributes[] |
getAttributesMap()
Gets a map from register numbers to register
attributes for this register configuration.
|
CalleeSaveLayout |
getCalleeSaveLayout()
Gets the layout of the callee save area of this register configuration.
|
Register[] |
getCallerSaveRegisters()
Gets the registers whose values must be preserved by a method across any call it makes.
|
CallingConvention |
getCallingConvention(CallingConvention.Type type,
JavaType returnType,
JavaType[] parameterTypes,
TargetDescription target,
boolean stackOnly)
Gets the calling convention describing how arguments are passed.
|
Register[] |
getCallingConventionRegisters(CallingConvention.Type type,
Kind kind)
Gets the ordered set of registers that are can be used to pass parameters according to a
given calling convention.
|
Register |
getFrameRegister()
Gets the register to which
Register.Frame and Register.CallerFrame are bound. |
Register |
getRegisterForRole(int index)
Gets the register corresponding to a runtime-defined role.
|
Register |
getReturnRegister(Kind kind)
Gets the register to be used for returning a value of a given kind.
|
private static Register |
getReturnRegister(Kind kind,
CallingConvention.Type type) |
private static Register[] |
initAllocatable(boolean reserveForHeapBase) |
private static int |
roundUp(int number,
int mod) |
String |
toString() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitgetMaximumFrameSizeprivate final Architecture architecture
private final Register[] allocatable
private final RegisterAttributes[] attributesMap
private final Register[] cpuCallerParameterRegisters
private final Register[] cpuCalleeParameterRegisters
private final Register[] fpuParameterRegisters
private final Register[] fpuDoubleParameterRegisters
private final Register[] callerSaveRegisters
private final Register[] calleeSaveRegisters
private final CalleeSaveLayout csl
public SPARCHotSpotRegisterConfig(TargetDescription target, HotSpotVMConfig config)
public SPARCHotSpotRegisterConfig(TargetDescription target, Register[] allocatable)
public Register[] getAllocatableRegisters()
RegisterConfigRegisterAllocationConfig#getAllocatableRegisters()getAllocatableRegisters in interface RegisterConfigpublic Register[] filterAllocatableRegisters(PlatformKind kind, Register[] registers)
RegisterConfigfilterAllocatableRegisters in interface RegisterConfigpublic RegisterAttributes[] getAttributesMap()
RegisterConfiggetAttributesMap in interface RegisterConfigprivate static Register[] initAllocatable(boolean reserveForHeapBase)
public Register[] getCallerSaveRegisters()
RegisterConfiggetCallerSaveRegisters in interface RegisterConfigpublic boolean areAllAllocatableRegistersCallerSaved()
RegisterConfigallocatable registers are
caller saved.areAllAllocatableRegistersCallerSaved in interface RegisterConfigpublic Register getRegisterForRole(int index)
RegisterConfiggetRegisterForRole in interface RegisterConfigindex - the identifier of a runtime-defined register roleidpublic CallingConvention getCallingConvention(CallingConvention.Type type, JavaType returnType, JavaType[] parameterTypes, TargetDescription target, boolean stackOnly)
RegisterConfiggetCallingConvention in interface RegisterConfigtype - the type of calling convention being requestedreturnType - the return type (can be null for methods returning void)parameterTypes - the types of the arguments of the calltarget - the target platformstackOnly - ignore registerspublic Register[] getCallingConventionRegisters(CallingConvention.Type type, Kind kind)
RegisterConfiggetCallingConventionRegisters in interface RegisterConfigtype - the type of calling conventionkind - specifies what kind of registers is being requestedtypeprivate CallingConvention callingConvention(Register[] generalParameterRegisters, JavaType returnType, JavaType[] parameterTypes, CallingConvention.Type type, TargetDescription target, boolean stackOnly)
private static int roundUp(int number, int mod)
public Register getReturnRegister(Kind kind)
RegisterConfiggetReturnRegister in interface RegisterConfigprivate static Register getReturnRegister(Kind kind, CallingConvention.Type type)
public Register getFrameRegister()
RegisterConfigRegister.Frame and Register.CallerFrame are bound.getFrameRegister in interface RegisterConfigpublic CalleeSaveLayout getCalleeSaveLayout()
RegisterConfiggetCalleeSaveLayout in interface RegisterConfignull if there is no callee save area