From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 23832 invoked by alias); 4 Feb 2011 15:50:27 -0000 Received: (qmail 23804 invoked by uid 22791); 4 Feb 2011 15:50:25 -0000 X-SWARE-Spam-Status: No, hits=-2.7 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,RCVD_IN_DNSWL_LOW,SPF_HELO_PASS,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from smtp-out.google.com (HELO smtp-out.google.com) (74.125.121.67) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Fri, 04 Feb 2011 15:50:18 +0000 Received: from wpaz21.hot.corp.google.com (wpaz21.hot.corp.google.com [172.24.198.85]) by smtp-out.google.com with ESMTP id p14FoFcR019237 for ; Fri, 4 Feb 2011 07:50:15 -0800 Received: from pwi10 (pwi10.prod.google.com [10.241.219.10]) by wpaz21.hot.corp.google.com with ESMTP id p14FoC6u021103 (version=TLSv1/SSLv3 cipher=RC4-MD5 bits=128 verify=NOT) for ; Fri, 4 Feb 2011 07:50:13 -0800 Received: by pwi10 with SMTP id 10so503939pwi.13 for ; Fri, 04 Feb 2011 07:50:12 -0800 (PST) Received: by 10.142.213.18 with SMTP id l18mr11820829wfg.424.1296834612609; Fri, 04 Feb 2011 07:50:12 -0800 (PST) Received: from coign.google.com ([216.239.45.130]) by mx.google.com with ESMTPS id x18sm1146926wfa.11.2011.02.04.07.50.07 (version=TLSv1/SSLv3 cipher=RC4-MD5); Fri, 04 Feb 2011 07:50:11 -0800 (PST) From: Ian Lance Taylor To: Sumanth Gundapaneni Cc: Jeff Law , "gcc-help\@gcc.gnu.org" , "rth\@redhat.com" , "Jayant R. Sonar" Subject: Re: Internal Compiler Error in gen_rtx_SUBREG,at emit-rtl.c:776 in CR16 References: <371569CBCFB2E745B891DBB88B2DFDDD19FA64F721@KCINPUNHJCMS01.kpit.com> <371569CBCFB2E745B891DBB88B2DFDDD19FA855F2B@KCINPUNHJCMS01.kpit.com> <4D482532.5000103@redhat.com> <371569CBCFB2E745B891DBB88B2DFDDD19FAC4D8E3@KCINPUNHJCMS01.kpit.com> Date: Fri, 04 Feb 2011 15:51:00 -0000 In-Reply-To: <371569CBCFB2E745B891DBB88B2DFDDD19FAC4D8E3@KCINPUNHJCMS01.kpit.com> (Sumanth Gundapaneni's message of "Fri, 4 Feb 2011 18:17:14 +0530") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-System-Of-Record: true X-IsSubscribed: yes Mailing-List: contact gcc-help-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-help-owner@gcc.gnu.org X-SW-Source: 2011-02/txt/msg00098.txt.bz2 Sumanth Gundapaneni writes: > However below mentioned is one of the test case that I was not able to > resolve. > > struct test{ > int ia; > char ca; > float fa; > }; > > int main() > { > struct test testinst = {23, 'c', 12.34}; > > return (int) &testinst; > } > > Whenever a function returns a 32-bit address, the compiler crashes with > internal compiler error: in instantiate_virtual_regs_in_insn, at function.c:1600 Line numbers don't help since our sources are not precisely the same as your sources. In the future please show us a few lines around the point you are describing. > The rtl dump for return value "(insn 21 18 0 5 test.c:12 (use (reg/i:HI 0 r0)) -1 (nil))" > which I believe should be SImode. I don't know what the problem is but I think you should look at PROMOTE_MODE and TARGET_PROMOTE_PROTOTYPES. Ian