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 rtl-optimization/98037] ICE in dse.c:find_shift_sequence for large non-integer modes
Date: Mon, 30 Nov 2020 17:16:09 +0000	[thread overview]
Message-ID: <bug-98037-4-DQNuQEKxyx@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-98037-4@http.gcc.gnu.org/bugzilla/>

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

--- Comment #1 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Richard Sandiford <rsandifo@gcc.gnu.org>:

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

commit r11-5580-gf835e9f6562dda9c8a1384be2c9d4e45c112ed8e
Author: Richard Sandiford <richard.sandiford@arm.com>
Date:   Mon Nov 30 17:15:47 2020 +0000

    dse: Cope with bigger-than-integer modes [PR98037]

    dse.c:find_shift_sequence tries to represent a store and load
    back as a shift right followed by a truncation.  It therefore
    needs to find an integer mode in which to do the shift right.
    The loop it uses has the form:

      FOR_EACH_MODE_FROM (new_mode_iter,
                          smallest_int_mode_for_size (GET_MODE_BITSIZE
(read_mode)))

    which implicitly assumes that read_mode has an equivalent integer mode.
    As shown in the testcase, not all modes have such an integer mode.

    This patch just makes the code start from the smallest integer mode and
    skip modes that are too small.  The loop already breaks at the first
    mode wider than word_mode.

    gcc/
            PR rtl-optimization/98037
            * dse.c (find_shift_sequence): Iterate over all integers and
            skip modes that are too small.

    gcc/testsuite/
            PR rtl-optimization/98037
            * gcc.target/aarch64/sve/acle/general/pr98037.c: New test.

  parent reply	other threads:[~2020-11-30 17:16 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-11-27 16:41 [Bug rtl-optimization/98037] New: " rsandifo at gcc dot gnu.org
2020-11-27 16:41 ` [Bug rtl-optimization/98037] " rsandifo at gcc dot gnu.org
2020-11-30 17:16 ` cvs-commit at gcc dot gnu.org [this message]
2020-12-02 16:21 ` cvs-commit at gcc dot gnu.org
2020-12-02 18:41 ` rsandifo 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-98037-4-DQNuQEKxyx@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).