diff options
author | liuhongt <hongtao.liu@intel.com> | 2023-06-13 14:20:59 +0800 |
---|---|---|
committer | liuhongt <hongtao.liu@intel.com> | 2023-06-14 16:18:54 +0800 |
commit | b7e42b85212e03eb59193a712eb523f26911a581 (patch) | |
tree | 08a76f4f8a39bb69044824424b6be661edd4b4d4 | |
parent | 18c8b56c7d67a9e37acf28822587786f0fc0efbc (diff) | |
download | gcc-b7e42b85212e03eb59193a712eb523f26911a581.zip gcc-b7e42b85212e03eb59193a712eb523f26911a581.tar.gz gcc-b7e42b85212e03eb59193a712eb523f26911a581.tar.bz2 |
Use x instead of v for alternative 2 (v, BH) in mov<mode>_internal.
Since there's no evex version for vpcmpeq ymm, ymm, ymm.
gcc/ChangeLog:
PR target/110227
* config/i386/sse.md (mov<mode>_internal>): Use x instead of v
for alternative 2 since there's no evex version for vpcmpeqd
ymm, ymm, ymm.
gcc/testsuite/ChangeLog:
* gcc.target/i386/pr110227.c: New test.
-rw-r--r-- | gcc/config/i386/sse.md | 2 | ||||
-rw-r--r-- | gcc/testsuite/gcc.target/i386/pr110227.c | 11 |
2 files changed, 12 insertions, 1 deletions
diff --git a/gcc/config/i386/sse.md b/gcc/config/i386/sse.md index 7d4b4ec..a0824ef 100644 --- a/gcc/config/i386/sse.md +++ b/gcc/config/i386/sse.md @@ -1333,7 +1333,7 @@ (define_insn "mov<mode>_internal" [(set (match_operand:VMOVE 0 "nonimmediate_operand" - "=v,v ,v,v ,m") + "=v,v ,x,v ,m") (match_operand:VMOVE 1 "nonimmediate_or_sse_const_operand" " C,<sseconstm1>,BH,vm,v"))] "TARGET_SSE diff --git a/gcc/testsuite/gcc.target/i386/pr110227.c b/gcc/testsuite/gcc.target/i386/pr110227.c new file mode 100644 index 0000000..9b59f5b --- /dev/null +++ b/gcc/testsuite/gcc.target/i386/pr110227.c @@ -0,0 +1,11 @@ +/* { dg-do assemble { target { ! ia32 } } } */ +/* { dg-options " -O2 -mavx512vl" } */ + +#include <immintrin.h> + +void f() +{ + __m256i mask = _mm256_set_epi32(0, 0, 0, 0, -1, -1, -1, -1); + register __m256i reg asm("xmm16") = mask; + asm(""::"v"(reg)); +} |