On Tue, Aug 26, 2014 at 9:55 PM, Kirill Yukhin <kirill.yuk...@gmail.com> wrote:
> Hello Uroš,
> On 23 Aug 09:44, Uros Bizjak wrote:
>> On Fri, Aug 22, 2014 at 1:51 PM, Kirill Yukhin <kirill.yuk...@gmail.com> 
>> wrote:
>>
>> > This patch extends unaligned loads and stores patterns.
>> At this stage, I'd still prefer simple constraints (the solution,
>> proposed above), even for the price of additional patterns. Looking at
>> the patterns, it is quite hard to calculate final condition for the
>> particular mode/target combo, even without enable attribute and
>> conditional operand constraints/predicates. With the solution above,
>> the complexity is conveniently pushed to mask define_subst attribute.
> In the bottom patch which splits unaligned ld/st patterns.
> Bootstrapped and avx512-regtested on simulator.
>
> gcc/
>         * config/i386/sse.md
>         (define_mode_iterator VI48_AVX512VL): New.
>         (define_mode_iterator VI_UNALIGNED_LOADSTORE): Delete.
>         (define_mode_iterator VI_ULOADSTORE_AVX512BW): New.
>         (define_mode_iterator VI_ULOADSTORE_AVX512F): Ditto.
>         (define_expand "<sse2_avx_avx512f>_loaddqu<mode><mask_name>"
>         with VI1): Change mode iterator.
>         (define_expand "<sse2_avx_avx512f>_loaddqu<mode><mask_name>"
>         with VI_ULOADSTORE_AVX512BW): New.
>         (define_expand "<sse2_avx_avx512f>_loaddqu<mode><mask_name>"
>         with VI_ULOADSTORE_AVX512F): Ditto.
>         (define_insn "*<sse2_avx_avx512f>_loaddqu<mode><mask_name>"
>         with VI1): Change mode iterator.
>         (define_insn "*<sse2_avx_avx512f>_loaddqu<mode><mask_name>"
>         with VI_ULOADSTORE_AVX512BW): New.
>         (define_insn "*<sse2_avx_avx512f>_loaddqu<mode><mask_name>"
>         with VI_ULOADSTORE_AVX512F): Ditto.
>         (define_insn "<sse2_avx_avx512f>_storedqu<mode>
>         with VI1): Change mode iterator.
>         (define_insn "<sse2_avx_avx512f>_storedqu<mode>
>         with VI_ULOADSTORE_AVX512BW): New.
>         (define_insn "<sse2_avx_avx512f>_storedqu<mode>
>         with VI_ULOADSTORE_AVX512F): Ditto.
>         (define_insn "avx512f_storedqu<mode>_mask"): Delete.
>         (define_insn "<avx512>_storedqu<mode>_mask" with
>         VI48_AVX512VL): New.
>         (define_insn "<avx512>_storedqu<mode>_mask" with
>         VI12_AVX512VL): Ditto.
>
> Is it ok for trunk?

OK with a renamed mode iterator as suggested below.

Thanks,
Uros.


> -(define_mode_iterator VI_UNALIGNED_LOADSTORE
> -  [(V32QI "TARGET_AVX") V16QI
> -   (V16SI "TARGET_AVX512F") (V8DI "TARGET_AVX512F")])
> +(define_mode_iterator VI_ULOADSTORE_AVX512BW
> +  [V64QI
> +   V32HI (V8HI "TARGET_AVX512VL") (V16HI "TARGET_AVX512VL")])
> +
> +(define_mode_iterator VI_ULOADSTORE_AVX512F
> +  [V16SI (V8SI "TARGET_AVX512VL") (V4SI "TARGET_AVX512VL")
> +   V8DI (V4DI "TARGET_AVX512VL") (V2DI "TARGET_AVX512VL")])

Please name these two VI_ULOADSTORE_BW_AVX512VL and
VI_ULOADSTORE_F_AVX512VL to be consistent with other names and put
these nearby loadstore patterns.

Reply via email to