Re: probably cause (and fix) for floating-point assist faults on itanium

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

 



On Thu, Nov 17, 2011 at 10:07 PM, Greg Matthews
<gregory.a.matthews@xxxxxxxx> wrote:
>        if (smoothed_alloc <= (float) recent_alloc)
>                smoothed_alloc = recent_alloc;
>        else if (smoothed_alloc >= 0.00001)
>                smoothed_alloc += ((float) recent_alloc - smoothed_alloc) /
>                        smoothing_samples;
>

I don't think that logic is sound.

Rather,

       if (smoothed_alloc <= (float) recent_alloc) {
               smoothed_alloc = recent_alloc;
       } else {
               if (smoothed_alloc < 0.000001)
                   smoothed_alloc = 0;
               smoothed_alloc += ((float) recent_alloc - smoothed_alloc) /
                       smoothing_samples;
       }

-- 
Sent via pgsql-performance mailing list (pgsql-performance@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-performance



[Postgresql General]     [Postgresql PHP]     [PHP Users]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Yosemite]

  Powered by Linux