From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 7DE163894C35; Wed, 7 Apr 2021 02:29:41 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 7DE163894C35 From: "cvs-commit at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug tree-optimization/98736] [10/11 Regression] Wrong partition order generated in loop distribution pass since r10-619-g5879ab5fafedc8f6 Date: Wed, 07 Apr 2021 02:29:41 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: tree-optimization X-Bugzilla-Version: 11.0 X-Bugzilla-Keywords: wrong-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: P2 X-Bugzilla-Assigned-To: amker 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: Wed, 07 Apr 2021 02:29:41 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D98736 --- Comment #5 from CVS Commits --- The master branch has been updated by Bin Cheng : https://gcc.gnu.org/g:e0bdccac582c01c928a05f26edcd8f5ac24669eb commit r11-8023-ge0bdccac582c01c928a05f26edcd8f5ac24669eb Author: Bin Cheng Date: Wed Apr 7 10:24:32 2021 +0800 tree-optimization/98736 - use programing order preserved RPO in ldist Tree loop distribution uses RPO to build reduced dependence graph, it's important that RPO preserves the original programing order. Though it usually does so, when distributing loop nest, exit BB can be placed before some loop BBs while after loop header. This patch fixes the issue by calling rev_post_order_and_mark_dfs_back_seme. gcc/ChangeLog: PR tree-optimization/98736 * tree-loop-distribution.c * (loop_distribution::bb_top_order_init): Compute RPO with programing order preserved by calling function rev_post_order_and_mark_dfs_back_seme. gcc/testsuite/ChangeLog: PR tree-optimization/98736 * gcc.c-torture/execute/pr98736.c: New test.=