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

--- Comment #3 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Jakub Jelinek <ja...@gcc.gnu.org>:

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

commit r16-3386-gd551f88f88b821dc80de9d39c5b275a3678b3e31
Author: Jakub Jelinek <ja...@redhat.com>
Date:   Tue Aug 26 06:43:39 2025 +0200

    i386: Fix up recent changes to use GFNI for rotates/shifts [PR121658]

    The vgf2p8affineqb_<mode><mask_name> pattern uses "register_operand"
    predicate for the first input operand, so using "general_operand"
    for the rotate operand passed to it leads to ICEs, and so does
    the "nonimmediate_operand" in the <insn>v16qi3 define_expand.
    The following patch fixes it by using "register_operand" in the former
    case (that pattern is TARGET_GFNI only) and using force_reg in
    the latter case (the pattern is TARGET_XOP || TARGET_GFNI and for XOP
    we can handle MEM operand).

    The rest of the changes are small formatting tweaks or use of const0_rtx
    instead of GEN_INT (0).

    2025-08-26  Jakub Jelinek  <ja...@redhat.com>

            PR target/121658
            * config/i386/sse.md (<insn><mode>3 any_shift): Use const0_rtx
            instead of GEN_INT (0).
            (cond_<insn><mode> any_shift): Likewise.  Formatting fix.
            (<insn><mode>3 any_rotate): Use register_operand predicate instead
of
            general_operand for match_operand 1.  Use const0_rtx instead of
            GEN_INT (0).
            (<insn>v16qi3 any_rotate): Use force_reg on operands[1]. 
Formatting
            fix.
            * config/i386/i386.cc (ix86_shift_rotate_cost): Comment formatting
            fixes.

            * gcc.target/i386/pr121658.c: New test.

Reply via email to