[PATCH 2/2] Improves __ieee754_exp() performance by greater than 5x on sparc/x86.

Joseph Myers joseph@codesourcery.com
Thu Nov 2 21:09:00 GMT 2017


On Thu, 2 Nov 2017, Patrick McGehearty wrote:

> Version 4 of proposed patch.

I'd expect a single patch with the formatting fixed rather than a repost 
of a previous version followed by a patch to fix up the formatting, since 
the version with non-GNU formatting should never be committed.

>  	  if (fe_val == FE_TONEAREST) {
>  	    t = xx.x * xx.x;

Another formatting issue: that's not the correct brace position in GNU 
style, which always uses

if (condition)
  {
    block contents;
  }

so the braced block is below and indented from the if, then the contents 
of the block are again indented.

> -/* maximum value for -x to not underflow */
> +/* maximum value for -x to not underflow to zero in FE_NEAREST mode */

It's FE_TONEAREST, I think this means for exp(-x) not to underflow rather 
than for -x not to underflow, and the formatting as elsewhere should be 
sentence style,

/* Maximum value for exp (-x) not to underflow to zero in FE_TONEAREST
   mode.  */

or similar.  Likewise for other comments (start with a capital letter, end 
with "." and two spaces).

-- 
Joseph S. Myers
joseph@codesourcery.com



More information about the Libc-alpha mailing list