Processing Unit Exponential Function Evaluation Circuit
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Existing processing units face challenges in efficiently and accurately evaluating exponential functions, which can lead to slow program execution and statistical errors, especially in neural network processing where biases in overestimation or underestimation can result in poorly trained models.
Innovation Solution
A processing unit is designed with a hardware module that includes a multiplier circuit, a lookup table, a barrel shifter, and circuitry to quickly evaluate exponential functions by multiplying the operand by log2(e), converting the result to a fixed-point number, extracting the fractional part, and using the lookup table to provide an estimate for 2f without bias, thereby avoiding statistical errors and achieving faster processing.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Speed
If a processing unit uses traditional software-based exponential function evaluation, then the implementation is simpler and more flexible, but the execution speed is slow and consumes multiple processor thread cycles
Solution Approach 1:
The patent replaces the software-based exponential function evaluation (mechanical/system-level operation) with a dedicated hardware module that performs the calculation in parallel circuitry. This substitution enables single-cycle execution by implementing the exponential function evaluation directly in hardware using a lookup table and barrel shifter, eliminating the need for multi-cycle software computation.
2Productivity
If a processing unit uses approximate methods for exponential function evaluation, then the processing speed increases, but the accuracy decreases and introduces statistical errors
Solution Approach 1:
The patent introduces a lookup table as an intermediary structure that pre-stores accurate exponential function values. The hardware module queries this table with exponent values and retrieves pre-computed results, ensuring high accuracy while maintaining fast processing speed. This intermediary approach avoids both slow direct computation and inaccurate approximation.
Solution Approach 2:
The patent performs preliminary computation of exponential function values and stores them in a lookup table before actual processing occurs. This pre-computation allows the hardware module to retrieve accurate results in constant time during execution, achieving both high speed and high accuracy without introducing statistical errors.
3Measurement precision
If a processing unit uses a lookup table with high precision entries, then the calculation accuracy improves, but the memory requirements and table size increase
Solution Approach 1:
The patent segments the exponential function evaluation into two parts: the exponent portion (handled by indexing into the lookup table) and the mantissa portion (handled by the barrel shifter). This segmentation allows the lookup table to store only the essential precision data while the barrel shifter handles the remaining computational precision requirements, reducing overall memory requirements while maintaining accuracy.
Data Source
AI summary
A processing unit is provided with circuitry enabling execution quick evaluation of an exponential function. A multiplier circuit is used to multiply the input operand by log2(e), such that a result for the exponential function may be determined by evaluating 2i+f, where i is an integer part of a fixed-point number and f is a fractional part of the fixed-point number. A lookup table is used for providing an estimate for 2f based on the l MSBs of f. The lookup entries are provided according to a function such that the estimates for 2f are provided without bias towards either zero or infinity in the result. In other words, the maximum multiplicative error for each entry of the lookup table is the same in both negative and positive directions. In this way, statistical errors in the evaluation of a large number of exponential functions may be avoided.


