From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 7A727385783A; Thu, 11 Feb 2021 15:49:00 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 7A727385783A From: "rguenth at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug rtl-optimization/96264] [10/11 Regression] wrong code with -Os -fno-forward-propagate -fschedule-insns -fno-tree-ter Date: Thu, 11 Feb 2021 15:49:00 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: rtl-optimization X-Bugzilla-Version: 11.0 X-Bugzilla-Keywords: wrong-code X-Bugzilla-Severity: normal X-Bugzilla-Who: rguenth at gcc dot gnu.org X-Bugzilla-Status: NEW X-Bugzilla-Resolution: X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: 10.3 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: Thu, 11 Feb 2021 15:49:00 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D96264 --- Comment #6 from Richard Biener --- (In reply to seurer from comment #5) > I too am able to duplicate this on a native powerpc64 LE machine. Changi= ng > any of the compilation options (-Os -fno-forward-propagate -fschedule-ins= ns > -fno-tree-ter) generates code that works. >=20 > The revision that causes it is: >=20 > g:a7eb97ad269b6509bd7b31ca373daea98e4d7e85, r10-135 >=20 > commit a7eb97ad269b6509bd7b31ca373daea98e4d7e85 (HEAD) > Author: Richard Biener > Date: Fri May 3 10:39:56 2019 +0000 >=20 > re PR middle-end/88963 (gcc generates terrible code for vectors of 64+ > length which are not natively supported) >=20=20=20=20=20 > 2019-05-03 Richard Biener >=20=20=20=20=20 > PR tree-optimization/88963 > * tree-ssa-forwprop.c (pass_forwprop::execute): Rewrite > vector loads feeding only BIT_FIELD_REFs to component > loads. Rewrite stores fed by CONSTRUCTORs to component > stores. >=20=20=20=20=20 > * gcc.dg/tree-ssa/ssa-fre-31.c: Disable forwprop. > * gcc.target/i386/pr88963-1.c: New testcase. > * gcc.target/i386/pr88963-2.c: Likewise. >=20=20=20=20=20 > From-SVN: r270844 >=20 > I compared the assembler output from r10-134 and r10-135 for the test case > and the differences are significant. Assembler output of the two revisio= ns > attached. Note -fno-forward-propagate is an RTL optimization so if enabling that fixes the issue the issue cannot really be the above rev. but it's probably expos= ed by it only. Note this is only done for vector load/stores using BLKmode. Somebody needs to look at the RTL details to see what's the difference with RTL fwprop or scheduling for example (at least for scheduling there are existing dbg-counters that might help pointing to the breaking (non-)transf= orm)=