From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 22946 invoked by alias); 19 Dec 2017 14:23:10 -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 22799 invoked by uid 89); 19 Dec 2017 14:23:09 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-11.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM,GIT_PATCH_2,GIT_PATCH_3,RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=ham version=3.3.2 spammy=2136, H*RU:74.125.83.67, Hx-spam-relays-external:74.125.83.67 X-HELO: mail-pg0-f67.google.com Received: from mail-pg0-f67.google.com (HELO mail-pg0-f67.google.com) (74.125.83.67) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 19 Dec 2017 14:23:08 +0000 Received: by mail-pg0-f67.google.com with SMTP id j9so10580727pgc.11 for ; Tue, 19 Dec 2017 06:23:07 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=d4KtFt13dRt9ygmj4YtLZUAMOd4/4OYs8TGFYi+BJjc=; b=f3lFP9c31rGku5RNyN/KvuQr3k91urPQ7lHDwmQ9IR17uA6rBEcHtNdNV7bTLJmVmp U8W4PVsEfPBeRgrBK3a8apsibM7CsqAuHffHqCm/fmkWg3qvV9BYRuNbFdLZqn0hW4d8 BeBVrbyrNovFNoXQOlHmgvu9M4f1uKKLtpZTc2s2ZF7u6/axaak02713RbS9s1U5VEmA HsPrQDuSjs4GkDwNuKUiMyiGJiJKQuos1ouytLUrTMm5Q6oD2eTTrUDvJn9hEXNjhn+P pfozouI4O3QYYiCQbi2o2FYZZumYDdiWCBqcNS40ShaVCzkY/iLvTkaj/+5vG2NTunMB nJHA== X-Gm-Message-State: AKGB3mJDRHpzY6n49SqCrqjszFtNEpuQuL1GNgZYT5oBr8C06I4tiaBY 5dgi+RT95SA9z5YgdBgJLlbmgmnc X-Google-Smtp-Source: ACJfBotwIuG1Iy4qSb2SXAjJlcX0dqJZmsrwC12HCi4sMYeyM4KE0uL/Uos1LMbC0lz//oeHldCi2Q== X-Received: by 10.99.110.201 with SMTP id j192mr3170692pgc.70.1513693386008; Tue, 19 Dec 2017 06:23:06 -0800 (PST) Received: from localhost (g41.219-103-184.ppp.wakwak.ne.jp. [219.103.184.41]) by smtp.gmail.com with ESMTPSA id q68sm29292818pfb.1.2017.12.19.06.23.04 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 19 Dec 2017 06:23:05 -0800 (PST) From: Stafford Horne To: GDB patches Cc: Openrisc , Stafford Horne Subject: [PATCH v3 0/4] Support for arbitrary reggroups Date: Tue, 19 Dec 2017 14:23:00 -0000 Message-Id: <20171219142257.13402-1-shorne@gmail.com> X-IsSubscribed: yes X-SW-Source: 2017-12/txt/msg00421.txt.bz2 Hello, (Its been some time since v2, but now that openrisc is upstream I can focus on this There were not many concerns raised with v2. One possible issue with v3 is that the reggroups struct uses 'char *' for strings. We now compare std::string vs 'char *' which is a bit clumsy, but I didnt think it calls for converting reggroups strings to 'std::string' yet.) Onto the change: Traditionally registers have been limited to names like "vector", "general", "system" which are hard coded in the gdbarch. This patch allows additional reggroups to be defined by the xml target description. This is necessary for architectures like OpenRISC which have many registers. This series also adds documentation on tests for the feature of listing register groups via the "info reg $reggroup" command. -Stafford -- Changes since v2 * Fixed NEWS entry XML/descriptions typo seggested by Petro * Rebased on latest upstream/master. Changes since v1 * On 'info reg $reggroup' test and docs patch - Suggested by Eli - Fix changelog - Suggested by Simon > Added help text in 'help info registers' > Fixed 'register' typos > Fixed style of test program > Fixed copyright '2017' > Fixed code styles in expect * On 'arbitrary strings' patch - Suggested by Simon > Allow for freeing reggroups - Suggested by Eli > Add documentation for this feature Stafford Horne (4): reggroups: Add test and docs for `info reg $reggroup` feature reggroups: Convert reggroups from post_init to pre_init reggroups: Create reggroup_gdbarch_new for dynamic reggroups tdesc: handle arbitrary strings in tdesc_register_in_reggroup_p gdb/NEWS | 7 ++++ gdb/doc/gdb.texinfo | 14 +++++-- gdb/infcmd.c | 8 +++- gdb/reggroups.c | 27 +++++++------ gdb/reggroups.h | 4 ++ gdb/target-descriptions.c | 74 ++++++++++++++++++------------------ gdb/testsuite/gdb.base/reggroups.c | 5 +++ gdb/testsuite/gdb.base/reggroups.exp | 63 ++++++++++++++++++++++++++++++ gdb/testsuite/gdb.xml/extra-regs.xml | 1 + gdb/testsuite/gdb.xml/tdesc-regs.exp | 3 ++ 10 files changed, 152 insertions(+), 54 deletions(-) create mode 100644 gdb/testsuite/gdb.base/reggroups.c create mode 100644 gdb/testsuite/gdb.base/reggroups.exp -- 2.13.6