public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH i386 AVX512] [24/n] Add integer max/min.
@ 2014-08-27 12:16 Kirill Yukhin
  2014-08-27 15:16 ` Uros Bizjak
  0 siblings, 1 reply; 2+ messages in thread
From: Kirill Yukhin @ 2014-08-27 12:16 UTC (permalink / raw)
  To: Uros Bizjak; +Cc: Jakub Jelinek, Richard Henderson, GCC Patches, kirill.yukhin

Hello,
This patch introduces integer max/min AVX-512 pattern.

Bootstrapped.
AVX-512* tests on top of patch-set all pass
under simulator.

Is it ok for trunk?

gcc/
	* config/i386/sse.md
	(define_mode_iterator VI128_256): New.
	(define_insn "<mask_codefor><code><mode>3<mask_name>"): Ditto.

--
Thanks, K

diff --git a/gcc/config/i386/sse.md b/gcc/config/i386/sse.md
index 5904450..6c99d84 100644
--- a/gcc/config/i386/sse.md
+++ b/gcc/config/i386/sse.md
@@ -281,6 +281,9 @@
 (define_mode_iterator VI8_256_512
   [V8DI (V4DI "TARGET_AVX512VL")])
 
+(define_mode_iterator VI128_256
+  [V4DI V2DI V4SI (V16QI "TARGET_AVX512BW") (V8HI "TARGET_AVX512BW")])
+
 (define_mode_iterator VI1_AVX2
   [(V32QI "TARGET_AVX2") V16QI])
 
@@ -8922,6 +8925,17 @@
    (set_attr "prefix" "maybe_evex")
    (set_attr "mode" "OI")])
 
+(define_insn "<mask_codefor><code><mode>3<mask_name>"
+  [(set (match_operand:VI128_256 0 "register_operand" "=v")
+        (maxmin:VI128_256
+          (match_operand:VI128_256 1 "register_operand" "v")
+          (match_operand:VI128_256 2 "nonimmediate_operand" "vm")))]
+  "TARGET_AVX512VL"
+  "vp<maxmin_int><ssemodesuffix>\t{%2, %1, %0<mask_operand3>|%0<mask_operand3>, %1, %2}"
+  [(set_attr "type" "sseiadd")
+   (set_attr "prefix" "evex")
+   (set_attr "mode" "<sseinsnmode>")])
+
 (define_expand "<code><mode>3"
   [(set (match_operand:VI8_AVX2 0 "register_operand")
 	(maxmin:VI8_AVX2

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH i386 AVX512] [24/n] Add integer max/min.
  2014-08-27 12:16 [PATCH i386 AVX512] [24/n] Add integer max/min Kirill Yukhin
@ 2014-08-27 15:16 ` Uros Bizjak
  0 siblings, 0 replies; 2+ messages in thread
From: Uros Bizjak @ 2014-08-27 15:16 UTC (permalink / raw)
  To: Kirill Yukhin; +Cc: Jakub Jelinek, Richard Henderson, GCC Patches

On Wed, Aug 27, 2014 at 2:16 PM, Kirill Yukhin <kirill.yukhin@gmail.com> wrote:

> This patch introduces integer max/min AVX-512 pattern.
>
> Bootstrapped.
> AVX-512* tests on top of patch-set all pass
> under simulator.
>
> Is it ok for trunk?
>
> gcc/
>         * config/i386/sse.md
>         (define_mode_iterator VI128_256): New.
>         (define_insn "<mask_codefor><code><mode>3<mask_name>"): Ditto.

OK.

Thanks,
Uros.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2014-08-27 15:16 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-08-27 12:16 [PATCH i386 AVX512] [24/n] Add integer max/min Kirill Yukhin
2014-08-27 15:16 ` Uros Bizjak

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).