On 05/15/2011 07:13 AM, Aurelien Jarno wrote:
> +    temp = floatx80_add(ST0, floatx80_one, &env->fp_status);
> +    if (!floatx80_is_neg(temp)) {
> +        temp = floatx80_add(ST0, floatx80_one, &env->fp_status);
> +        temp = floatx80_log2(temp, &env->fp_status);
> +        ST1 = floatx80_mul(ST1, temp, &env->fp_status);

While this is probably better than the existing code, you really
should be using a different series expansion than for log2.  This
expansion will be wildly inaccurate for inputs near zero.


r~

Reply via email to