Specialized code paths in GPU processing

US10140678B2 · US · B2

Patent metadata
FieldValue
Publication numberUS-10140678-B2
Application numberUS-201615089270-A
CountryUS
Kind codeB2
Filing dateApr 1, 2016
Priority dateDec 18, 2015
Publication dateNov 27, 2018
Grant dateNov 27, 2018

How to read this patent

A practical reading order for non-experts. Skip the full description unless you need deep technical detail.

  1. Title

    What the patent document calls the invention.

  2. Abstract

    A short plain-language summary of the technical disclosure.

  3. Assignees and inventors

    Who owns or filed the patent and who is credited as inventor.

  4. Key dates

    Filing, priority, publication, and grant dates set the timeline.

  5. First independent claim

    The legal scope of protection — read this for what is actually claimed.

  6. CPC / IPC classifications

    Technology tags used to group this patent with similar filings.

  7. Citations and related patents

    Prior art links and similar publications in this corpus.

Abstract

Official abstract text for this publication.

Techniques to improve graphics processing unit (GPU) performance by introducing specialized code paths to process frequent common values are described. A shader compiler can determine instruction that, during operation, may output a common value and can introduce an enhanced shader instruction branch to process the common value to reduce overall computational requirements to execute the shader.

First claim

Opening claim text (preview).

What is claimed is: 1. An apparatus to compile a shader comprising: logic, at least a portion of which is implemented in hardware, the logic to: determine whether an output-merger (OM) state of a shader instruction is set to a src_alpha; and compile the shader instruction to include an optimized sub-sequence based on a determination that the OM state is set to src_alpha. 2. The apparatus of claim 1 , the logic to: select the shader instruction that will output a value that matches a predetermined value, wherein the predetermined value comprises one, zero, 1.0 f, or 0.0 f; and compile the shader instruction to include the optimized sub-sequence based on selection of the shader instruction. 3. The apparatus of claim 2 , the logic to: evaluate at least one coordinate; and determine whether the shader instruction can output the predetermined value based on the at least one coordinate. 4. The apparatus of claim 2 , wherein the shader instruction comprises a sample_c instruction, a mul_sat instruction, an add_sat instruction, a ld instruction, a sample instruction, an AND instruction, a greater than instruction, an equal to instruction, or a less than instruction. 5. The apparatus of claim 2 , the logic to generate an optimized shader based in part on compiling the shader instructions, the optimized shader to: determine whether the output of the shader instruction equals the predetermined value; and execute a first sequence based on a determination that the output of the shader instruction equals the predetermined value; and execute a second sequence based on a determination that the output of the shader instruction does not equal the predetermined value, the second sequence requiring more graphics processing resources than the first sequence. 6. The apparatus of claim 2 , the logic to: determine whether the shader instruction can be folded based on a determination that the shader instruction can output the predetermined value; and compile the shader instruction to include the optimized sub-sequence based on a determination that the shader instruction can be folded. 7. The apparatus of claim 6 , the logic to compile the shader instruction omitting the optimized sub-sequence based on a determination that the shader instruction cannot be folded. 8. The apparatus of claim 2 , wherein the compiled shaders comprise a pixel shader, a vertex shader, a depth shader, a fragment shader, a domain shader, a hull shader, a computer shader, or a geometry shader. 9. The apparatus of claim 1 , the logic to compile the shader instruction omitting the optimized sub-sequence based on a determination that the OM state is not set to src_alpha. 10. The apparatus of claim 1 , the logic to: determine whether an alpha-max corresponding to the shader instruction is equal to zero; and bind the shader based on a determination that the alpha_max corresponding to the shader instruction equals zero. 11. A method comprising: determining whether an output-merger (OM) state of a shader instruction is set to a src_alpha; and compiling the shader instruction to include an optimized sub-sequence based on a determination that the OM state is set to src_alpha. 12. The method of claim 11 , comprising: selecting the shader instruction that will output a value that matches a predetermined value, wherein the predetermined value comprises one, zero, 1.0 f, or 0.0 f; and compiling the shader instruction to include the optimized sub-sequence based on selection of the shader instruction. 13. The method of claim 12 , comprising: evaluating at least one coordinate; and determining whether the shader instruction can output the predetermined value based on the at least one coordinate. 14. The method of claim 12 , wherein the shader instruction comprises a sample_c instruction, a mul_sat instruction, an add_sat instruction, a ld instruction, a sample instruction, an AND instruction, a greater than instruction, an equal to instruction, or a less than instruction. 15. The method of claim 12 , comprising: determining whether the shader instruction can be folded based on a determination that the shader instruction can output the predetermined value; and compiling the shader instruction to include the optimized sub-sequence based on a determination that the shader instruction can be folded. 16. The method of claim 15 , comprising compiling the shader instruction omitting the optimized sub-sequence based on a determination that the shader instruction cannot be folded. 17. At least one non-transitory machine-readable storage medium comprising instructions that when executed by a computing device, cause the computing device to: determine whether an output-merger (OM) state of a shader instruction is set to a src_alpha; and compile the shader instruction to include an optimized sub-sequence based on a determination that the OM state is set to src_alpha. 18. The at least one non-transitory machine-readable storage medium of claim 17 , comprising instructions that when executed by the computing device, cause the computing device to: select the shader instruction that will output a value that matches a predetermined value, wherein the predetermined value comprises one, zero, 1.0 f, or 0.0 f; and compile the shader instruction to include the optimized sub-sequence based on selection of the shader instruction. 19. The at least one non-transitory machine-readable storage medium of claim 18 , comprising instructions that when executed by the computing device, cause the computing device to: evaluate at least one coordinate; and determine whether the shader instruction can output the predetermined value based on the at least one coordinate. 20. The at least one non-transitory machine-readable storage medium of claim 18 , wherein the shader instruction comprises a sample_c instruction, a mul_sat instruction, an add_sat instruction, a ld instruction, a sample instruction, an AND instruction, a greater than instruction, an equal to instruction, or a less than instruction. 21. The at least one non-transitory machine-readable storage medium of claim 17 , comprising instruction that when executed by the GPU, cause the GPU to: evaluate at least one coordinate of pixel; execute a shader instruction based on the at least one coordinate; determine whether an output of the shader instruction equals a value that matches a predetermined value, wherein the predetermined value comprises one, zero, 1.0 f, or 0.0 f; and execute a first sequence based on a determination that the output equals the predetermined value; and execute a second sequence based on a determination that the output does not equal the predetermined value. 22. The at least one non-transitory machine-readable storage medium of claim 21 , comprising instruction that when executed by the GPU, wherein the shader instruction comprises a sample_c instruction, a mul_sat instruction, an add_sat instruction, a ld instruction, a sample instruction, an AND instruction, a greater than instruction, an equal to instruction, or a less than instruction.

Assignees

Inventors

Classifications

  • General purpose rendering architectures · CPC title

  • Instruction analysis, e.g. decoding, instruction word fields · CPC title

  • G06F8/41Primary

    Compilation · CPC title

  • of variable length instructions · CPC title

  • G06T1/20Primary

    Processor architectures; Processor configuration, e.g. pipelining · CPC title

Patent family

Related publications grouped by family.

External sources

Frequently asked questions

Answers are generated from the same data shown on this page.

What does patent US10140678B2 cover?
Techniques to improve graphics processing unit (GPU) performance by introducing specialized code paths to process frequent common values are described. A shader compiler can determine instruction that, during operation, may output a common value and can introduce an enhanced shader instruction branch to process the common value to reduce overall computational requirements to execute the shader.
Who is the assignee on this patent?
Intel Corp
What technology area does this patent fall under?
Primary CPC classification G06F8/41. Mapped technology areas include Physics.
When was this patent published?
Publication date Tue Nov 27 2018 00:00:00 GMT+0000 (Coordinated Universal Time) (B2). Legal status and post-grant events are not shown on this page.
What related patents are in patentsdb?
We list 2 related publications on this page (citations in our corpus or others sharing the same primary CPC).