This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: PATCH: Enable TFmode for SSE2
On Sat, 28 Jun 2008, H.J. Lu wrote:
> > t-fprules-softfp64, so we can convert 128bit FP to 128bit integer on
> > x86_64. x86_32 should define its own t-fprules-softfp32, where TImode
> > is omitted.
>
> This won't work since we need both 32bit and 64bit version of
> soft-fp for Linux/x86-64.
Complete the toplevel libgcc transition
<http://gcc.gnu.org/wiki/Top-Level_Libgcc_Migration> and you can make the
definitions in t-* files used for libgcc depend on the multilib in any way
that's convenient.
Actually, I'm sure you don't need the full transition; it should be
possible to transition just enough for the definitions of LIB2FUNCS_EXTRA
and LIB2FUNCS_EXCLUDE to be determined in the libgcc directory rather than
communicated from the gcc directory. And there might be ways to hack
things without the transition - but moving this configuration to the
libgcc directory would make it *much* easier. The transition aim is for
all the configuration logic and source files used in libgcc and related
objects built for the target to go in the libgcc directory. (There are
several further cleanups possible afterwards, but I'd consider the
transition complete at that point.)
Obviously completing the transition shouldn't be a requirement for getting
in the basic compiler support, but I'd be very glad if it were completed,
or even if just the part needed for soft-fp were completed.
> It is the same problem with TImode. Also __float80 and __float128
> don't depend on MMX nor SSE. I moved __float80 and __float128
> to ix86_init_builtins. I enabled __builtin_fabsq and
> __builtin_copysignq only if HOST_BITS_PER_WIDE_INT >= 64 and SSE2
> is available. Is there a way to generate library call when builtin
> pattern isn't available?
Making built-in functions - a user-visible interface - available depending
on HOST_BITS_PER_WIDE_INT is a very bad idea; it's bad enough for code
generation to depend on HOST_BITS_PER_WIDE_INT. Just make i?86 require
64-bit HOST_WIDE_INT unconditionally as a separate patch (to
gcc/config.gcc and libcpp/configure.ac) marked as fixing bug 35466.
I'd hope it should be possible to work out expansions of these builtins
inline for 32-bit without SSE2; it's not as if they need to do more than
simple bit manipulation.
> OK for trunk?
This patch does not include the required testsuite changes. By making the
types available unconditionally for x86 the very simplest change is
possible: every test of __float80 or __float128 can be enabled for all
i?86 and x86_64 targets rather than just those targets with lp64, and no
special options need be passed.
--
Joseph S. Myers
joseph@codesourcery.com