Compiler optimization for complex exponential calculations

US2016110171A1 · US · A1

Patent metadata
FieldValue
Publication numberUS-2016110171-A1
Application numberUS-201314129438-A
CountryUS
Kind codeA1
Filing dateJun 14, 2013
Priority dateJun 14, 2013
Publication dateApr 21, 2016
Grant date

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.

Technologies for optimizing complex exponential calculations include a computing device with optimizing compiler. The compiler parses source code, optimizes the parsed representation of the source code, and generates output code. During optimization, the compiler identifies a loop in the source code including a call to the exponential function having an argument that is a loop-invariant complex number multiplied by the loop index variable. The compiler tiles the loop to generate a pair of nested loops. The compiler generates code to pre-compute the exponential function and store the resulting values in a pair of coefficient arrays. The size of each coefficient array may be equal to the square root of the number of loop iterations. The compiler applies rewrite rules to replace the exponential function call with a multiplicative expression of one element from each of the coefficient arrays. Other embodiments are described and claimed.

First claim

Opening claim text (preview).

1 - 25 . (canceled) 26 . A computing device to optimize a source program, the computing device comprising: a processor; source code having a code segment including a loop, the loop having a first number of iterations and including an exponential function call having an argument including a loop-invariant complex number multiplied by a loop index; and a memory having a compiler stored therein, wherein the compiler (i) a loop detect module to detect the code segment, (ii) a loop optimize module to optimize the code segment in response to detection of the code segment, and (iii) a code generator module to generate output code as a function of the optimized code segment, wherein the loop optimize module to: tile the loop to generate an outer loop having a second number of iterations and a nested inner loop having a third number of iterations; generate code to calculate a first coefficient array having a number of elements equal to the third number of iterations, wherein each element of the first coefficient array equals an exponential function of the loop-invariant complex number multiplied by a first coefficient array index; generate code to calculate a second coefficient array having a number of elements equal to the second number of iterations, wherein each element of the second coefficient array equals an exponential function of the loop-invariant complex number multiplied by the third number of iterations and a second coefficient array index; and replace the exponential function call with a multiplicative expression of an element of the first coefficient array at an inner loop index multiplied by an element of the second coefficient array at an outer loop index. 27 . The computing device of claim 26 , wherein the loop optimize module is further to generate a conditional statement to determine whether the first number of iterations exceeds a minimum loop size, the conditional statement to execute the optimized code segment in response to determining the first number of iterations exceeds the minimum loop size. 28 . The computing device of claim 27 , wherein to determine whether the first number of iterations exceeds the minimum loop size comprises to determine whether an iteration space of the loop exceeds a cache size of the computing device. 29 . The computing device of claim 26 , the loop optimize module is further to: determine whether the first number of iterations exceeds a minimum loop size; wherein the loop optimize module is to optimize the code segment in response to a determination that the first number of iterations exceeds the minimum loop size. 30 . The computing device of claim 29 , wherein to determine whether the first number of iterations exceeds the minimum loop size comprises to determine whether an iteration space of the loop exceeds a cache size of a target computing device. 31 . The computing device of claim 26 , wherein the loop optimize module is further to: determine one of: whether the second number of iterations exceeds a minimum loop size or the third number of iterations exceeds the minimum loop size; and optimize one of: the outer loop in response to a determination that the second number of iterations exceeds the minimum loop size, or the inner loop in response to a determination that the third number of iterations exceeds the minimum loop size. 32 . The computing device of claim 31 , wherein to determine whether the second number of iterations or the third number of iterations exceeds the minimum loop size comprises to determine whether an iteration space of the outer loop or an iteration space of the inner loop exceeds a cache size of a target computing device. 33 . The computing device of claim 26 , wherein the loop optimize module is further to optimize the multiplicative expression. 34 . The computing device of claim 33 , wherein to optimize the multiplicative expression comprises one of to: vectorize the multiplicative expression or parallelize the multiplicative expression. 35 . A method for optimizing a source program on a computing device comprising a processor and a memory, the method comprising: detecting, by a compiler of the computing device, a code segment of the source program having a loop, the loop having a first number of iterations and including an exponential function call having an argument including a loop-invariant complex number multiplied by a loop index; and optimizing, by the compiler, the code segment to generate an optimized code segment in response to detecting the code segment, wherein optimizing the code segment comprises: (i) tiling the loop to generate an outer loop having a second number of iterations and a nested inner loop having a third number of iterations; (ii) generating code to calculate the first coefficient array having a number of elements equal to the third number of iterations, wherein each element of the first coefficient array equals the exponential function of the loop-invariant complex number multiplied by the first coefficient array index; (iii) generating code to calculate the second coefficient array having a number of elements equal to the second number of iterations, wherein each element of the second coefficient array equals the exponential function of the loop-invariant complex number multiplied by the third number of iterations and the second coefficient array index; (iv) replacing the exponential function call with a multiplicative expression of an element of the first coefficient array at an inner loop index multiplied by an element of the second coefficient array at an outer loop index. 36 . (canceled) 37 . The method of claim 35 , wherein optimizing the code segment further comprises: generating a conditional statement to determine whether the first number of iterations exceeds a minimum loop size, the conditional statement to execute the optimized code segment in response to determining the first number of iterations exceeds the minimum loop size. 38 . The method of claim 35 , further comprising: determining, by the compiler, whether the first number of iterations exceeds a minimum loop size; wherein optimizing the code segment comprises optimizing the code segment in response to determining the first number of iterations exceeds the minimum loop size. 39 . The method of claim 35 , further comprising: determining, by the compiler, one of: whether the second number of iterations exceeds a minimum loop size or the third number of iterations exceeds the minimum loop size; and optimizing, by the compiler, one of: the outer loop in response to determining the second number of iterations exceeds the minimum loop size, or the inner loop in response to determining the third number of iterations exceeds the minimum loop size. 40 . The method of claim 35 , wherein optimizing the code segment further comprises optimizing the multiplicative expression. 41 . One or more non-transitory, machine readable storage media comprising a plurality of instructions that in response to being executed cause a computing device to: detect, by a compiler, a code segment of a source program having a loop, the loop having a first number of iterations and including an exponential function call having an argument including a loop-invariant complex number multiplied by a loop index; and optimize, by the compiler, the code segment to generate an optimized code segment in response to detecting the code segment, wherein to optimize the code segment comprises to: (i) tile the loop to generate an outer loop having a second number of iterations and a nested inner loop having a thir

Assignees

Inventors

Classifications

  • Logarithmic or exponential functions · CPC title

  • G06F8/443Primary

    Optimisation · CPC title

  • Computations with complex numbers · CPC title

  • Reducing the memory space required by the program code · CPC title

  • Loops · 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 US2016110171A1 cover?
Technologies for optimizing complex exponential calculations include a computing device with optimizing compiler. The compiler parses source code, optimizes the parsed representation of the source code, and generates output code. During optimization, the compiler identifies a loop in the source code including a call to the exponential function having an argument that is a loop-invariant complex…
Who is the assignee on this patent?
Intel Corp
What technology area does this patent fall under?
Primary CPC classification G06F8/443. Mapped technology areas include Physics.
When was this patent published?
Publication date Thu Apr 21 2016 00:00:00 GMT+0000 (Coordinated Universal Time) (A1). Legal status and post-grant events are not shown on this page.
What related patents are in patentsdb?
We list 8 related publications on this page (citations in our corpus or others sharing the same primary CPC).