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

--- Comment #4 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-12 branch has been updated by Wilco Dijkstra
<wi...@gcc.gnu.org>:

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

commit r12-9898-gbc1e385488001b0bd1a9b9c55b09ce987c31d353
Author: Wilco Dijkstra <wilco.dijks...@arm.com>
Date:   Tue Sep 26 16:42:45 2023 +0100

    AArch64: Fix memmove operand corruption [PR111121]

    A MOPS memmove may corrupt registers since there is no copy of the input
    operands to temporary registers.  Fix this by calling
    aarch64_expand_cpymem_mops.

    Reviewed-by: Richard Sandiford <richard.sandif...@arm.com>

    gcc/ChangeLog/
            PR target/111121
            * config/aarch64/aarch64.md (aarch64_movmemdi): Add new expander.
            (movmemdi): Call aarch64_expand_cpymem_mops for correct expansion.
            * config/aarch64/aarch64.cc (aarch64_expand_cpymem_mops): Add
support
            for memmove.
            * config/aarch64/aarch64-protos.h (aarch64_expand_cpymem_mops): Add
new
            function.

    gcc/testsuite/ChangeLog/
            PR target/111121
            * gcc.target/aarch64/mops_4.c: Add memmove testcases.

    (cherry picked from commit d8b56c95782aeeee79ec40932ca88d00fd9f2ee2)

Reply via email to