# US 10,768,935 B2 · Boosting local memory performance in processor graphics

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 10,768,935 B2
- Document ID: US10768935B2
- Status: Granted
- Kind: B2
- Application number: 15/765,279
- Filed: 2015-10-29
- Published: 2018-10-18
- Granted: 2020-09-08
- Earliest claimed: 2015-10-29
- Assignees: Intel Corporation
- Applicants: Intel Corporation
- Inventors: Can K. Que
- Web page: https://patentgrep.com/patent/US10768935B2

## CPC

- G06F 9/30138: {Extension of register space, e.g. register cache}
- G06F 9/3867: {using instruction pipelines}
- G06F 9/3887: {controlled by a single instruction for multiple data lanes [SIMD]}
- G06F 9/3888: {controlled by a single instruction for multiple threads [SIMT] in parallel}
- G06F 9/38885: {Divergence aspects}
- G06F 9/522: {Barrier synchronisation}
- G06F 12/0804: with main memory updating (G06F12/0806 takes precedence)
- G06T 1/20: Processor architectures; Processor configuration, e.g. pipelining
- G06T 1/60: Memory management
- G06T 19/00: Manipulating three-dimensional [3D] models or images for computer graphics
- G06F 2212/1016: Performance improvement
- G06F 2212/1024: Latency reduction
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)
- G06T: IMAGE DATA PROCESSING OR GENERATION, IN GENERAL

## Abstract

In some cases, processor graphics with a slower local memory can compensate by using another memory in place of the lowest level or L3 cache. For example, in some processors, there is a large register space that can be used for the local memory function by allocating the local memory within those registers. Also, since the registers do not operate with barriers, barriers can be simulated by letting one execution unit thread execute more SIMD instructions. For example, one execution thread may simulate a whole work-group in the OpenCL API.

## Claims

### Claim 1

A method comprising:
executing a first work-group on a processor, wherein the first work-group comprises a plurality of work-items that are executed in parallel to perform a defined function, wherein the processor comprises internal registers files, wherein the processor uses a cache hierarchy including a lowest level cache and at least one other cache;
determining an available space in the internal register files of the processor;
allocating the determined available space in the internal register files as local memory for the first work-group, wherein the local memory for the first work-group is only accessible by the plurality of work-items included in the first work-group; and
within the available space of the internal register files that is allocated as the local memory for the first work-group, simulating a barrier of the first work-group by controlling a number of single instruction multiple data instructions executed by one execution thread.

### Claim 2 (depends on 1)

The method of claim 1 including:
determining whether the available space in the internal register files is sufficient for the local memory for the first work-group; and
in response to a determination that the available space in the internal register files is not sufficient for the local memory for the first work-group:
allocating the available space in the internal register files as a first portion of the local memory for the first work-group, and
allocating the lowest level cache as a second portion of the local memory for the first work-group.

### Claim 3 (depends on 1)

The method of claim 1 wherein simulating the barrier of the first work-group includes synchronizing the plurality of work-items in the first work-group.

### Claim 4 (depends on 1)

The method of claim 1 wherein the first work-group is an OpenCL work-group.

### Claim 5 (depends on 1)

The method of claim 1 including:
detecting a non-aligned write from a first register location in a source register to a second register location in a destination register, wherein the first register location is not aligned with the second register location;
in response to the detected non-aligned write, generating a plurality of instructions based on permutation group theory; and
transforming the non-aligned write using the generated plurality of instructions.

### Claim 6 (depends on 5)

The method of claim 5 including generating the plurality of instructions in an OpenGL compiler.

### Claim 7 (depends on 5)

The method of claim 5 wherein k is a value calculated using permutation group theory, and wherein generating the plurality of instructions comprises generating log (k−1) instructions to transform the source register.

### Claim 8 (depends on 1)

The method of claim 1, wherein the internal register files are general purpose registers of the processor.

### Claim 9 (depends on 1)

The method of claim 1, wherein the defined function is an OpenGL kernel.

### Claim 10

One or more non-transitory computer readable media storing instructions to perform a sequence comprising:
executing a first work-group on a processor, wherein the first work-group comprises a plurality of work-items that are executed in parallel to perform a defined function, wherein the processor comprises internal registers files, wherein the processor uses a cache hierarchy including a lowest level cache and at least one other cache;
determining an available space in the internal register files of the processor;
allocating the determined available space in the internal register files as local memory for the first work-group, wherein the local memory for the first work-group is only accessible by the plurality of work-items included in the first work-group; and
within the available space of the internal register files that is allocated as the local memory for the first work-group, simulating a barrier of the first work-group by controlling a number of single instruction multiple data instructions executed by one execution thread.

### Claim 11 (depends on 10)

The media of claim 10 including:
determining whether the available space in the internal register files is sufficient for the local memory for the first work-group; and
in response to a determination that the available space in the internal register files is not sufficient for the local memory for the first work-group:
allocating the available space in the internal register files as a first portion of the local memory for the first work-group, and
allocating the lowest level cache as a second portion of the local memory for the first work-group.

### Claim 12 (depends on 10)

The media of claim 10 wherein simulating the barrier of the first work-group includes synchronizing the plurality of work-items in the first work-group.

### Claim 13 (depends on 10)

The media of claim 10 wherein the first work-group is an OpenCL work-group.

### Claim 14 (depends on 10)

The media of claim 10 including:
detecting a non-aligned write from a first register location in a source register to a second register location in a destination register, wherein the first register location is not aligned with the second register location;
in response to the detected non-aligned write, generating a plurality of instructions based on permutation group theory; and
transforming the non-aligned write using the generated plurality of instructions.

### Claim 15 (depends on 14)

The media of claim 14 including generating the plurality of instructions in an OpenGL compiler.

### Claim 16 (depends on 14)

The media of claim 14 wherein k is a value calculated using permutation group theory, and wherein generating the plurality of instructions comprises generating log (k−1) instructions to transform source registers.

### Claim 17 (depends on 10)

The media of claim 10, wherein the internal register files are general purpose registers of the processor.

### Claim 18 (depends on 10)

The media of claim 10, wherein the defined function is an OpenGL kernel.

### Claim 19

An apparatus comprising:
a processor to:
execute a first work-group comprising a plurality of work-items that are executed in parallel to perform a defined function, wherein the processor comprises internal registers files, wherein the processor uses a cache hierarchy including a lowest level cache and at least one other cache;
determine an available space in the internal register files of the processor;
allocate the determined available space in the internal register files as local memory for the first work-group, wherein the local memory for the first work-group is only accessible by the plurality of work-items included in the first work-group; and
within the available space of the internal register files that is allocated as the local memory for the first work-group, simulate a barrier of the first work-group by controlling a number of single instruction multiple data instructions executed by one execution thread; and
a storage coupled to said processor.

### Claim 20 (depends on 19)

The apparatus of claim 19, said processor to:
determine whether the available space in the internal register files is sufficient for the local memory for the first work-group; and
in response to a determination that the available space in the internal register files is not sufficient for the local memory for the first work-group:
allocate the available space in the internal register files as a first portion of the local memory for the first work-group, and
allocate the lowest level cache as a second portion of the local memory for the first work-group.

### Claim 21 (depends on 19)

The apparatus of claim 19, wherein simulating the barrier of the first work-group includes synchronizing the plurality of work-items in the first work-group.

### Claim 22 (depends on 19)

The apparatus of claim 19, wherein the first work-group is an OpenCL work-group.

### Claim 23 (depends on 19)

The apparatus of claim 19, said processor to:
detect a non-aligned write from a first register location in a source register to a second register location in a destination register, wherein the first register location is not aligned with the second register location;
in response to the detected non-aligned write, generate a plurality of instructions based on permutation group theory; and
transform the non-aligned write using the generated plurality of instructions.

### Claim 24 (depends on 23)

The apparatus of claim 23, said processor to generate the plurality of instructions in an OpenGL compiler.

### Claim 25 (depends on 23)

The apparatus of claim 23, wherein k is a value calculated using permutation group theory, and said processor to generate log (k−1) instructions to transform the source register.

### Claim 26 (depends on 19)

The apparatus of claim 19, wherein the internal register files are general purpose registers of the processor.

### Claim 27 (depends on 19)

The apparatus of claim 19, wherein the defined function is an OpenGL kernel.
