This is the mail archive of the
mailing list for the glibc project.
Re: [RFC][PATCH] fix math cflags overrides
- From: Joseph Myers <joseph at codesourcery dot com>
- To: Szabolcs Nagy <szabolcs dot nagy at arm dot com>
- Cc: GNU C Library <libc-alpha at sourceware dot org>, <nd at arm dot com>
- Date: Thu, 24 Aug 2017 14:33:46 +0000
- Subject: Re: [RFC][PATCH] fix math cflags overrides
- Authentication-results: sourceware.org; auth=none
- References: <599E9BF4.email@example.com>
On Thu, 24 Aug 2017, Szabolcs Nagy wrote:
> as a workaround i'd just use += instead of = in the dbl-64 makefile
> cflags definitions so at least it does not drop earlier cflags,
> the cflag definition ordering is not ideal: if i have a target
> specific sqrt, i don't want to compile it with nofma flags.
This patch is OK on the general principle of using += in Makefiles when
overriding is not specifically intended.
For a target-specific file, the nofma flags could be worked around by just
having a dummy e_sqrt.c and the main implementation in a separate
e_sqrt_<arch>.c. Or make all the cases where contraction is appropriate
explicit (e.g. sysdeps/powerpc/fpu/e_sqrt.c makes explicit use of
__builtin_fma to fix bug 17964).
Joseph S. Myers