[Bug target/48612] [4.7 Regression] vminps instruction is generated with -ftree-vectorize even without -mavx, causing SIGILL

hjl.tools at gmail dot com gcc-bugzilla@gcc.gnu.org
Fri Apr 15 02:52:00 GMT 2011


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48612

H.J. Lu <hjl.tools at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |hjl.tools at gmail dot com,
                   |                            |ubizjak at gmail dot com

--- Comment #1 from H.J. Lu <hjl.tools at gmail dot com> 2011-04-15 02:51:43 UTC ---
This should work:

diff --git a/gcc/config/i386/sse.md b/gcc/config/i386/sse.md
index df5e216..fabd35b 100644
--- a/gcc/config/i386/sse.md
+++ b/gcc/config/i386/sse.md
@@ -962,8 +962,8 @@
      UNSPEC_IEEE_MIN))]
   ""
   "@
-   vmin<ssemodesuffix>\t{%2, %1, %0|%0, %1, %2}
-   min<ssemodesuffix>\t{%2, %0|%0, %2}"
+   min<ssemodesuffix>\t{%2, %0|%0, %2}
+   vmin<ssemodesuffix>\t{%2, %1, %0|%0, %1, %2}"
   [(set_attr "isa" "noavx,avx")
    (set_attr "type" "sseadd")
    (set_attr "prefix" "orig,vex")
@@ -977,8 +977,8 @@
      UNSPEC_IEEE_MAX))]
   ""
   "@
-   vmax<ssemodesuffix>\t{%2, %1, %0|%0, %1, %2}
-   max<ssemodesuffix>\t{%2, %0|%0, %2}"
+   max<ssemodesuffix>\t{%2, %0|%0, %2}
+   vmax<ssemodesuffix>\t{%2, %1, %0|%0, %1, %2}"
   [(set_attr "isa" "noavx,avx")
    (set_attr "type" "sseadd")
    (set_attr "prefix" "orig,vex")



More information about the Gcc-bugs mailing list