From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 26663 invoked by alias); 3 Sep 2008 15:38:15 -0000 Received: (qmail 26013 invoked by uid 48); 3 Sep 2008 15:36:53 -0000 Date: Wed, 03 Sep 2008 15:38:00 -0000 Message-ID: <20080903153653.26012.qmail@sourceware.org> X-Bugzilla-Reason: CC References: Subject: [Bug rtl-optimization/37296] [4.4 Regression] Bootstrap failure compiling libgcc In-Reply-To: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "vmakarov at redhat dot com" 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: 2008-09/txt/msg00369.txt.bz2 ------- Comment #25 from vmakarov at redhat dot com 2008-09-03 15:36 ------- The problem is in sorting insn chains according to their frequencies to get a better reloads for most frequently executed insns. This very simple optimization was introduced on IRA branch. Correct updating elimination offsets in reload needs original insn chain order. I see two solutions of the problem: o Restore evaluation of elimination offsets by using original order of insn chains. It means move of sorting insn chains to function calculate_needs_all_insns and process offsets there before sorting. It also needs to save elimination offsets not only at code labels (as it now) but at any BB end start. So it complicates significantly this very simple optimization and makes it even slower because we need sort insn chain on each reload iteration (not once as it now). o Just remove sorting of insn chain. I've checked the optimization impact on SPEC2000 for x86 and found it is not significant (about 0.1% improvement on SPECINT2000 which is in measurement error range and 0.02% codes size decrease on SPECFP2000). It should speed up the compiler although in reality I did not find a visible speedup. After some thinking, I've decided to stic to the 2nd solution. The patch solving the problem will follow soon. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37296