Update ENTERI() macro
Bruce Evans
brde at optusnet.com.au
Fri Mar 8 13:58:51 UTC 2019
On Thu, 7 Mar 2019, Steve Kargl wrote:
> On Thu, Mar 07, 2019 at 04:22:45PM -0800, Steve Kargl wrote:
>>
>> Make that 3 bugs.
>>
>> Index: ld80/k_expl.h
>> ===================================================================
>> --- ld80/k_expl.h (revision 344600)
>> +++ ld80/k_expl.h (working copy)
>> @@ -285,7 +285,7 @@
>> y = cimagl(z);
>> __k_expl(x, &hi, &lo, &k);
>>
>> - exp_x = (lo + hi) * 0x1p16382;
>> + exp_x = (lo + hi) * 0x1p16382L;
>> expt += k - 16382;
>>
>> scale1 = 1;
>> @@ -292,9 +292,9 @@
>> half_expt = expt / 2;
>> SET_LDBL_EXPSIGN(scale1, BIAS + half_expt);
>> scale2 = 1;
>> - SET_LDBL_EXPSIGN(scale1, BIAS + expt - half_expt);
>> + SET_LDBL_EXPSIGN(scale2, BIAS + expt - half_expt);
Oops.
> This bug appears in ld128/k_expl.h. The other two bugs
> are not present or were fixed at some point.
All 3 are in both ld*/k_expl.h. This one is is fixed or not
present in my src/k_exp[f].c.
>>
>> - return (CMPLXL(cos(y) * exp_x * scale1 * scale2,
>> + return (CMPLXL(cosl(y) * exp_x * scale1 * scale2,
One like this is fixed or not present in src/k_expf.c.
>> sinl(y) * exp_x * scale1 * scale2));
>> }
>> #endif /* _COMPLEX_H */
Bruce
More information about the freebsd-numerics
mailing list