From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 3414 invoked by alias); 23 Oct 2018 22:31:03 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 3392 invoked by uid 89); 23 Oct 2018 22:31:02 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-25.6 required=5.0 tests=AWL,BAYES_00,GIT_PATCH_0,GIT_PATCH_1,GIT_PATCH_2,GIT_PATCH_3,RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=ham version=3.3.2 spammy= X-HELO: relay1.mentorg.com Received: from relay1.mentorg.com (HELO relay1.mentorg.com) (192.94.38.131) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 23 Oct 2018 22:31:00 +0000 Received: from nat-ies.mentorg.com ([192.94.31.2] helo=SVR-IES-MBX-03.mgc.mentorg.com) by relay1.mentorg.com with esmtps (TLSv1.2:ECDHE-RSA-AES256-SHA384:256) id 1gF5CU-0006LU-4D from abid_qadeer@mentor.com ; Tue, 23 Oct 2018 15:30:58 -0700 Received: from [172.30.65.184] (137.202.0.90) by SVR-IES-MBX-03.mgc.mentorg.com (139.181.222.3) with Microsoft SMTP Server (TLS) id 15.0.1320.4; Tue, 23 Oct 2018 23:30:54 +0100 Subject: Re: [1/2] C-SKY Port To: Simon Marchi CC: , References: <1b689bab-bb28-7ba9-9602-d66f0568ff28@simark.ca> <1799f181-2531-dc53-4934-6f436a2b858c@simark.ca> <9777cb488fab070bc4e1a05ce4b9fbed@simark.ca> From: Hafiz Abid Qadeer Message-ID: Date: Tue, 23 Oct 2018 22:31:00 -0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.5.0 MIME-Version: 1.0 In-Reply-To: <9777cb488fab070bc4e1a05ce4b9fbed@simark.ca> Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit X-SW-Source: 2018-10/txt/msg00529.txt.bz2 On 23/10/18 17:42, Simon Marchi wrote: > On 2018-10-23 08:48, Hafiz Abid Qadeer wrote: >>> A quick investigation shows it's because some raw registers are not >>> in the >>> save reggroup.  So csky should probably be added to that big if in >>> the test: >>> >>>       if (bfd_arch == bfd_arch_frv || bfd_arch == bfd_arch_h8300 >>>           || bfd_arch == bfd_arch_m32c || bfd_arch == bfd_arch_sh >>>           || bfd_arch == bfd_arch_alpha || bfd_arch == bfd_arch_v850 >>>           || bfd_arch == bfd_arch_msp430 || bfd_arch == bfd_arch_mep >>>           || bfd_arch == bfd_arch_mips || bfd_arch == >>> bfd_arch_v850_rh850 >>>           || bfd_arch == bfd_arch_tic6x || bfd_arch == bfd_arch_mn10300 >>>           || bfd_arch == bfd_arch_rl78 || bfd_arch == bfd_arch_score >>>           || bfd_arch == bfd_arch_riscv) >>>         { >>>           /* Raw registers.  If raw registers are not in save_reggroup, >>>          their status are unknown.  */ >>>           if (gdbarch_register_reggroup_p (gdbarch, regnum, >>> save_reggroup)) >>>         SELF_CHECK (status == REG_VALID); >>>           else >>>         SELF_CHECK (status == REG_UNKNOWN); >>>         } >>>       else >>>         SELF_CHECK (status == REG_VALID); >>> >> >> When I was reviewing the test results for csky, I saw this fail in >> unittest.exp and fixed it by adding csky to the big if list as you >> mentioned above. Somehow I missed that patch when upstreaming the port. >> So if you are happy with that change then I will push it. > > Yes please, consider it pre-approved.  We can take a look at removing > the big list laster. I pushed the following patch. gdb/ChangeLog: 2018-10-23 Hafiz Abid Qadeer * regcache.c (cooked_read_test): Add CSKY to the list of architectures with a save_reggroup -- diff --git a/gdb/regcache.c b/gdb/regcache.c index 38ad7ba3f1..946035ae67 100644 --- a/gdb/regcache.c +++ b/gdb/regcache.c @@ -1679,7 +1679,7 @@ cooked_read_test (struct gdbarch *gdbarch) || bfd_arch == bfd_arch_mips || bfd_arch == bfd_arch_v850_rh850 || bfd_arch == bfd_arch_tic6x || bfd_arch == bfd_arch_mn10300 || bfd_arch == bfd_arch_rl78 || bfd_arch == bfd_arch_score - || bfd_arch == bfd_arch_riscv) + || bfd_arch == bfd_arch_riscv || bfd_arch == bfd_arch_csky) { /* Raw registers. If raw registers are not in save_reggroup, their status are unknown. */ Thanks, -- Hafiz Abid Qadeer Mentor Embedded/CodeSourcery