From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 79990 invoked by alias); 31 May 2017 14:52:18 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Received: (qmail 79974 invoked by uid 89); 31 May 2017 14:52:17 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-26.4 required=5.0 tests=BAYES_00,GIT_PATCH_0,GIT_PATCH_1,GIT_PATCH_2,GIT_PATCH_3,RCVD_IN_DNSWL_NONE,RCVD_IN_SORBS_SPAM,SPF_PASS autolearn=ham version=3.3.2 spammy=HX-Received:10.28.92.135 X-HELO: mail-wm0-f53.google.com Received: from mail-wm0-f53.google.com (HELO mail-wm0-f53.google.com) (74.125.82.53) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Wed, 31 May 2017 14:52:16 +0000 Received: by mail-wm0-f53.google.com with SMTP id d127so22771759wmf.0 for ; Wed, 31 May 2017 07:52:19 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=wqP/SjuBDq9kgVZTF/YV3cG6i3DzMyg1faxKL34HN/o=; b=W8gEW/5TUvYuzBqwCIXhdZE0yKMvnoPqBpsSJylq/Ok2IvHAYJYfwrT340sUxkFcQ0 HVmWdJNHXitIhMA/UReuvt3A7zKdwjAls3HjRz/OarvvTaUvlz5lU7gC4c6q1U6WBjY0 uigUqovJ8iuJT77VpLT2M1hi2u8IpqcgeGYKAW7hJuo11kMt0PkBp5/uqgs40R0eGXVq 6jKUr0kJXC4u263/HbISVbh9hBy0gb+bvuqNzI2LecucmvdeOwELX3jIuMpRTZ3T/VCH 9uccLGqo7WV1Q2Ymqt47ueOFJTnXEip1GSYdpiG25e3la34oXUkJaVb75sfXdLfMz/A6 9OAQ== X-Gm-Message-State: AODbwcAdN3/6KonuIkVeMKnmNcGcYNNVpXBMQPOTz/a+9uVJopycWkT8 MtEuWggQdQ7j6D/2 X-Received: by 10.28.92.135 with SMTP id q129mr5887606wmb.109.1496242336849; Wed, 31 May 2017 07:52:16 -0700 (PDT) Received: from localhost (host86-164-133-102.range86-164.btcentralplus.com. [86.164.133.102]) by smtp.gmail.com with ESMTPSA id e73sm30860605wmd.1.2017.05.31.07.52.15 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 31 May 2017 07:52:15 -0700 (PDT) Date: Wed, 31 May 2017 15:10:00 -0000 From: Andrew Burgess To: Claudiu Zissulescu Cc: gcc-patches@gcc.gnu.org, Francois.Bedard@synopsys.com Subject: Re: [PATCH 3/7] [ARC] Allow r30 to be used by the reg-alloc. Message-ID: <20170531145214.GE25719@embecosm.com> References: <1495189862-20533-1-git-send-email-claziss@synopsys.com> <1495189862-20533-4-git-send-email-claziss@synopsys.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1495189862-20533-4-git-send-email-claziss@synopsys.com> X-Editor: GNU Emacs [ http://www.gnu.org/software/emacs ] User-Agent: Mutt/1.6.1 (2016-04-27) X-IsSubscribed: yes X-SW-Source: 2017-05/txt/msg02375.txt.bz2 * Claudiu Zissulescu [2017-05-19 12:30:58 +0200]: > gcc/ > 2016-12-12 Claudiu Zissulescu > > * config/arc/arc.c (arc_conditional_register_usage): Allow r30 to > be used by the reg-alloc. Looks good, thanks, Andrew > --- > gcc/config/arc/arc.c | 9 ++++++++- > gcc/config/arc/arc.h | 3 ++- > 2 files changed, 10 insertions(+), 2 deletions(-) > > diff --git a/gcc/config/arc/arc.c b/gcc/config/arc/arc.c > index fd4bf2c..ff86f6c 100644 > --- a/gcc/config/arc/arc.c > +++ b/gcc/config/arc/arc.c > @@ -1551,7 +1551,14 @@ arc_conditional_register_usage (void) > /* For ARCv2 the core register set is changed. */ > strcpy (rname29, "ilink"); > strcpy (rname30, "r30"); > - fixed_regs[30] = call_used_regs[30] = 1; > + call_used_regs[30] = 1; > + fixed_regs[30] = 0; > + > + arc_regno_reg_class[30] = WRITABLE_CORE_REGS; > + SET_HARD_REG_BIT (reg_class_contents[WRITABLE_CORE_REGS], 30); > + SET_HARD_REG_BIT (reg_class_contents[CHEAP_CORE_REGS], 30); > + SET_HARD_REG_BIT (reg_class_contents[GENERAL_REGS], 30); > + SET_HARD_REG_BIT (reg_class_contents[MPY_WRITABLE_CORE_REGS], 30); > } > > if (TARGET_MUL64_SET) > diff --git a/gcc/config/arc/arc.h b/gcc/config/arc/arc.h > index 0a4c745..fbc1195 100644 > --- a/gcc/config/arc/arc.h > +++ b/gcc/config/arc/arc.h > @@ -641,7 +641,8 @@ extern enum reg_class arc_regno_reg_class[]; > ((REGNO) < 29 || ((REGNO) == ARG_POINTER_REGNUM) || ((REGNO) == 63) \ > || ((unsigned) reg_renumber[REGNO] < 29) \ > || ((unsigned) (REGNO) == (unsigned) arc_tp_regno) \ > - || (fixed_regs[REGNO] == 0 && IN_RANGE (REGNO, 32, 59))) > + || (fixed_regs[REGNO] == 0 && IN_RANGE (REGNO, 32, 59)) \ > + || ((REGNO) == 30 && fixed_regs[REGNO] == 0)) > > #define REGNO_OK_FOR_INDEX_P(REGNO) REGNO_OK_FOR_BASE_P(REGNO) > > -- > 1.9.1 >