diff mbox

[testsuite,i386] Avoid finite in gcc.target/i386/avx512dq-vfpclasspd-2.c etc.

Message ID yddwq1m6989.fsf@CeBiTec.Uni-Bielefeld.DE
State New
Headers show

Commit Message

Rainer Orth April 8, 2015, 1:27 p.m. UTC
Some AVX512DQ tests are failing on Solaris/x86 with gas:

FAIL: gcc.target/i386/avx512dq-vfpclasspd-2.c (test for excess errors)
FAIL: gcc.target/i386/avx512dq-vfpclassps-2.c (test for excess errors)
FAIL: gcc.target/i386/avx512vl-vfpclasspd-2.c (test for excess errors)
FAIL: gcc.target/i386/avx512vl-vfpclassps-2.c (test for excess errors)

FAIL: gcc.target/i386/avx512dq-vfpclasspd-2.c (test for excess errors)
Excess errors:
/vol/gcc/src/hg/trunk/local/gcc/testsuite/gcc.target/i386/avx512dq-vfpclasspd-2.c:24:20: warning: implicit declaration of function 'finite' [-Wimplicit-function-declaration]

finite() is non-standard and requires <ieeefp.h> on Solaris.  Instead of
this, I believe it's simplest to just use __builtin_finite instead.

The following patch does just that.  Tested with the appropriate runtest
invocation on i386-pc-solaris2.11 and x86_64-unknown-linux-gnu.

Ok for mainline?

	Rainer


2015-04-08  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>

	* gcc.target/i386/avx512dq-vfpclasspd-2.c (check_fp_class_dp): Use
	__builtin_finite instead of finite.
	* gcc.target/i386/avx512dq-vfpclassps-2.c (check_fp_class_sp):
	Likewise.

Comments

Kirill Yukhin April 13, 2015, 6:31 p.m. UTC | #1
Hello Rainer,
On 08 Apr 15:27, Rainer Orth wrote:
> Ok for mainline?

Patch is ok, thanks!

--
K
Rainer Orth April 13, 2015, 7:16 p.m. UTC | #2
Kirill Yukhin <kirill.yukhin@gmail.com> writes:

> Hello Rainer,
> On 08 Apr 15:27, Rainer Orth wrote:
>> Ok for mainline?
>
> Patch is ok, thanks!

Thanks.  How about the gcc-5 branch?  It would be good to avoid those
failures there, too.

	Rainer
Kirill Yukhin April 13, 2015, 8:37 p.m. UTC | #3
On 13 Apr 21:16, Rainer Orth wrote:
> Kirill Yukhin <kirill.yukhin@gmail.com> writes:
> 
> > Hello Rainer,
> > On 08 Apr 15:27, Rainer Orth wrote:
> >> Ok for mainline?
> >
> > Patch is ok, thanks!
> 
> Thanks.  How about the gcc-5 branch?  It would be good to avoid those
> failures there, too.
Definetely! OK for gcc-5. (sorry for not mentioning that
in original mail)

--
Thanks, K
Rainer Orth April 13, 2015, 9:36 p.m. UTC | #4
Kirill Yukhin <kirill.yukhin@gmail.com> writes:

> On 13 Apr 21:16, Rainer Orth wrote:
>> Kirill Yukhin <kirill.yukhin@gmail.com> writes:
>> 
>> > Hello Rainer,
>> > On 08 Apr 15:27, Rainer Orth wrote:
>> >> Ok for mainline?
>> >
>> > Patch is ok, thanks!
>> 
>> Thanks.  How about the gcc-5 branch?  It would be good to avoid those
>> failures there, too.
> Definetely! OK for gcc-5. (sorry for not mentioning that
> in original mail)

I believe at this point this requires RM approval.  Jakub, Richard?

	Rainer
Richard Biener April 14, 2015, 8:12 a.m. UTC | #5
On Mon, 13 Apr 2015, Rainer Orth wrote:

> Kirill Yukhin <kirill.yukhin@gmail.com> writes:
> 
> > On 13 Apr 21:16, Rainer Orth wrote:
> >> Kirill Yukhin <kirill.yukhin@gmail.com> writes:
> >> 
> >> > Hello Rainer,
> >> > On 08 Apr 15:27, Rainer Orth wrote:
> >> >> Ok for mainline?
> >> >
> >> > Patch is ok, thanks!
> >> 
> >> Thanks.  How about the gcc-5 branch?  It would be good to avoid those
> >> failures there, too.
> > Definetely! OK for gcc-5. (sorry for not mentioning that
> > in original mail)
> 
> I believe at this point this requires RM approval.  Jakub, Richard?

Ok.

Thanks,
Richard.
diff mbox

Patch

# HG changeset patch
# Parent 4a9cc7114f8129eb1eda0f314ca2ae48494b48be
Avoid finite in gcc.target/i386/avx512dq-vfpclasspd-2.c etc.

diff --git a/gcc/testsuite/gcc.target/i386/avx512dq-vfpclasspd-2.c b/gcc/testsuite/gcc.target/i386/avx512dq-vfpclasspd-2.c
--- a/gcc/testsuite/gcc.target/i386/avx512dq-vfpclasspd-2.c
+++ b/gcc/testsuite/gcc.target/i386/avx512dq-vfpclasspd-2.c
@@ -21,7 +21,7 @@  int check_fp_class_dp (double src, int i
   int PInf_res = (isinf (src) == 1);
   int NInf_res = (isinf (src) == -1);
   int Denorm_res = (fpclassify (src) == FP_SUBNORMAL);
-  int FinNeg_res = finite (src) && (src < 0);
+  int FinNeg_res = __builtin_finite (src) && (src < 0);
 
   int result = (((imm & 1) && qNaN_res)
 		|| (((imm >> 1) & 1) && Pzero_res)
diff --git a/gcc/testsuite/gcc.target/i386/avx512dq-vfpclassps-2.c b/gcc/testsuite/gcc.target/i386/avx512dq-vfpclassps-2.c
--- a/gcc/testsuite/gcc.target/i386/avx512dq-vfpclassps-2.c
+++ b/gcc/testsuite/gcc.target/i386/avx512dq-vfpclassps-2.c
@@ -21,7 +21,7 @@  int check_fp_class_sp (float src, int im
   int PInf_res = (isinf (src) == 1);
   int NInf_res = (isinf (src) == -1);
   int Denorm_res = (fpclassify (src) == FP_SUBNORMAL);
-  int FinNeg_res = finite (src) && (src < 0);
+  int FinNeg_res = __builtin_finite (src) && (src < 0);
 
   int result = (((imm & 1) && qNaN_res)
 		|| (((imm >> 1) & 1) && Pzero_res)