From patchwork Wed Oct 31 13:56:13 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sebastian Huber X-Patchwork-Id: 195879 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) by ozlabs.org (Postfix) with SMTP id BD57C2C01FD for ; Thu, 1 Nov 2012 00:58:02 +1100 (EST) Comment: DKIM? See http://www.dkim.org DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d=gcc.gnu.org; s=default; x=1352296683; h=Comment: DomainKey-Signature:Received:Received:Received:Received:Received: Message-ID:Date:From:User-Agent:MIME-Version:To:CC:Subject: References:In-Reply-To:Content-Type:Mailing-List:Precedence: List-Id:List-Unsubscribe:List-Archive:List-Post:List-Help:Sender: Delivered-To; bh=2+CUKfBgwzqgUgtORqW9er1O/1A=; b=d+QTwVyOGIG7RB5 YMU0jzaXD9xO7k13D1dRaeuriwWbQRE8hBuQLOdpF7AxEvcvw+qAd6ozYw+RDoYX PLemY6NSl7miFfaq71tEow9FiQSu0XdZHANkKgznsa0UXJ8FoFi+2W4cTTz49tkl cnrE5fhuUcBfVaRrerhgJtuggcpM= Comment: DomainKeys? See http://antispam.yahoo.com/domainkeys DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=default; d=gcc.gnu.org; h=Received:Received:X-SWARE-Spam-Status:X-Spam-Check-By:Received:Received:Received:Message-ID:Date:From:User-Agent:MIME-Version:To:CC:Subject:References:In-Reply-To:Content-Type:X-IsSubscribed:Mailing-List:Precedence:List-Id:List-Unsubscribe:List-Archive:List-Post:List-Help:Sender:Delivered-To; b=vtLgd9q/j649YfnxKXyqfs75tgp/Xuxyn+Qxu3SDbxNchYRdxTJci+A0OJf34y xIo6Di20wHhQB4o5IeJf0KQlCLYDqGF9QAHXoVW2i2HhpDyKmNJ+VBPHS1XKhomp HH+ar53tZ7pvOxmFZGsw3vbXabVUyMgc0GjKDnm5E+DFU=; Received: (qmail 8382 invoked by alias); 31 Oct 2012 13:56:31 -0000 Received: (qmail 8336 invoked by uid 22791); 31 Oct 2012 13:56:29 -0000 X-SWARE-Spam-Status: No, hits=0.5 required=5.0 tests=AWL, BAYES_50, FILL_THIS_FORM_SHORT, KHOP_THREADED, RDNS_DYNAMIC X-Spam-Check-By: sourceware.org Received: from host-82-135-62-35.customer.m-online.net (HELO mail.embedded-brains.de) (82.135.62.35) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 31 Oct 2012 13:56:18 +0000 Received: by mail.embedded-brains.de (Postfix, from userid 65534) id 9C7C9652C2C; Wed, 31 Oct 2012 14:56:15 +0100 (CET) Received: from [192.168.96.64] (eb0024.eb.z [192.168.96.64]) by mail.embedded-brains.de (Postfix) with ESMTP id 8E6DE652C2C; Wed, 31 Oct 2012 14:56:13 +0100 (CET) Message-ID: <50912DFD.4030503@embedded-brains.de> Date: Wed, 31 Oct 2012 14:56:13 +0100 From: Sebastian Huber User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:13.0) Gecko/20120601 Thunderbird/13.0 MIME-Version: 1.0 To: gcc-patches@gcc.gnu.org CC: Alan Modra Subject: Re: [Patch] Potential fix for PR55033 References: <5086C507.5080905@embedded-brains.de> <508A808B.1020807@embedded-brains.de> <508FDA04.6000005@embedded-brains.de> <20121031001252.GA26796@bubble.grove.modra.org> In-Reply-To: <20121031001252.GA26796@bubble.grove.modra.org> X-IsSubscribed: yes Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Hello Alan, maybe it is better to use a require effective target instead of the { target powerpc*-*-eabi* powerpc*-*-elf* powerpc*-*-linux* } patterns scattered around in the testsuite? One problem with this is that test cases for one of these will likely also work with powerpc*-*-rtems*. I want to look at the remaining 104 test cases which are marked as UNSUPPORTED for RTEMS some time in the future. Please have a look at the attached patches. On 10/31/2012 01:12 AM, Alan Modra wrote: > On Tue, Oct 30, 2012 at 02:45:40PM +0100, Sebastian Huber wrote: >> On 10/26/2012 02:22 PM, Sebastian Huber wrote: >>> Hello, >>> >>> here is a test case for PR55033. >>> >> >> Is there something wrong with this test case? It compiles well with Alan's patch. > > It looks OK to me if you replace your "gd-do compile" line with the > following two lines to avoid failures on powerpc targets that don't > support -meabi -msdata. > > /* { dg-do compile { target powerpc*-*-eabi* powerpc*-*-elf* powerpc*-*-linux* } } */ > /* { dg-require-effective-target ilp32 } */ > > From 0a8c10e6f41339c16557a76dd11a4de08244acdf Mon Sep 17 00:00:00 2001 From: Sebastian Huber Date: Tue, 23 Oct 2012 12:27:05 +0200 Subject: [PATCH 2/2] Test case for PR55033 2012-10-31 Sebastian Huber PR target/55033 * gcc.target/powerpc/pr55033.c: New. --- gcc/testsuite/gcc.target/powerpc/pr55033.c | 21 +++++++++++++++++++++ 1 files changed, 21 insertions(+), 0 deletions(-) create mode 100644 gcc/testsuite/gcc.target/powerpc/pr55033.c diff --git a/gcc/testsuite/gcc.target/powerpc/pr55033.c b/gcc/testsuite/gcc.target/powerpc/pr55033.c new file mode 100644 index 0000000..cd8abcb --- /dev/null +++ b/gcc/testsuite/gcc.target/powerpc/pr55033.c @@ -0,0 +1,21 @@ +/* { dg-do compile } */ +/* { dg-require-effective-target powerpc_eabi_ok } */ +/* { dg-options "-mcpu=8540 -msoft-float -msdata=eabi -G 8 -fno-common" } */ + +void f(void); + +struct s { + int *p; + int *q; +}; + +extern int a; + +extern const struct s c; + +const struct s c = { &a, 0 }; + +void f(void) +{ + char buf[4] = { 0, 1, 2, 3 }; +} -- 1.7.7