Denormal numbers are the border values in the floating-point format and special case values for the processor. Denormal data occurs, for example, in filtering by Infinite Impulse Response (IIR) and Finite Impulse Response (FIR) filters of the signal captured in fixed-point format and converted to the floating-point format. Operations on denormal data make processing slow, even if corresponding interrupts are disabled. To avoid the slowdown effect in denormal data processing, the Intel IPP threshold functions can be applied to the input signal before filtering. For example:
if (denormal_data)
ippsThreshold_LT_32f_I( src, len, 1e-6f );
ippsFIR_32f( src, dst, len, st );
The 1e-6f value is the threshold level; the input data below that level are set to zero. Because the Intel IPP threshold function is very fast, the execution of these two functions is faster than execution of filter if denormal numbers meet in the source data. Of course, if the denormal data occurs while using the filtering procedure, the threshold functions do not help.
For Intel(R) Pentium(R) 4 processor and later processors, you can set special computation modes - flush-to-zero (FTZ) and the denormals-are-zero (DAZ). Use the functions ippSetFlushToZero and ippSetDenormAreZeros to enable these modes. Note that this setting takes effect only when computing is done with the Intel(R) Streaming SIMD Extensions (Intel(R) SSE) and Intel(R) Streaming SIMD Extensions 2 (Intel(R) SSE2) instructions.
The following table illustrates how denormal data may affect performance and shows the effect of thresholding denormal data. As you can see, thresholding takes only three clocks more. On the other hand, denormal data can cause the application performance to drop x250.
Data/Method |
Normal |
Denormal |
Denormal + Threshold |
CPU cycles per element |
46 |
11467 |
49 |
Optimization Notice |
---|
The Intel® Integrated Performance Primitives (Intel® IPP) library contains functions that are more highly optimized for Intel microprocessors than for other microprocessors. While the functions in the Intel® IPP library offer optimizations for both Intel and Intel-compatible microprocessors, depending on your code and other factors, you will likely get extra performance on Intel microprocessors. While the paragraph above describes the basic optimization approach for the Intel® IPP library as a whole, the library may or may not be optimized to the same degree for non-Intel microprocessors for optimizations that are not unique to Intel microprocessors. These optimizations include Intel® Streaming SIMD Extensions 2 (Intel® SSE2), Intel® Streaming SIMD Extensions 3 (Intel® SSE3), and Supplemental Streaming SIMD Extensions 3 (Intel® SSSE3) instruction sets and other optimizations. Intel does not guarantee the availability, functionality, or effectiveness of any optimization on microprocessors not manufactured by Intel. Microprocessor-dependent optimizations in this product are intended for use with Intel microprocessors. Intel recommends that you evaluate other library products to determine which best meets your requirements. |
Copyright © 2008 - 2010, Intel Corporation. All rights reserved.