This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH v3] Add tests for the long double version of ecvt and fcvt
- From: "Gabriel F. T. Gomes" <gabriel at inconstante dot eti dot br>
- To: Florian Weimer <fweimer at redhat dot com>
- Cc: <libc-alpha at sourceware dot org>
- Date: Wed, 12 Dec 2018 11:07:41 -0200
- Subject: Re: [PATCH v3] Add tests for the long double version of ecvt and fcvt
- References: <20181108222916.27414-1-gabriel@inconstante.eti.br> <87bm5sulmt.fsf@oldenburg2.str.redhat.com>
On Tue, 11 Dec 2018, Florian Weimer wrote:
>* Gabriel F. T. Gomes:
>
>> * misc/tst-efgcvt-template.c: Renamed from misc/tst-efgcvt.c.
>
>I think you should add a file comment with a brief list of all the
>customization macros.
Is the following text all right?
/* This template provides testing for the *cvt family of functions,
which deal with double or long double types. In order to use the
template, the following macros must be defined before inclusion of
this template:
FLOAT: The floating-point type, i.e. double or long double.
ECVT: Appropriate *ecvt function for FLOAT, i.e. ecvt or qecvt.
FCVT: Likewise for *fcvt, i.e. fcvt or qfcvt.
ECVT_R: Likewise for *ecvt_r, i.e. ecvt_r or qecvt_r.
FCVT_R: Likewise for *fcvt_r, i.e. fcvt_r or qfcvt_r.
NAME: Macro to stringify the name of the function, e.g. ecvt,
possibly adding prefixes or suffixes to it, e.g. qecvt.
PRINTF_CONVERSION: The appropriate printf conversion specifier with
length modifier for FLOAT, i.e. "%f" or "%Lf".
EXTRA_ECVT_TESTS: Additional tests for the ecvt or qecvt function
that are only relevant to a particular floating-point type and
cannot be represented generically. */
>Do you expect NAME to be customizable in the future?
No more than what is already implemented, i.e. when FLOAT is double,
errors print the function name as ecvt or fcvt, but when FLOAT is long
double, you get qecvt, qfcvt, etc. For the long double transition on
powerpc64le, I do *not* plan to make this test print the internal name of
the functions, e.g. __qecvtieee128.