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

--- Comment #16 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The trunk branch has been updated by Andrew Pinski <pins...@gcc.gnu.org>:

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

commit r15-2700-gda33ad53bcb57943fa671c745938a53f4de89a1b
Author: Andrew Pinski <quic_apin...@quicinc.com>
Date:   Thu Aug 1 14:22:36 2024 -0700

    genemit: Fix handling of explicit parallels for clobbers [PR116058]

    In a define_insn, you could use either an explicit parallel for
    the insns or genrecog/genemit will add one for you.
    The problem when genemit is processing the pattern for clobbers
    (to create the function add_clobbers), genemit hadn't add the implicit
    parallel yet but at the same time forgot to ignore that there
    could be an explicit parallel there.
    This means in some cases (like in the sh backend), add_clobbers
    and recog had a different idea if there was clobbers on the insn.
    This fixes the problem by looking through the explicit parallel
    for the instruction in genemit.

    Bootstrapped and tested on x86_64-linux-gnu.

            PR middle-end/116058

    gcc/ChangeLog:

            * genemit.cc (struct clobber_pat): Change pattern to be rtvec.
            Add code field.
            (gen_insn): Look through an explicit parallel if there was one.
            Update store to new clobber_pat.
            (output_add_clobbers): Update call to gen_exp for the changed
            clobber_pat.

    Signed-off-by: Andrew Pinski <quic_apin...@quicinc.com>

Reply via email to