From 06046046916eaab671caf56f6da8f4db8664d005 Mon Sep 17 00:00:00 2001 From: Jakub Jelinek Date: Mon, 2 Jan 2012 14:59:32 +0100 Subject: [PATCH] sse.md (*avx2_gatherdi_3, [...]): New patterns. * config/i386/sse.md (*avx2_gatherdi_3, *avx2_gatherdi_4): New patterns. From-SVN: r182802 --- gcc/ChangeLog | 5 +++++ gcc/config/i386/sse.md | 48 +++++++++++++++++++++++++++++++++++++++++- 2 files changed, 52 insertions(+), 1 deletion(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 4cdef41ddcaa..7b018cb9f5e6 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2012-01-02 Jakub Jelinek + + * config/i386/sse.md (*avx2_gatherdi_3, *avx2_gatherdi_4): + New patterns. + 2012-01-02 Richard Sandiford * expr.h (move_by_pieces_ninsns): Declare. diff --git a/gcc/config/i386/sse.md b/gcc/config/i386/sse.md index 2d248aae2c7b..d07069de5cb6 100644 --- a/gcc/config/i386/sse.md +++ b/gcc/config/i386/sse.md @@ -1,5 +1,5 @@ ;; GCC machine description for SSE instructions -;; Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2011 +;; Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012 ;; Free Software Foundation, Inc. ;; ;; This file is part of GCC. @@ -12834,3 +12834,49 @@ [(set_attr "type" "ssemov") (set_attr "prefix" "vex") (set_attr "mode" "")]) + +(define_insn "*avx2_gatherdi_3" + [(set (match_operand: 0 "register_operand" "=&x") + (vec_select: + (unspec:VI4F_256 + [(match_operand: 2 "register_operand" "0") + (match_operator: 7 "vsib_mem_operator" + [(unspec:P + [(match_operand:P 3 "vsib_address_operand" "p") + (match_operand: 4 "register_operand" "x") + (match_operand:SI 6 "const1248_operand" "n")] + UNSPEC_VSIBADDR)]) + (mem:BLK (scratch)) + (match_operand: 5 "register_operand" "1")] + UNSPEC_GATHER) + (parallel [(const_int 0) (const_int 1) + (const_int 2) (const_int 3)]))) + (clobber (match_scratch:VI4F_256 1 "=&x"))] + "TARGET_AVX2" + "vgatherq\t{%5, %7, %0|%0, %7, %5}" + [(set_attr "type" "ssemov") + (set_attr "prefix" "vex") + (set_attr "mode" "")]) + +(define_insn "*avx2_gatherdi_4" + [(set (match_operand: 0 "register_operand" "=&x") + (vec_select: + (unspec:VI4F_256 + [(pc) + (match_operator: 6 "vsib_mem_operator" + [(unspec:P + [(match_operand:P 2 "vsib_address_operand" "p") + (match_operand: 3 "register_operand" "x") + (match_operand:SI 5 "const1248_operand" "n")] + UNSPEC_VSIBADDR)]) + (mem:BLK (scratch)) + (match_operand: 4 "register_operand" "1")] + UNSPEC_GATHER) + (parallel [(const_int 0) (const_int 1) + (const_int 2) (const_int 3)]))) + (clobber (match_scratch:VI4F_256 1 "=&x"))] + "TARGET_AVX2" + "vgatherq\t{%4, %6, %0|%0, %6, %4}" + [(set_attr "type" "ssemov") + (set_attr "prefix" "vex") + (set_attr "mode" "")]) -- 2.47.3