From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 16505 invoked by alias); 2 Nov 2011 05:51:24 -0000 Received: (qmail 16494 invoked by uid 22791); 2 Nov 2011 05:51:21 -0000 X-SWARE-Spam-Status: No, hits=-2.9 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00 X-Spam-Check-By: sourceware.org Received: from localhost (HELO gcc.gnu.org) (127.0.0.1) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 02 Nov 2011 05:51:08 +0000 From: "venkataramanan.kumar.gnu at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug rtl-optimization/50904] Induct benchmark of polyhedron slows down when -fno-protect-parens is enabled by -Ofast. Date: Wed, 02 Nov 2011 05:51: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-Keywords: missed-optimization X-Bugzilla-Severity: normal X-Bugzilla-Who: venkataramanan.kumar.gnu at gmail dot com X-Bugzilla-Status: NEW X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated Content-Type: text/plain; charset="UTF-8" MIME-Version: 1.0 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2011-11/txt/msg00087.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50904 --- Comment #7 from Venkataramanan Kumar 2011-11-02 05:50:44 UTC --- (In reply to comment #6) > > I don't see why RTL invariant motion should move the one variant but not > > the other. Of course this also shows that we should, after loop unrolling > > on the tree level, also perform loop invariant motion again ... > The problem seems to be in RTL PRE, which hoists simple loads but not loads > that are wrapped up in a PLUS or a MINUS. Even with -fprotect-parens, load > hoisting opportunities are lost because of this. You mean to say PRE hosits the when expression of this pattern. (Snip) (insn 536 533 537 14 (set (reg:V2DF 1172 [ MEM[(real(kind=8)[9] *)&y2gauss] ]) (mem/c:V2DF (symbol_ref:DI ("y2gauss.2335") [flags 0x2] ) [8 MEM[(real(kind=8)[9] *)&y2gauss]+0 S16 A256])) induct2.f90:1662 1102 {*movv2df_internal} (Snip) But not of this pattern. (Snip) (insn 526 525 527 14 (set (reg:V2DF 1123) (plus:V2DF (reg:V2DF 1124) (mem/c:V2DF (symbol_ref:DI ("y2gauss.2335") [flags 0x2] ) [8 MEM[(real(kind=8)[9] *)&y2gauss]+0 S16 A256]))) ../induct2.f90:1662 1130 {*addv2df3} (Snip)