Low-Precision Arithmetic Lookup Arrays for Faster Function Evaluation
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Computing arithmetic functions with reduced precision formats, such as INT8 or FP8, is time-consuming and resource-intensive due to the need for real-time computation, which can significantly slow down program execution.
Innovation Solution
Precomputing output values of arithmetic functions for a range of input values and storing them in arrays, allowing for faster retrieval through lookup instead of real-time computation, especially for functions like exponential and logarithmic functions.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Measurement precision
If real-time computation of arithmetic functions is performed, then computational accuracy is maintained, but computational time and resource usage increase significantly
Solution Approach 1:
The patent precomputes output values for all possible input values within the reduced precision format range and stores them in lookup tables. During execution, the system performs a simple table lookup instead of computing the arithmetic function in real-time, thereby eliminating computational time while maintaining accuracy through precomputed results
Solution Approach 2:
The patent creates a copy of the computationally expensive arithmetic function results by precomputing and storing them in lookup tables. Instead of performing the actual computation during execution, the system retrieves pre-copied results from memory, trading memory usage for computational speed
2Productivity
If reduced precision formats are used, then processing efficiency improves, but the quantity of representable numeric values decreases
Solution Approach 1:
The patent changes the precision parameter of the numeric format from standard floating-point to reduced precision formats (such as INT8 or FP8). This parameter change enables the use of lookup tables with manageable sizes while maintaining sufficient accuracy for the application, thereby improving processing efficiency without significantly compromising the quantity of representable values
3Speed
If lookup tables are used for precomputed values, then retrieval speed increases, but memory requirements increase
Solution Approach 1:
The patent implements a hybrid approach where lookup tables are used for the majority of common input values, but not all possible values are precomputed. For values outside the lookup table range, the system falls back to real-time computation. This partial use of lookup tables achieves significant speed improvement for common cases while limiting memory requirements
Data Source
Figure 1
Figure 2
Figure 3
AI summary
Reduced precision computer number formats inherently limit the quantity of discrete numeric values that can be represented. Therefore, the solution values of an arithmetic function, for each numeric value that is individually and uniquely expressible utilizing such a reduced precision computer number format, can be precomputed since the quantity of unique solution values can be limited to a quantity that can be conveniently stored, such as in an array. Subsequently, rather than computing the solution value of such an arithmetic function, for a given input value, the precomputed array can be referenced and a solution value corresponding to the given input value can be read from the array. Reading numeric values from an array can be substantially faster than computing solution values of a computationally-expensive arithmetic function.