Register allocation for graphics processing
First Claim
Patent Images
1. A method comprising:
- receiving, with a processor executing a compiler, a program with at least one instruction for graphics processing for operation on at least one non-scalar value, wherein the at least one non-scalar value comprises a value that cannot be stored in a single physical register of a specified size;
dividing, with the processor executing the compiler, the at least one instruction for operation on the at least one non-scalar value into a plurality of instructions for operation on constituent scalar values of the at least one non-scalar value, wherein each one of the constituent scalar values can be stored in the single physical register of the specified size;
allocating, with the processor executing the compiler, a plurality of physical registers to store the constituent scalar values; and
recomposing, with the processor executing the compiler, the plurality of instructions for operation on the constituent scalar values into a recomposed instruction for operation on the non-scalar value, wherein the recomposed instruction includes indices to the allocated physical registers.
1 Assignment
0 Petitions
Accused Products
Abstract
In general, aspects of this disclosure describe a compiler for allocation of physical registers for storing constituent scalar values of a non-scalar value. In some example, the compiler, executing on a processor, may receive an instruction for operation on a non-scalar value. The compiler may divide the instruction into a plurality of instructions for operation on constituent scalar values of the non-scalar value. The compiler may allocate a plurality of physical registers to store the constituent scalar values.
16 Citations
34 Claims
-
1. A method comprising:
-
receiving, with a processor executing a compiler, a program with at least one instruction for graphics processing for operation on at least one non-scalar value, wherein the at least one non-scalar value comprises a value that cannot be stored in a single physical register of a specified size; dividing, with the processor executing the compiler, the at least one instruction for operation on the at least one non-scalar value into a plurality of instructions for operation on constituent scalar values of the at least one non-scalar value, wherein each one of the constituent scalar values can be stored in the single physical register of the specified size; allocating, with the processor executing the compiler, a plurality of physical registers to store the constituent scalar values; and recomposing, with the processor executing the compiler, the plurality of instructions for operation on the constituent scalar values into a recomposed instruction for operation on the non-scalar value, wherein the recomposed instruction includes indices to the allocated physical registers. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8, 9)
-
-
10. A device comprising:
-
a plurality of physical registers that are each of a specified size; and a processor executing a compiler that is configured to; receive a program with at least one instruction for graphics processing for operation on at least one non-scalar value, wherein the at least one non-scalar value comprises a value that cannot be stored in the specified size of a single physical register of the plurality of physical registers; divide the at least one instruction for operation on the at least one non-scalar value into a plurality of instructions for operation on constituent scalar values of the at least one non-scalar value, wherein each one of the constituent scalar values can be stored in the specified size of the single physical register; allocate two or more physical registers of the plurality of physical registers to store the constituent scalar values; and recompose the plurality of instructions for operation on the constituent scalar values into a recomposed instruction for operation on the non-scalar value, wherein the recomposed instruction includes indices to the allocated physical registers. - View Dependent Claims (11, 12, 13, 14, 15, 16, 17, 18)
-
-
19. A non-transitory computer-readable storage medium comprising instructions for a compiler that cause one or more processors to:
-
receive, with the compiler, a program with at least one instruction for graphics processing for operation on at least one non-scalar value, wherein the at least one non-scalar value comprises a value that cannot be stored in a single physical register of a specified size; divide, with the compiler, the at least one instruction for operation on the at least one non-scalar value into a plurality of instructions for operation on constituent scalar values of the at least one non-scalar value, wherein each one of the constituent scalar values can be stored in the single physical register of the specified size; allocate, with the compiler, a plurality of physical registers to store the constituent scalar values; and recompose, with the compiler, the plurality of instructions for operation on the constituent scalar values into a recomposed instruction for operation on the non-scalar value, wherein the recomposed instruction includes indices to the allocated physical registers. - View Dependent Claims (20, 21, 22, 23, 24, 25, 26)
-
-
27. A device comprising:
-
means for receiving, with a processor executing a compiler, a program with at least one instruction for graphics processing for operation on at least one non-scalar value, wherein the at least one non-scalar value comprises a value that cannot be stored in a single physical register of a specified size; means for dividing, with the processor executing the compiler, the at least one instruction for operation on the at least one non-scalar value into a plurality of instructions for operation on constituent scalar values of the at least one non-scalar value, wherein each one of the constituent scalar values can be stored in the single physical register of the specified size; means for allocating, with the processor executing the compiler, a plurality of physical registers to store the constituent scalar values; and means for recomposing, with the processor executing the compiler, the plurality of instructions for operation on the constituent scalar values into a recomposed instruction for operation on the non-scalar value, wherein the recomposed instruction includes indices to the allocated physical registers. - View Dependent Claims (28, 29, 30, 31, 32, 33, 34)
-
Specification