[Bug target/97528] [9/10 Regression] ICE in decompose_automod_address, at rtlanal.c:6298 (arm-linux-gnueabihf)

cvs-commit at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Wed Feb 3 10:03:12 GMT 2021


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

--- Comment #10 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-9 branch has been updated by Andre Simoes Dias Vieira
<avieira@gcc.gnu.org>:

https://gcc.gnu.org/g:320d8676c770124a4baffab2d9e82224c74964ed

commit r9-9219-g320d8676c770124a4baffab2d9e82224c74964ed
Author: Jakub Jelinek <jakub@redhat.com>
Date:   Fri Nov 20 12:26:58 2020 +0100

    arm: Fix up neon_vector_mem_operand [PR97528]

    The documentation for POST_MODIFY says:
       Currently, the compiler can only handle second operands of the
       form (plus (reg) (reg)) and (plus (reg) (const_int)), where
       the first operand of the PLUS has to be the same register as
       the first operand of the *_MODIFY.
    The following testcase ICEs, because combine just attempts to simplify
    things and ends up with
    (post_modify (reg1) (plus (mult (reg2) (const_int 4)) (reg1))
    but the target predicates accept it, because they only verify
    that POST_MODIFY's second operand is PLUS and the second operand
    of the PLUS is a REG.

    The following patch fixes this by performing further verification that
    the POST_MODIFY is in the form it should be.

    2020-11-20  Jakub Jelinek  <jakub@redhat.com>

            PR target/97528
            * config/arm/arm.c (neon_vector_mem_operand): For POST_MODIFY,
require
            first POST_MODIFY operand is a REG and is equal to the first
operand
            of PLUS.

            * gcc.target/arm/pr97528.c: New test.

    (cherry picked from commit 410b8f6f41920dad200cd709f9f3de8b840a995c)


More information about the Gcc-bugs mailing list