From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id B2F123858415; Wed, 15 Dec 2021 05:25:56 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org B2F123858415 From: "cvs-commit at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug middle-end/100843] [12 Regression] ICE with -O1: in try_store_by_multiple_pieces, at builtins.c:6739 since r12-397-gda9e6e63d1ae22e530ec7baf59f6ed028bf05776 Date: Wed, 15 Dec 2021 05:25:56 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: middle-end X-Bugzilla-Version: 12.0 X-Bugzilla-Keywords: ice-on-valid-code X-Bugzilla-Severity: normal X-Bugzilla-Who: cvs-commit at gcc dot gnu.org X-Bugzilla-Status: ASSIGNED X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: aoliva at gcc dot gnu.org X-Bugzilla-Target-Milestone: 12.0 X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: gcc-bugs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-bugs mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Dec 2021 05:25:56 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D100843 --- Comment #5 from CVS Commits --- The master branch has been updated by Alexandre Oliva : https://gcc.gnu.org/g:c95a9f1ee7ebd461cbced455271a993bae3a42b6 commit r12-5983-gc95a9f1ee7ebd461cbced455271a993bae3a42b6 Author: Alexandre Oliva Date: Wed Dec 15 02:22:33 2021 -0300 [PR100843] store by mult pieces: punt on max_len < min_len The testcase confuses the code that detects min and max len for the memset, so max_len ends up less than min_len. That shouldn't be possible, but the testcase requires us to handle this case. The store-by-mult-pieces algorithm actually relies on min and max lengths, so if we find them to be inconsistent, the best we can do is punting. for gcc/ChangeLog PR middle-end/100843 * builtins.c (try_store_by_multiple_pieces): Fail if min_len is greater than max_len. for gcc/testsuite/ChangeLog PR middle-end/100843 * gcc.dg/pr100843.c: New.=