r333509 - [X86] Remove masking from the AVX512VNNI builtins. Use a select in IR instead.

Hans Wennborg via cfe-commits cfe-commits at lists.llvm.org
Wed May 30 01:12:34 PDT 2018


On Wed, May 30, 2018 at 7:26 AM, Craig Topper via cfe-commits
<cfe-commits at lists.llvm.org> wrote:
> Author: ctopper
> Date: Tue May 29 22:26:04 2018
> New Revision: 333509
>
> URL: http://llvm.org/viewvc/llvm-project?rev=333509&view=rev
> Log:
> [X86] Remove masking from the AVX512VNNI builtins. Use a select in IR instead.
>
> Modified:
>     cfe/trunk/include/clang/Basic/BuiltinsX86.def
>     cfe/trunk/lib/Headers/avx512vlvnniintrin.h
>     cfe/trunk/lib/Headers/avx512vnniintrin.h
>     cfe/trunk/test/CodeGen/avx512vlvnni-builtins.c
>     cfe/trunk/test/CodeGen/avx512vnni-builtins.c

[...]

> --- cfe/trunk/lib/Headers/avx512vlvnniintrin.h (original)
> +++ cfe/trunk/lib/Headers/avx512vlvnniintrin.h Tue May 29 22:26:04 2018

[...]

>  static __inline__ __m256i __DEFAULT_FN_ATTRS
>  _mm256_maskz_dpbusds_epi32(__mmask8 __U, __m256i __S, __m256i __A, __m256i __B)
>  {
> -  return (__m256i) __builtin_ia32_vpdpbusds256_maskz ((__v8si) __S,
> -              (__v8si) __A,
> -              (__v8si) __B,
> -              (__mmask8) __U);
> -}

Oops :-) Missing curly added back in r333515 to make the bots happier.

> +  return (__m256i)__builtin_ia32_selectd_256(__U,
> +                                     (__v8si)_mm256_dpbusds_epi32(__S, __A, __B),
> +                                     (__v8si)_mm256_setzero_si256());
> +


More information about the cfe-commits mailing list