bug-gsl
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Bug-gsl] gsl_sf_bessel_Jn_e performance


From: Brian Gough
Subject: Re: [Bug-gsl] gsl_sf_bessel_Jn_e performance
Date: Thu, 12 Jun 2008 16:31:57 +0100
User-agent: Wanderlust/2.14.0 (Africa) Emacs/22.1 Mule/5.0 (SAKAKI)

At Wed, 11 Jun 2008 12:31:39 +0100,
Jonny Taylor wrote:
> I don't know what the policy is regarding optimizations which  
> (slightly) decrease code readability, but there's a simple change to  
> the downward recurrence in gsl_sf_bessel_Jn_e which doubles the speed  
> of the function (almost all the remaining time is spent in  
> gsl_sf_bessel_J_CF1) for n of order 10-40.

Thanks for your email.  That is interesting.  Can you give a few more
details about the compilation options you used, compiler version and
the platform.

Did you see how much of the benefit comes from replacing 2/x by a
constant compared with keeping the value of k in a double?  The
optimisation of replacing (2/x) by a constant would be something I
would expect GCC to deduce at some level.

-- 
Brian Gough




reply via email to

[Prev in Thread] Current Thread [Next in Thread]