From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 19483 invoked by alias); 28 Jan 2015 16:14:24 -0000 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 Received: (qmail 19399 invoked by uid 48); 28 Jan 2015 16:14:18 -0000 From: "rearnsha at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug target/64774] [ARM/thumb] missed optimization: pc relative ldr used when constant can be derived from register Date: Wed, 28 Jan 2015 16:14:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: target X-Bugzilla-Version: 4.9.3 X-Bugzilla-Keywords: X-Bugzilla-Severity: minor X-Bugzilla-Who: rearnsha at gcc dot gnu.org X-Bugzilla-Status: NEW X-Bugzilla-Priority: P5 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: cf_gcctarget priority bug_status cf_reconfirmed_on everconfirmed Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2015-01/txt/msg03266.txt.bz2 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64774 Richard Earnshaw changed: What |Removed |Added ---------------------------------------------------------------------------- Target| |arm Priority|P3 |P5 Status|UNCONFIRMED |NEW Last reconfirmed| |2015-01-28 Ever confirmed|0 |1 --- Comment #1 from Richard Earnshaw --- Although the compiler tries to find some common cases, it is generally infeasible to detect all the possible permutations that exist. Furthermore, in real code generating common expressions in this way can increase register pressure and have additional impact on some optimization passes. I don't hold out much hope of this sort of problem ever being entirely fixed.