From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 91899 invoked by alias); 15 Dec 2015 10:25:57 -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 91885 invoked by uid 89); 15 Dec 2015 10:25:56 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.4 required=5.0 tests=AWL,BAYES_00,KAM_LAZY_DOMAIN_SECURITY,SPF_HELO_PASS,T_RP_MATCHES_RCVD autolearn=no version=3.3.2 X-HELO: mx1.redhat.com Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-GCM-SHA384 encrypted) ESMTPS; Tue, 15 Dec 2015 10:25:55 +0000 Received: from int-mx11.intmail.prod.int.phx2.redhat.com (int-mx11.intmail.prod.int.phx2.redhat.com [10.5.11.24]) by mx1.redhat.com (Postfix) with ESMTPS id 24DE18F511; Tue, 15 Dec 2015 10:25:54 +0000 (UTC) Received: from [127.0.0.1] (ovpn01.gateway.prod.ext.phx2.redhat.com [10.5.9.1]) by int-mx11.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id tBFAPq3x018843; Tue, 15 Dec 2015 05:25:53 -0500 Message-ID: <566FEAB0.4070008@redhat.com> Date: Tue, 15 Dec 2015 10:25:00 -0000 From: Pedro Alves User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.7.0 MIME-Version: 1.0 To: Yao Qi , Christopher Friedt CC: gdb-patches@sourceware.org Subject: Re: cortex-m xml register descriptions for m-system References: <86vb80nlac.fsf@gmail.com> In-Reply-To: <86vb80nlac.fsf@gmail.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-SW-Source: 2015-12/txt/msg00276.txt.bz2 On 12/15/2015 08:55 AM, Yao Qi wrote: > The number doesn't matter, but the name does. In the target > descriptions from openocd, the register is named as "xPSR" in > standard feature org.gnu.gdb.arm.m-profile. > > { ARMV7M_xPSR, "xPSR", 32, REG_TYPE_INT, "general", "org.gnu.gdb.arm.m-profile" }, > > however, in gdb/arm-tdep.c, gdb expects "xpsr" > > if (is_m) > valid_p &= tdesc_numbered_register (feature, tdesc_data, > ARM_PS_REGNUM, "xpsr"); > else > valid_p &= tdesc_numbered_register (feature, tdesc_data, > ARM_PS_REGNUM, "cpsr"); > > so I suspect that GDB won't accept the org.gnu.gdb.arm.m-profile feature > from openocd. > No, that's fine actually -- tdesc_numbered_register uses strcasecmp. >From https://sourceware.org/gdb/onlinedocs/gdb/Target-Description-Format.html: "The names of registers are not case sensitive for the purpose of recognizing standard features, but gdb will only display registers using the capitalization used in the description. " Thanks, Pedro Alves