From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8773 invoked by alias); 17 Jul 2006 01:43:27 -0000 Received: (qmail 8724 invoked by uid 48); 17 Jul 2006 01:43:15 -0000 Date: Mon, 17 Jul 2006 01:43:00 -0000 Message-ID: <20060717014315.8723.qmail@sourceware.org> X-Bugzilla-Reason: CC References: Subject: [Bug target/24036] [e500] ICE in subreg_offset_representable_p, at rtlanal.c:3143 In-Reply-To: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "dje at gcc dot gnu dot org" Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2006-07/txt/msg01212.txt.bz2 List-Id: ------- Comment #4 from dje at gcc dot gnu dot org 2006-07-17 01:43 ------- Double Complex on e500 with double GPRs fundamentally does not interact well with GCC's current design. GCC does not want to have a double placed in the same register that can contain an int if the width of the register for ints cannot span the width of the register for float. rs6000_hard_regno_nregs() can cover the e500 double case with: if (TARGET_E500_DOUBLE && FLOAT_MODE_P (mode)) return (GET_MODE_SIZE (mode) + UNITS_PER_FP_WORD - 1) / UNITS_PER_FP_WORD; which fixes the first dubreg_offset_representable_p() assert, but subreg_offset with double nregs foir regno != int nregs for same regno intends this case for "holes", e.g., XFmode spanning three 32-bit float words but four 32-bit int words. (In this example, xmode is DCmode and ymode is DFmode.) For this special case, the function overrides the default (and correct) nregs nregs_xmode = hard_regno_nregs[xregno][xmode]; with nregs_xmode_unit_int * GET_MODE_NUNITS (xmode) which is twice the number of units. However, ymode is calculated the normal way. Hilarity ensues, e.g., gcc_assert ((mode_multiple % nregs_multiple) == 0); fails. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=24036