summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.target/i386/avx512f-vrndscaleps-2.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/gcc.target/i386/avx512f-vrndscaleps-2.c')
-rw-r--r--gcc/testsuite/gcc.target/i386/avx512f-vrndscaleps-2.c19
1 files changed, 14 insertions, 5 deletions
diff --git a/gcc/testsuite/gcc.target/i386/avx512f-vrndscaleps-2.c b/gcc/testsuite/gcc.target/i386/avx512f-vrndscaleps-2.c
index ca8edad8f40..470313d9741 100644
--- a/gcc/testsuite/gcc.target/i386/avx512f-vrndscaleps-2.c
+++ b/gcc/testsuite/gcc.target/i386/avx512f-vrndscaleps-2.c
@@ -38,7 +38,7 @@ TEST (void)
UNION_TYPE (AVX512F_LEN,) res1, res2, res3, s;
float res_ref[SIZE];
- MASK_TYPE mask = 6 ^ (0xffff >> SIZE);
+ MASK_TYPE mask = MASK_VALUE;
imm = _MM_FROUND_FLOOR | (7 << 4);
@@ -64,12 +64,16 @@ TEST (void)
case 1:
imm = _MM_FROUND_FLOOR;
res1.x = INTRINSIC (_floor_ps) (s.x);
- res2.x = INTRINSIC (_mask_floor_ps) (res2.x, mask, s.x);
+ #if AVX512F_LEN == 512
+ res2.x = INTRINSIC (_mask_floor_ps) (res2.x, mask, s.x);
+ #endif
break;
case 2:
imm = _MM_FROUND_CEIL;
res1.x = INTRINSIC (_ceil_ps) (s.x);
- res2.x = INTRINSIC (_mask_ceil_ps) (res2.x, mask, s.x);
+ #if AVX512F_LEN == 512
+ res2.x = INTRINSIC (_mask_ceil_ps) (res2.x, mask, s.x);
+ #endif
break;
}
@@ -80,8 +84,13 @@ TEST (void)
MASK_MERGE ()(res_ref, mask, SIZE);
- if (UNION_CHECK (AVX512F_LEN,) (res2, res_ref))
- abort ();
+ #if AVX512F_LEN == 512
+ if (UNION_CHECK (AVX512F_LEN,) (res2, res_ref))
+ abort ();
+ #else
+ if (!i && UNION_CHECK (AVX512F_LEN,) (res2, res_ref))
+ abort ();
+ #endif
MASK_ZERO ()(res_ref, mask, SIZE);