public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "cvs-commit at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug target/109800] [11 Regression] arm: ICE (segfault) loading double with -mpure-code -mbig-endian
Date: Fri, 09 Jun 2023 11:18:07 +0000	[thread overview]
Message-ID: <bug-109800-4-uldq0wtXI2@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-109800-4@http.gcc.gnu.org/bugzilla/>

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

--- Comment #5 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-11 branch has been updated by Alex Coplan
<acoplan@gcc.gnu.org>:

https://gcc.gnu.org/g:2d3b72cbbfe7fb38b0e3b8ef2119156cbce57488

commit r11-10852-g2d3b72cbbfe7fb38b0e3b8ef2119156cbce57488
Author: Alex Coplan <alex.coplan@arm.com>
Date:   Thu May 25 13:34:46 2023 +0100

    arm: Fix ICE due to infinite splitting [PR109800]

    In r11-966-g9a182ef9ee011935d827ab5c6c9a7cd8e22257d8 we introduce a
    simplification to emit_move_insn that attempts to simplify moves of the
form:

    (set (subreg:M1 (reg:M2 ...)) (constant C))

    where M1 and M2 are of equal mode size. That is problematic for the
splitter
    vfp.md:no_literal_pool_df_immediate in the arm backend, which tries to pun
an
    lvalue DFmode pseudo into DImode and assign a constant to it with
    emit_move_insn, as the new transformation simply undoes this, and we end up
    splitting indefinitely.

    This patch changes things around in the arm backend so that we use a
    DImode temporary (instead of DFmode) and first load the DImode constant
    into the pseudo, and then pun the pseudo into DFmode as an rvalue in a
    reg -> reg move. I believe this should be semantically equivalent but
    avoids the pathalogical behaviour seen in the PR.

    gcc/ChangeLog:

            PR target/109800
            * config/arm/arm.md (movdf): Generate temporary pseudo in DImode
            instead of DFmode.
            * config/arm/vfp.md (no_literal_pool_df_immediate): Rather than
punning an
            lvalue DFmode pseudo into DImode, use a DImode pseudo and pun it
into
            DFmode as an rvalue.

    gcc/testsuite/ChangeLog:

            PR target/109800
            * gcc.target/arm/pure-code/pr109800.c: New test.

    (cherry picked from commit f5298d9969b4fa34ff3aecd54b9630e22b2984a5)

  parent reply	other threads:[~2023-06-09 11:18 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-10 16:32 [Bug target/109800] New: [11/12/13/14 " acoplan at gcc dot gnu.org
2023-05-11  6:25 ` [Bug target/109800] " rguenth at gcc dot gnu.org
2023-05-11 11:21 ` acoplan at gcc dot gnu.org
2023-05-25 12:35 ` cvs-commit at gcc dot gnu.org
2023-05-29 10:08 ` jakub at gcc dot gnu.org
2023-06-07 14:12 ` cvs-commit at gcc dot gnu.org
2023-06-08 17:31 ` [Bug target/109800] [11/12 " cvs-commit at gcc dot gnu.org
2023-06-09 11:18 ` cvs-commit at gcc dot gnu.org [this message]
2023-06-09 11:19 ` [Bug target/109800] [11 " acoplan at gcc dot gnu.org

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bug-109800-4-uldq0wtXI2@http.gcc.gnu.org/bugzilla/ \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).