From: Alexandre Oliva Date: Thu, 11 May 2023 13:06:25 +0000 (-0300) Subject: [vxworks] [testsuite] [aarch64] use builtin in pred-not-gen-4.c X-Git-Tag: basepoints/gcc-15~9432 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3ec6d8a030cd893c24ea5da9e86bc5eaed747b21;p=thirdparty%2Fgcc.git [vxworks] [testsuite] [aarch64] use builtin in pred-not-gen-4.c On vxworks, isunordered is defined as a macro that ultimately calls a _Fpcomp function, that GCC doesn't recognize as a builtin, so it can't optimize accordingly. Use __builtin_isunordered instead to get the desired code for the test. for gcc/testsuite/ChangeLog * gcc.target/aarch64/sve/pred-not-gen-4.c: Drop math.h include, call builtin. --- diff --git a/gcc/testsuite/gcc.target/aarch64/sve/pred-not-gen-4.c b/gcc/testsuite/gcc.target/aarch64/sve/pred-not-gen-4.c index 0001dd3fc211..1845bd3f0f70 100644 --- a/gcc/testsuite/gcc.target/aarch64/sve/pred-not-gen-4.c +++ b/gcc/testsuite/gcc.target/aarch64/sve/pred-not-gen-4.c @@ -1,12 +1,10 @@ /* { dg-do compile } */ /* { dg-options "-O3" } */ -#include - void f13(double * restrict z, double * restrict w, double * restrict x, double * restrict y, int n) { for (int i = 0; i < n; i++) { - z[i] = (isunordered(w[i], 0)) ? x[i] + w[i] : y[i] - w[i]; + z[i] = (__builtin_isunordered(w[i], 0)) ? x[i] + w[i] : y[i] - w[i]; } }