This is the mail archive of the
libc-ports@sources.redhat.com
mailing list for the libc-ports project.
Re: [PATCH] Speed up libm on MIPS
- From: Richard Henderson <rth at twiddle dot net>
- To: Steve Ellcey <sellcey at mips dot com>
- Cc: libc-ports at sourceware dot org
- Date: Fri, 20 Sep 2013 08:00:55 -0700
- Subject: Re: [PATCH] Speed up libm on MIPS
- Authentication-results: sourceware.org; auth=none
- References: <1379631395 dot 5770 dot 445 dot camel at ubuntu-sellcey>
On 09/19/2013 03:56 PM, Steve Ellcey wrote:
> +libc_fesetenv_mips (fenv_t *envp)
> +{
> + fpu_control_t cw;
> +
> + /* Read first current state to flush fpu pipeline. */
> + _FPU_GETCW (cw);
> +
> + if (envp == FE_DFL_ENV)
> + _FPU_SETCW (_FPU_DEFAULT);
> + else if (envp == FE_NOMASK_ENV)
> + _FPU_SETCW (_FPU_IEEE);
> + else
> + _FPU_SETCW (envp->__fp_control_register);
> +}
You shouldn't need the two default env checks, since this private
interface will always be used in pairs.
r~