On Tue, Jun 20, 2023 at 5:34 PM Hongtao Liu <crazy...@gmail.com> wrote:
>
> On Tue, Jun 20, 2023 at 5:03 PM Jan Beulich <jbeul...@suse.com> wrote:
> >
> > On 20.06.2023 10:33, Hongtao Liu wrote:
> > > On Tue, Jun 20, 2023 at 3:07 PM Jan Beulich via Gcc-patches
> > > <gcc-patches@gcc.gnu.org> wrote:
> > >>
> > >> I guess the underlying pattern, going along the lines of what
> > >> <mask_codefor>one_cmpl<mode>2<mask_name> uses, can be applied elsewhere
> > >> as well.
> > > That should be guarded with !TARGET_PREFER_AVX256, let's handle that
> > > in a separate patch.
> >
> > Sure, and as indicated there are more places where similar things could
> > be done.
> >
> > >> --- /dev/null
> > >> +++ b/gcc/testsuite/gcc.target/i386/avx512f-copysign.c
> > >> @@ -0,0 +1,32 @@
> > >> +/* { dg-do compile } */
> > >> +/* { dg-options "-mavx512f -mno-avx512vl -O2" } */
> > > Please explicitly add -mprefer-vector-width=512, our tester will also
> > > test unix{-m32 \-march=cascadelake,\ -march=cascadelake} which set the
> > > - mprefer-vector-width=256, -mprefer-vector-width=512 in dg-options
> > > can overwrite that.
> >
> > Oh, I see. Will do. And I expect I then also need to adjust the newly
> > added avx512f-dupv2di.c from the earlier patch. I guess I could commit
> > that option addition there as obvious?
> Still need to send out the patch, and commit as an obvious fix.
> >
> > > Others LGTM.
> >
> > May I take this as "okay with that change", or should I submit v4?
> Okay. no need for a v4 version.
> >
avx512f-copysign.c failed for -m32, we need to add -mfpmath=sse to dg-options.

cs_df:
.LFB0:
        .cfi_startproc
        fldl    12(%esp)
        fxam
        fnstsw  %ax
        fstp    %st(0)
        fldl    4(%esp)
        fabs
        testb   $2, %ah
        je      .L1
        fchs
.L1:
        ret
        .cfi_endproc
.LFE0:
        .size   cs_df, .-cs_df
        .p2align 4
        .globl  cs_sf
        .type   cs_sf, @function
cs_sf:
.LFB1:
        .cfi_startproc
        flds    8(%esp)
        fxam
        fnstsw  %ax
        fstp    %st(0)
        flds    4(%esp)
        testb   $2, %ah
        fabs
        fld     %st(0)
        fchs
        fcmove  %st(1), %st
        fstp    %st(1)
        ret
        .cfi_endproc
.LFE1:
        .size   cs_sf, .-cs_sf
        .p2align 4
        .globl  cs_v2df
        .type   cs_v2df, @function

> > Jan
>
>
>
> --
> BR,
> Hongtao



-- 
BR,
Hongtao

Reply via email to