From patchwork Wed Jun 8 11:20:56 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Senthil Kumar Selvaraj X-Patchwork-Id: 632176 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]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3rPmGh5YXLz9sf9 for ; Wed, 8 Jun 2016 21:21:32 +1000 (AEST) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b=B3ff+QD/; dkim-atps=neutral DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:from :to:cc:subject:date:message-id:mime-version:content-type; q=dns; s=default; b=I40XhM6+/CZkMmipuw1TPCGqouqOSZBbz/5P5nCyfBaviZFRLB sX6EUjFwswkNH8UZL4cKC929SG6djSVnaUyhASZm1kesvIxykg6TG2znng/RJb8R +nQle8Fa7lYqXtLOf06qivQFkD17IHCe2MgsiXZ8tLkzB6e9fE3pIeTWc= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:from :to:cc:subject:date:message-id:mime-version:content-type; s= default; bh=1u6TeC9N/WKpDugYhlbqpg4P38Q=; b=B3ff+QD/Mkli1uexkA7A QZ7AJiLdi5UUjd30OaHmqbU7catmO3O4MJZpgCWR0O1lDnMosJvlCRu/atuw58l5 QXFBug96s2uCB+rWGDB83OCGUZ6gjL2gaN/qP1aStNsx3P9u0XWXtdKND1puI6H3 +CoQUgv1br7mjZ3qQDRFSzQ= Received: (qmail 23257 invoked by alias); 8 Jun 2016 11:21:25 -0000 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 Received: (qmail 23163 invoked by uid 89); 8 Jun 2016 11:21:24 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-3.3 required=5.0 tests=BAYES_00, RP_MATCHES_RCVD, SPF_PASS autolearn=ham version=3.3.2 spammy= X-HELO: eusmtp01.atmel.com Received: from eusmtp01.atmel.com (HELO eusmtp01.atmel.com) (212.144.249.242) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-SHA encrypted) ESMTPS; Wed, 08 Jun 2016 11:21:14 +0000 Received: from HNOCHT01.corp.atmel.com (10.161.30.161) by eusmtp01.atmel.com (10.161.101.30) with Microsoft SMTP Server (TLS) id 14.3.235.1; Wed, 8 Jun 2016 13:21:06 +0200 Received: from jaguar.atmel.com (10.161.30.18) by HNOCHT01.corp.atmel.com (10.161.30.161) with Microsoft SMTP Server (TLS) id 14.3.235.1; Wed, 8 Jun 2016 13:21:08 +0200 User-agent: mu4e 0.9.17; emacs 24.5.1 From: Senthil Kumar Selvaraj To: GCC Patches CC: Mike Stump , Jeff Law Subject: [Patch, avr] Fix broken stack-usage-1.c test Date: Wed, 8 Jun 2016 16:50:56 +0530 Message-ID: <87pors2ag7.fsf@atmel.com> MIME-Version: 1.0 X-IsSubscribed: yes Hi, A recent patch I submitted fixed broken -fstack-usage for the avr target, by including the size of the return address pushed to the stack (https://gcc.gnu.org/ml/gcc-patches/2016-05/msg01715.html). I forgot to send this testcase modification with that patch - here's the fix for making gcc.dg/stack-usage-1.c pass again for avr. If this is ok, could someone commit please? I don't have commit access. Regards Senthil gcc/testsuite/ChangeLog 2016-06-08 Senthil Kumar Selvaraj * gcc.dg/stack-usage-1.c (SIZE): Consider return address when setting SIZE. diff --git gcc/testsuite/gcc.dg/stack-usage-1.c gcc/testsuite/gcc.dg/stack-usage-1.c index 7864c6a..bdc5656 100644 --- gcc/testsuite/gcc.dg/stack-usage-1.c +++ gcc/testsuite/gcc.dg/stack-usage-1.c @@ -64,7 +64,11 @@ # define SIZE 240 # endif #elif defined (__AVR__) -# define SIZE 254 +#if defined (__AVR_3_BYTE_PC__ ) +# define SIZE 251 /* 256 - 2 bytes for Y - 3 bytes for return address */ +#else +# define SIZE 252 /* 256 - 2 bytes for Y - 2 bytes for return address */ +#endif #elif defined (__s390x__) # define SIZE 96 /* 256 - 160 bytes for register save area */ #elif defined (__s390__)