From: Uros Bizjak Date: Thu, 5 Apr 2018 16:50:49 +0000 (+0200) Subject: re PR target/85193 (ICE: SIGSEGV in memory_operand at recog.c:1361 with -O2 -fno... X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=b5f3bb7b5f7d4a67ace230ed5b0c46cd71d41c6d;p=gcc.git re PR target/85193 (ICE: SIGSEGV in memory_operand at recog.c:1361 with -O2 -fno-tree-ccp -fno-tree-fre -mno-sse) PR target/85193 * config/i386/i386.md (define_attr "memory"): Handle rotate1 type. testsuite/ChangeLog: PR target/85193 * gcc.target/i386/pr85193.c: New test. From-SVN: r259134 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 517ac4e57ae..be9c255a4b6 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2018-04-05 Uros Bizjak + + PR target/85193 + * config/i386/i386.md (define_attr "memory"): Handle rotate1 type. + 2018-04-05 Tom de Vries PR target/85204 diff --git a/gcc/config/i386/i386.md b/gcc/config/i386/i386.md index b28e7831030..352212094ec 100644 --- a/gcc/config/i386/i386.md +++ b/gcc/config/i386/i386.md @@ -752,7 +752,7 @@ (if_then_else (match_operand 1 "constant_call_address_operand") (const_string "none") (const_string "load")) - (and (eq_attr "type" "alu1,negnot,ishift1,sselog1,sseshuf1") + (and (eq_attr "type" "alu1,negnot,ishift1,rotate1,sselog1,sseshuf1") (match_operand 1 "memory_operand")) (const_string "both") (and (match_operand 0 "memory_operand") @@ -763,7 +763,7 @@ (match_operand 1 "memory_operand") (const_string "load") (and (eq_attr "type" - "!alu1,negnot,ishift1, + "!alu1,negnot,ishift1,rotate1, imov,imovx,icmp,test,bitmanip, fmov,fcmp,fsgn, sse,ssemov,ssecmp,ssecomi,ssecvt,ssecvt1,sseicvt, diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 570bfdca4df..45fecfb27bf 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2018-04-05 Uros Bizjak + + PR target/85193 + * gcc.target/i386/pr85193.c: New test. + 2018-04-05 Alexandre Oliva PR c++/84979 diff --git a/gcc/testsuite/gcc.target/i386/pr85193.c b/gcc/testsuite/gcc.target/i386/pr85193.c new file mode 100644 index 00000000000..98e3dafc7ae --- /dev/null +++ b/gcc/testsuite/gcc.target/i386/pr85193.c @@ -0,0 +1,17 @@ +/* { dg-do compile } */ +/* { dg-options "-Wno-psabi -O2 -fno-tree-ccp -fno-tree-fre -mno-sse" } */ + +typedef unsigned char U __attribute__((vector_size(16))); +typedef unsigned int V __attribute__((vector_size(16))); +typedef unsigned long long W __attribute__((vector_size(16))); + +extern void bar(U, U); + +V v; + +void +foo(U f) +{ + f[0] = f[0] << (unsigned char)~v[0] | f[~((W)(U){0, 0, 0, 0, 0, 0, 0, 0, 5})[1] & 5] >> (-(unsigned char)~v[0] & 7); + bar(f, (U){}); +}