This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH v3] soft-fp: Add the lack of implementation for 128 bit self-contained.
- From: Richard Henderson <rth at twiddle dot net>
- To: Zong Li <zong at andestech dot com>, joseph at codesourcery dot com, palmer at dabbelt dot com, darius at bluespec dot com, andrew at sifive dot com, dj at redhat dot com
- Cc: libc-alpha at sourceware dot org, zongbox at gmail dot com, rth7680 at gmail dot com
- Date: Thu, 26 Jul 2018 09:59:02 -0700
- Subject: Re: [PATCH v3] soft-fp: Add the lack of implementation for 128 bit self-contained.
- References: <1532610973-22705-1-git-send-email-zong@andestech.com>
On 07/26/2018 06:16 AM, Zong Li wrote:
> +#define _FP_FRAC_CLZ_8(R, X) \
> + do \
> + { \
> + if (X##_f[7]) \
> + __FP_CLZ ((R), X##_f[7]); \
> + else if (X##_f[6]) \
> + { \
> + __FP_CLZ ((R), X##_f[6]); \
> + (R) += _FP_W_TYPE_SIZE; \
> + } \
> + else if (X##_f[5]) \
...
Perhaps better as
#define _FP_FRAC_CLZ_8(R, X) \
do \
{ \
int fs8_i; \
for (fs8_i = 7; fs8_i > 0; fs8_i--) \
if (X##_f[fs8_i]) \
break; \
__FP_CLZ ((R), X##_f[fs8_i]); \
(R) += _FP_W_TYPE_SIZE * (7 - fs8_i); \
} \
while (0)
r~