https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117715

--- Comment #4 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Eric Botcazou <ebotca...@gcc.gnu.org>:

https://gcc.gnu.org/g:ab952929f7741998e3f28959c85e7abbf88ea79f

commit r15-5632-gab952929f7741998e3f28959c85e7abbf88ea79f
Author: Eric Botcazou <ebotca...@adacore.com>
Date:   Sun Nov 24 20:23:34 2024 +0100

    Fix vectorization regressions on the SPARC

    This fixes the vectorization regressions present on the SPARC by switching
    from vcond[u] patterns to vec_cmp[u] + vcond_mask_ patterns.  While I was
    at it, I merged the patterns for V4HI/V2SI and V8QI enabled with VIS 3/VIS
4
    to follow the model of those enabled with VIS 4B, and standardized all the
    mnemonics to the version documented in the Oracle SPARC architecture 2015.

    gcc/
            PR target/117715
            * config/sparc/sparc-protos.h (sparc_expand_vcond): Rename to...
            (sparc_expand_vcond_mask): ...this.
            * config/sparc/sparc.cc (TARGET_VECTORIZE_GET_MASK_MODE): Define.
            (sparc_vis_init_builtins): Adjust the CODE_FOR_* identifiers.
            (sparc_get_mask_mode): New function.
            (sparc_expand_vcond): Rename to...
            (sparc_expand_vcond_mask): ...this and adjust.
            * config/sparc/sparc.md (unspec): Remove UNSPEC_FCMP & UNSPEC_FUCMP
            and rename UNSPEC_FPUCMPSHL into UNSPEC_FPCMPUSHL.
            (fcmp<gcond:code><GCM:gcm_name><P:mode>_vis): Merge into...
            (fpcmp<gcond:code>8<P:mode>_vis): Merge into...
            (fpcmp<fpcmpcond:code><FPCMP:vbits><P:mode>_vis): ...this.
            (fucmp<gcond:code>8<P:mode>_vis): Merge into...
            (fpcmpu<gcond:code><GCM:gcm_name><P:mode>_vis): Merge into...
            (fpcmpu<fpcmpucond:signed_code><FPCMP:vbits><P:mode>_vis): ...this.
            (vec_cmp<FPCMP:mode><P:mode>): New expander.
            (vec_cmpu<FPCMP:mode><P:mode>): Likewise.
            (vcond<GCM:mode><GCM:mode>): Delete.
            (vcondv8qiv8qi): Likewise.
            (vcondu<GCM:mode><GCM:mode>): Likewise.
            (vconduv8qiv8qi): Likewise.
            (vcond_mask_<FPCMP:mode><P:mode>): New expander.
            (fpcmp<fpcscond:code><FPCSMODE:vbits><P:mode>shl): Adjust.
            (fpcmpu<fpcsucond:code><FPCSMODE:vbits><P:mode>shl): Likewise.
            (fpcmpde<FPCSMODE:vbits><P:mode>shl): Likewise.
            (fpcmpur<FPCSMODE:vbits><P:mode>shl): Likewise.
            * doc/md.texi (vcond_mask_len_): Fix pasto.

    gcc/testsuite/
            * gcc.target/sparc/20230328-1.c: Adjust to new mnemonics.
            * gcc.target/sparc/20230328-4.c: Likewise.
            * gcc.target/sparc/fcmp.c: Likewise.
            * gcc.target/sparc/fucmp.c: Likewise.

Reply via email to