Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Pedro Alves <palves@redhat.com>
To: Tom Tromey <tromey@redhat.com>
Cc: gdb-patches@sourceware.org
Subject: Re: [PATCH 01/22] [GDBserver] Multi-process + multi-arch: core + GNU/Linux x86*
Date: Thu, 30 May 2013 12:01:00 -0000	[thread overview]
Message-ID: <51A73F5D.9070402@redhat.com> (raw)
In-Reply-To: <87mwrdtxqa.fsf@fleche.redhat.com>

On 05/29/2013 08:03 PM, Tom Tromey wrote:
> Pedro> diff --git a/gdb/gdbserver/linux-amd64-ipa.c b/gdb/gdbserver/linux-amd64-ipa.c
> Pedro> index dc20a15..d0c40c9 100644
> Pedro> --- a/gdb/gdbserver/linux-amd64-ipa.c
> Pedro> +++ b/gdb/gdbserver/linux-amd64-ipa.c
> Pedro> @@ -23,6 +23,9 @@
> Pedro>  /* Defined in auto-generated file amd64-linux.c.  */
> Pedro>  void init_registers_amd64_linux (void);
>  
> Pedro> +/* Ditto.  */
> Pedro> +extern struct target_desc *tdesc_amd64_linux;
> 
> It seems like this (and other instances) could be const.

Good idea.

While at it, I noticed the since the globals in the generated
files, are now accessed through the target_desc globals, can/should
be made static:

-const char *expedite_regs_tilegx[] = { "sp", "lr", "pc", 0 };
-const char *xmltarget_tilegx = 0;
+static const char *expedite_regs_tilegx[] = { "sp", "lr", "pc", 0 };
+static const char *xmltarget_tilegx = 0;

I did the necessary change to regdat.sh.

> Pedro>  struct reg *
> Pedro> -find_register_by_name (const char *name)
> Pedro> +find_register_by_name (struct target_desc *tdesc, const char *name)
> 
> How about const here?
> 
> Pedro>  int
> Pedro> -find_regno (const char *name)
> Pedro> +find_regno (struct target_desc *tdesc, const char *name)
> 
> And here and other similar spots?

Yes, a bunch of other spots.  :-)

Did the adjustment now across the whole series.
Good old grep is telling I didn't miss any spot.

> Pedro> +struct target_desc
> Pedro> +{
> Pedro> +  /* An array of NUM_REGISTERS elements of register definitions that
> Pedro> +     description the inferior's register set.  */
> Pedro> +  struct reg *reg_defs;
> 
> I think it should be "...that describe...".

Indeed.  Thanks!

v3 coming up...

-- 
Pedro Alves


  reply	other threads:[~2013-05-30 12:01 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-05-29 16:24 [PATCH 00/22] [GDBserver] Multi-process + multi-arch Pedro Alves
2013-05-29 16:25 ` [PATCH 03/22] [GDBserver] Multi-process + multi-arch: GNU/Linux SPARC Pedro Alves
2013-05-29 16:25 ` [PATCH 02/22] [GDBserver] Multi-process + multi-arch: GNU/Linux IA64 Pedro Alves
2013-05-29 16:25 ` [PATCH 01/22] [GDBserver] Multi-process + multi-arch: core + GNU/Linux x86* Pedro Alves
2013-05-29 19:03   ` Tom Tromey
2013-05-30 12:01     ` Pedro Alves [this message]
2013-05-29 16:25 ` [PATCH 04/22] [GDBserver] Multi-process + multi-arch: GNU/Linux PowerPC Pedro Alves
2013-05-29 16:26 ` [PATCH 06/22] [GDBserver] Multi-process + multi-arch: GNU/Linux MIPS Pedro Alves
2013-05-29 16:26 ` [PATCH 05/22] [GDBserver] Multi-process + multi-arch: GNU/Linux S/390 Pedro Alves
2013-05-29 16:26 ` [PATCH 07/22] [GDBserver] Multi-process + multi-arch: GNU/Linux ARM Pedro Alves
2013-05-29 16:27 ` [PATCH 10/22] [GDBserver] Multi-process + multi-arch: GNU/Linux Blackfin Pedro Alves
2013-05-29 16:27 ` [PATCH 09/22] [GDBserver] Multi-process + multi-arch: GNU/Linux SH Pedro Alves
2013-05-29 16:27 ` [PATCH 11/22] [GDBserver] Multi-process + multi-arch: GNU/Linux CRIS Pedro Alves
2013-05-29 16:27 ` [PATCH 08/22] [GDBserver] Multi-process + multi-arch: GNU/Linux m68k Pedro Alves
2013-05-29 16:28 ` [PATCH 14/22] [GDBserver] Multi-process + multi-arch: GNU/Linux TI C6x Pedro Alves
2013-05-29 16:28 ` [PATCH 15/22] [GDBserver] Multi-process + multi-arch: GNU/Linux Xtensa Pedro Alves
2013-05-29 16:28 ` [PATCH 13/22] [GDBserver] Multi-process + multi-arch: GNU/Linux M32R Pedro Alves
2013-05-29 16:28 ` [PATCH 12/22] [GDBserver] Multi-process + multi-arch: GNU/Linux CRISv32 Pedro Alves
2013-05-29 16:29 ` [PATCH 16/22] [GDBserver] Multi-process + multi-arch: GNU/Linux Nios 2 Pedro Alves
2013-05-29 16:29 ` [PATCH 18/22] [GDBserver] Multi-process + multi-arch: GNU/Linux TILE-Gx Pedro Alves
2013-05-29 16:29 ` [PATCH 17/22] [GDBserver] Multi-process + multi-arch: GNU/Linux Aarch64 Pedro Alves
2013-05-29 16:30 ` [PATCH 19/22] [GDBserver] Multi-process + multi-arch: SPU Pedro Alves
2013-05-29 16:30 ` [PATCH 22/22] [GDBserver] Multi-process + multi-arch: QNX NTO Pedro Alves
2013-05-29 16:30 ` [PATCH 21/22] [GDBserver] Multi-process + multi-arch: LynxOS Pedro Alves
2013-05-29 17:22 ` [PATCH 20/22] [GDBserver] Multi-process + multi-arch: Windows Pedro Alves
2013-05-29 17:29 ` [PATCH 00/22] [GDBserver] Multi-process + multi-arch Pedro Alves
2013-05-30 12:13 [PATCH 00/22 v3] " Pedro Alves
2013-05-30 12:13 ` [PATCH 01/22] [GDBserver] Multi-process + multi-arch: core + GNU/Linux x86* Pedro Alves
2013-06-03  8:47   ` Yao Qi
2013-06-03 15:24     ` Pedro Alves

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=51A73F5D.9070402@redhat.com \
    --to=palves@redhat.com \
    --cc=gdb-patches@sourceware.org \
    --cc=tromey@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox