From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 28610 invoked by alias); 3 Dec 2001 23:19:21 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Received: (qmail 28477 invoked from network); 3 Dec 2001 23:19:17 -0000 Received: from unknown (HELO hiauly1.hia.nrc.ca) (132.246.100.193) by sources.redhat.com with SMTP; 3 Dec 2001 23:19:17 -0000 Received: from hiauly1.hia.nrc.ca (localhost [127.0.0.1]) by hiauly1.hia.nrc.ca (8.12.0.Beta16/8.12.0.Beta16) with ESMTP id fB3NJB7c029493; Mon, 3 Dec 2001 18:19:12 -0500 (EST) Received: (from dave@localhost) by hiauly1.hia.nrc.ca (8.12.0.Beta16/8.12.0.Beta16) id fB3NJBlf029492; Mon, 3 Dec 2001 18:19:11 -0500 (EST) Message-Id: <200112032319.fB3NJBlf029492@hiauly1.hia.nrc.ca> Subject: Re: C++ pcc struct return fix To: mark@codesourcery.com (Mark Mitchell) Date: Mon, 03 Dec 2001 15:19:00 -0000 From: "John David Anglin" Cc: jason@redhat.com, gcc-patches@gcc.gnu.org In-Reply-To: <38880000.1007398006@gandalf.codesourcery.com> from "Mark Mitchell" at Dec 3, 2001 08:46:46 am X-Mailer: ELM [version 2.4 PL25] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-SW-Source: 2001-12/txt/msg00255.txt.bz2 > A test case would probably help. What about this? It's "obviously" a good test because it FAILs on hppa2.0w-hp-hpux11.11 with the current mainline. On the PA with main, struct blah function foo are missing in the assembler output for some reason. It passes on the PA with 3.0.2. Dave -- J. David Anglin dave.anglin@nrc.ca National Research Council of Canada (613) 990-0752 (FAX: 952-6605) 2001-12-03 John David Anglin * g++.dg/init/struct-ret1.C: New file. // { dg-do run } struct blah { int a[6]; }; inline struct blah foo() { struct blah r = { { 12, 24, 36, 48, 60, 72 } }; return r; } int main() { struct blah x = foo(); if (x.a[0] != 12 || x.a[1] != 24 || x.a[2] != 36 || x.a[3] != 48 || x.a[4] != 60 || x.a[5] != 72) return 1; }