This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [vec-cmp, patch 6/6, i386] Add i386 support for vector comparison
- From: Kirill Yukhin <kirill dot yukhin at gmail dot com>
- To: Ilya Enkovich <enkovich dot gnu at gmail dot com>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Mon, 26 Oct 2015 17:15:33 +0300
- Subject: Re: [vec-cmp, patch 6/6, i386] Add i386 support for vector comparison
- Authentication-results: sourceware.org; auth=none
- References: <20151008153227 dot GG63757 at msticlxl57 dot ims dot intel dot com>
Hi Ilya,
On 08 Oct 18:32, Ilya Enkovich wrote:
> Hi,
>
> This patch adds patterns for vec_cmp optabs. Vector comparison expand code was moved from VEC_COND_EXPR expanders into a separate functions. AVX-512 patterns use more simple masked versions.
>
> Thanks,
> Ilya
> --
> gcc/
>
> 2015-10-08 Ilya Enkovich <enkovich.gnu@gmail.com>
>
> * config/i386/i386-protos.h (ix86_expand_mask_vec_cmp): New.
> (ix86_expand_int_vec_cmp): New.
> (ix86_expand_fp_vec_cmp): New.
> * config/i386/i386.c (ix86_expand_sse_cmp): Allow NULL for
> op_true and op_false.
> (ix86_int_cmp_code_to_pcmp_immediate): New.
> (ix86_fp_cmp_code_to_pcmp_immediate): New.
> (ix86_cmp_code_to_pcmp_immediate): New.
> (ix86_expand_mask_vec_cmp): New.
> (ix86_expand_fp_vec_cmp): New.
> (ix86_expand_int_sse_cmp): New.
> (ix86_expand_int_vcond): Use ix86_expand_int_sse_cmp.
> (ix86_expand_fp_vcond): Use ix86_expand_sse_cmp.
> (ix86_expand_int_vec_cmp): New.
> (ix86_get_mask_mode): New.
> (TARGET_VECTORIZE_GET_MASK_MODE): New.
> * config/i386/sse.md (avx512fmaskmodelower): New.
> (vec_cmp<mode><avx512fmaskmodelower>): New.
> (vec_cmp<mode><sseintvecmodelower>): New.
> (vec_cmpv2div2di): New.
> (vec_cmpu<mode><avx512fmaskmodelower>): New.
> (vec_cmpu<mode><sseintvecmodelower>): New.
> (vec_cmpuv2div2di): New.
Patch is OK for trunk.
(Although vec_cmp and vec_cmpu might be merged w/ susbst).
--
Thanks, K