This is the mail archive of the
mailing list for the GCC project.
Re: [PATCH] Expand round inline with SSE on x86_64 and i?86
- From: Richard Guenther <rguenther at suse dot de>
- To: Roger Sayle <roger at eyesopen dot com>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Sun, 29 Oct 2006 16:45:28 +0100 (CET)
- Subject: Re: [PATCH] Expand round inline with SSE on x86_64 and i?86
- References: <Pine.LNX.email@example.com>
On Sun, 29 Oct 2006, Roger Sayle wrote:
> On Sun, 29 Oct 2006, Richard Guenther wrote:
> > 2006-08-23 Richard Guenther <firstname.lastname@example.org>
> > * config/i386/i386-protos.h (ix86_expand_round): Declare.
> > (ix86_expand_rounddf_32): Likewise.
> > * config/i386/i386.c (ix86_expand_round): New function expanding
> > round inline for SSE math and -fno-trapping-math.
> > (ix86_expand_rounddf_32): Same for DFmode on 32bit archs.
> > * config/i386/i386.md (rounddf2, roundsf2): New pattern expanding
> > round via ix86_expand_round.
> > * gcc.target/i386/math-torture/round.c: New testcase.
> This is OK for mainline. Thanks.
> I'm not sure how easy it would be to add some execution tests for these
> recent changes. It's complicated by the fact that we need to pass flags
> to the compiler, and test for the presence of SSE at run-time, but all
> of your tests so far only confirm that we don't ICE the compiler, not
> that we get the correct result. In theory, it might be nice to confirm
> that floor(2.6) == 2.0, and ceil(3.4) == 4.0 [but without compile-time
> rounding via real.c getting in the way].
Ok, I can try to produce something. I have a benchmark/verification
that compares against glibc - I could take glibc results as valid and
put it in a table of expected results.
Does this sound like a plan?
Richard Guenther <email@example.com>
Novell / SUSE Labs