public interface RegisterConfig
Modifier and Type | Method and Description |
---|---|
boolean |
areAllAllocatableRegistersCallerSaved()
Determines if all
allocatable registers are
caller saved . |
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. |
default int |
getMaximumFrameSize()
Gets the maximum allowed size of the frame.
|
Register |
getRegisterForRole(int id)
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.
|
Register getReturnRegister(Kind kind)
default int getMaximumFrameSize()
Register getFrameRegister()
Register.Frame
and Register.CallerFrame
are bound.CallingConvention getCallingConvention(CallingConvention.Type type, JavaType returnType, JavaType[] parameterTypes, TargetDescription target, boolean stackOnly)
type
- 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 registersRegister[] getCallingConventionRegisters(CallingConvention.Type type, Kind kind)
type
- the type of calling conventionkind
- specifies what kind of registers is being requestedtype
Register[] getAllocatableRegisters()
RegisterAllocationConfig#getAllocatableRegisters()
Register[] filterAllocatableRegisters(PlatformKind kind, Register[] registers)
Register[] getCallerSaveRegisters()
CalleeSaveLayout getCalleeSaveLayout()
null
if there is no callee save areaRegisterAttributes[] getAttributesMap()
Register getRegisterForRole(int id)
id
- the identifier of a runtime-defined register roleid
boolean areAllAllocatableRegistersCallerSaved()
allocatable
registers are
caller saved
.