The Community for Technology Leaders
Green Image
Issue No. 02 - February (2009 vol. 58)
ISSN: 0018-9340
pp: 197-207
Christoph Quirin Lauter , École Normale Supérieure de Lyon, Lyon
Vincent Lefèvre , LIP ENS Lyon INRIA, Lyon
The correct rounding of the function pow: (x, y) \mapsto x^{y} is currently based on Ziv's iterative approximation process. In order to ensure its termination, cases when x^{y} falls on a rounding-boundary must be filtered out. Such rounding-boundaries are floating-point numbers and midpoints between two consecutive floating-point numbers. Detecting rounding-boundaries for pow is a difficult problem. Previous approaches use repeated square root extraction followed by repeated square and multiply. This paper presents a new rounding-boundary test for pow in double precision, which reduces this to a few comparisons with precomputed constants. These constants are deduced from worst cases for the Table Maker's Dilemma, searched over a small subset of the input domain. This is a novel use of such worst-case bounds. The resulting algorithm has been designed for a fast-on-average correctly rounded implementation of pow, considering the scarcity of rounding-boundary cases. It does not stall average computations for rounding-boundary detection. This paper includes its correctness proof and experimental results.
Floating-point arithmetic, correct rounding, power function.

V. Lefèvre and C. Q. Lauter, "An Efficient Rounding Boundary Test for {\rm pow}(x, y) in Double Precision," in IEEE Transactions on Computers, vol. 58, no. , pp. 197-207, 2008.
95 ms
(Ver 3.3 (11022016))