RegisterSpec instances.
| Modifier and Type | Field and Description |
|---|---|
| public static final RegisterSpecList | EMPTY
|
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public RegisterSpec | Returns: non-null; the indicated element>= 0, < size(); which elementGets the indicated element. |
| public int | Returns: >= 0; the required registers sizeGets the minimum required register count implied by this instance. |
| public Type | getType(int
>= 0, < size(); which elementImplements org. |
| public int | getWordCount()
Implements org. |
| public int | Returns: index of RegisterSpec or -1Register to find reg)Returns the index of a RegisterSpec in this list that uses the specified register, or -1 if none in this list uses the register. |
| public static RegisterSpecList | Returns: non-null; an appropriately-constructed instancenon-null; the elementMakes a single-element instance. |
| public static RegisterSpecList | Returns: non-null; an appropriately-constructed instancenon-null; the first elementnon-null; the second elementMakes a two-element instance. |
| public static RegisterSpecList | Returns: non-null; an appropriately-constructed instancenon-null; the first elementnon-null; the second elementnon-null; the third elementMakes a three-element instance. |
| public static RegisterSpecList | Returns: non-null; an appropriately-constructed instancenon-null; the first elementnon-null; the second elementnon-null; the third elementnon-null; the fourth elementMakes a four-element instance. |
| public void | set(int
>= 0, < size(); which elementnon-null; the value to storeSets the element at the given index. |
| public RegisterSpec | Returns: RegisterSpec that uses argument or null.Register to find reg)Returns a RegisterSpec in this list that uses the specified register, or null if there is none in this list. |
| public RegisterSpecList | |
| public TypeList | withAddedType(Type
non-null; item to appendImplements org. |
| public RegisterSpecList | Returns: non-null; an appropriately-constructed instancethe base register number base, boolean whether to duplicate the first number duplicateFirst, BitSet null-ok; either a non-null set of
compatible registers, or null to indicate all registers are
compatibleReturns an instance that is identical to this one, except that all incompatible register numbers are renumbered sequentially from the given base, with the first number duplicated if indicated. |
| public RegisterSpecList | Returns: non-null; an appropriately-constructed instancenon-null; the new first spec (to prepend)Returns a new instance, which is the same as this instance, except that it has an additional element prepended to the original. |
| public RegisterSpecList | Returns: non-null; an appropriately-constructed instancethe amount to offset the register numbers by delta)Returns an instance that is identical to this one, except that all register numbers are offset by the given amount. |
| public RegisterSpecList | Returns: non-null; an appropriately-constructed instanceReturns a new instance, which is the same as this instance, except that its first element is removed. |
| public RegisterSpecList | Returns: non-null; an appropriately-constructed instanceReturns a new instance, which is the same as this instance, except that its last element is removed. |
| EMPTY | back to summary |
|---|---|
| public static final RegisterSpecList EMPTY
| |
| RegisterSpecList | back to summary |
|---|---|
| public RegisterSpecList(int size) Constructs an instance. All indices initially contain
| |
| get | back to summary |
|---|---|
| public RegisterSpec get(int n) Gets the indicated element. It is an error to call this with the
index for an element which was never set; if you do that, this
will throw
| |
| getRegistersSize | back to summary |
|---|---|
| public int getRegistersSize() Gets the minimum required register count implied by this instance. This is equal to the highest register number referred to plus the widest width (largest category) of the type used in that register.
| |
| getType | back to summary |
|---|---|
| public Type getType(int n) Implements org. Doc from org. Gets the indicated element. It is an error to call this with the
index for an element which was never set; if you do that, this
will throw
| |
| getWordCount | back to summary |
|---|---|
| public int getWordCount() Implements org. Doc from org. Gets the number of 32-bit words required to hold instances of all the elements of this list. This is a sum of the widths (categories) of all the elements.
| |
| indexOfRegister | back to summary |
|---|---|
| public int indexOfRegister(int reg) Returns the index of a RegisterSpec in this list that uses the specified register, or -1 if none in this list uses the register.
| |
| make | back to summary |
|---|---|
| public static RegisterSpecList make(RegisterSpec spec) Makes a single-element instance.
| |
| make | back to summary |
|---|---|
| public static RegisterSpecList make(RegisterSpec spec0, RegisterSpec spec1) Makes a two-element instance.
| |
| make | back to summary |
|---|---|
| public static RegisterSpecList make(RegisterSpec spec0, RegisterSpec spec1, RegisterSpec spec2) Makes a three-element instance.
| |
| make | back to summary |
|---|---|
| public static RegisterSpecList make(RegisterSpec spec0, RegisterSpec spec1, RegisterSpec spec2, RegisterSpec spec3) Makes a four-element instance.
| |
| set | back to summary |
|---|---|
| public void set(int n, RegisterSpec spec) Sets the element at the given index.
| |
| specForRegister | back to summary |
|---|---|
| public RegisterSpec specForRegister(int reg) Returns a RegisterSpec in this list that uses the specified register, or null if there is none in this list.
| |
| subset | back to summary |
|---|---|
| public RegisterSpecList subset(BitSet exclusionSet) Returns a new instance, which contains a subset of the elements specified by the given BitSet. Indexes in the BitSet with a zero are included, while indexes with a one are excluded. Mutability of the result is inherited from the original.
| |
| withAddedType | back to summary |
|---|---|
| public TypeList withAddedType(Type type) Implements org. Doc from org. Returns a new instance which is identical to this one, except that the given item is appended to the end and it is guaranteed to be immutable. | |
| withExpandedRegisters | back to summary |
|---|---|
| public RegisterSpecList withExpandedRegisters(int base, boolean duplicateFirst, BitSet compatRegs) Returns an instance that is identical to this one, except that all incompatible register numbers are renumbered sequentially from the given base, with the first number duplicated if indicated. If a null BitSet is given, it indicates all registers are compatible.
| |
| withFirst | back to summary |
|---|---|
| public RegisterSpecList withFirst(RegisterSpec spec) Returns a new instance, which is the same as this instance, except that it has an additional element prepended to the original. Mutability of the result is inherited from the original.
| |
| withOffset | back to summary |
|---|---|
| public RegisterSpecList withOffset(int delta) Returns an instance that is identical to this one, except that all register numbers are offset by the given amount. Mutability of the result is inherited from the original.
| |
| withoutFirst | back to summary |
|---|---|
| public RegisterSpecList withoutFirst() Returns a new instance, which is the same as this instance, except that its first element is removed. Mutability of the result is inherited from the original.
| |
| withoutLast | back to summary |
|---|---|
| public RegisterSpecList withoutLast() Returns a new instance, which is the same as this instance, except that its last element is removed. Mutability of the result is inherited from the original.
| |