i386.md ("isa" attribute): Add sse_noavx.
authorUros Bizjak <ubizjak@gmail.com>
Mon, 1 Jul 2019 18:41:09 +0000 (20:41 +0200)
committerUros Bizjak <uros@gcc.gnu.org>
Mon, 1 Jul 2019 18:41:09 +0000 (20:41 +0200)
* config/i386/i386.md ("isa" attribute): Add sse_noavx.
("enabled" attribute): Handle sse_noavx isa attribute.
* config/i386/mmx.md (*vec_dupv2sf): Add "isa" attribute.
Use TARGET_SSE && SSE_REGNO_P in split condition.
(*vec_dupv2sf): Ditto.

From-SVN: r272902

gcc/ChangeLog
gcc/config/i386/i386.md
gcc/config/i386/mmx.md

index bd4c8c5de09157368749b0107922d4be7ca9bf75..fd2ebf11281278dae473343ad949ca34a580f026 100644 (file)
@@ -1,3 +1,11 @@
+2019-07-01  Uroš Bizjak  <ubizjak@gmail.com>
+
+       * config/i386/i386.md ("isa" attribute): Add sse_noavx.
+       ("enabled" attribute): Handle sse_noavx isa attribute.
+       * config/i386/mmx.md (*vec_dupv2sf): Add "isa" attribute.
+       Use TARGET_SSE && SSE_REGNO_P in split condition.
+       (*vec_dupv2sf): Ditto.
+
 2019-07-01  Segher Boessenkool  <segher@kernel.crashing.org>
 
        * config/rs6000/rs6000.md (extenddf<mode>2_fprs): Make this a
index c362a72411a2b73d187676634b4aedad6ebfe94e..c401deb5eb008afbffa4cb04dac18b3c2d79cbf0 100644 (file)
 
 ;; Used to control the "enabled" attribute on a per-instruction basis.
 (define_attr "isa" "base,x64,x64_sse2,x64_sse4,x64_sse4_noavx,x64_avx,nox64,
-                   sse2,sse2_noavx,sse3,sse4,sse4_noavx,avx,noavx,
+                   sse_noavx,sse2,sse2_noavx,sse3,sse4,sse4_noavx,avx,noavx,
                    avx2,noavx2,bmi,bmi2,fma4,fma,avx512f,noavx512f,
                    avx512bw,noavx512bw,avx512dq,noavx512dq,
                    avx512vl,noavx512vl,x64_avx512dq,x64_avx512bw"
           (symbol_ref "TARGET_64BIT && TARGET_AVX512BW")
         (eq_attr "isa" "nox64") (symbol_ref "!TARGET_64BIT")
         (eq_attr "isa" "sse2") (symbol_ref "TARGET_SSE2")
+        (eq_attr "isa" "sse_noavx")
+          (symbol_ref "TARGET_SSE && !TARGET_AVX")
         (eq_attr "isa" "sse2_noavx")
           (symbol_ref "TARGET_SSE2 && !TARGET_AVX")
         (eq_attr "isa" "sse3") (symbol_ref "TARGET_SSE3")
index 70413349390c6d2c6d5ad1c4e9984dd6ea042bb7..9ff86ba0eecc55096774a16ebbc2b490d397cda5 100644 (file)
    punpckldq\t%0, %0
    #
    #"
-  "TARGET_MMX_WITH_SSE && reload_completed"
+  "TARGET_SSE && reload_completed
+   && SSE_REGNO_P (REGNO (operands[0]))"
   [(set (match_dup 0)
        (vec_duplicate:V4SF (match_dup 1)))]
-  "operands[0] = lowpart_subreg (V4SFmode, operands[0],
-                                GET_MODE (operands[0]));"
-  [(set_attr "mmx_isa" "native,sse_noavx,avx")
+{
+  operands[0] = lowpart_subreg (V4SFmode, operands[0],
+                               GET_MODE (operands[0]));
+}
+  [(set_attr "isa" "*,sse_noavx,avx")
+   (set_attr "mmx_isa" "native,*,*")
    (set_attr "type" "mmxcvt,ssemov,ssemov")
    (set_attr "mode" "DI,TI,TI")])
 
    #
    #
    #"
-  "TARGET_MMX_WITH_SSE && reload_completed"
+  "TARGET_SSE && reload_completed
+   && SSE_REGNO_P (REGNO (operands[0]))"
   [(set (match_dup 0)
        (vec_duplicate:V4SI (match_dup 1)))]
-  "operands[0] = lowpart_subreg (V4SImode, operands[0],
-                                GET_MODE (operands[0]));"
-  [(set_attr "mmx_isa" "native,sse_noavx,avx,avx")
+{
+  operands[0] = lowpart_subreg (V4SImode, operands[0],
+                               GET_MODE (operands[0]));
+}
+  [(set_attr "isa" "*,sse_noavx,avx,avx")
+   (set_attr "mmx_isa" "native,*,*,*")
    (set_attr "type" "mmxcvt,ssemov,ssemov,ssemov")
    (set_attr "mode" "DI,TI,TI,TI")])