Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Yao Qi <qiyaoltc@gmail.com>
To: Alan Hayward <Alan.Hayward@arm.com>
Cc: "gdb-patches\@sourceware.org" <gdb-patches@sourceware.org>,
Subject: Re: [PATCH] Remove MAX_REGISTER_SIZE from remote.c
Date: Fri, 24 Feb 2017 16:14:00 -0000	[thread overview]
Message-ID: <86d1e77eh1.fsf@gmail.com> (raw)
In-Reply-To: <00284BCB-10B9-41A6-BEFA-7873F4BB3B95@arm.com> (Alan Hayward's	message of "Fri, 24 Feb 2017 10:06:42 +0000")

Alan Hayward <Alan.Hayward@arm.com> writes:

> -enum register_status
> -regcache_raw_read (struct regcache *regcache, int regnum, gdb_byte *buf)
> +void
> +regcache_raw_update (struct regcache *regcache, int regnum)
>  {
> -  gdb_assert (regcache != NULL && buf != NULL);
> -  gdb_assert (regnum >= 0 && regnum < regcache->descr->nr_raw_registers);
>    /* Make certain that the register cache is up-to-date with respect
>       to the current thread.  This switching shouldn't be necessary
>       only there is still only one target side register cache.  Sigh!
>       On the bright side, at least there is a regcache object.  */
> +
> +  gdb_assert (regcache != NULL);
> +  gdb_assert (regnum >= 0 && regnum < regcache->descr->nr_raw_registers);

Nit, any reason you move these asserts from one place to another?  It
causes one unnecessary change.  Could you change the assert in its
original place?

OK with this change.

-- 
Yao (齐尧)


      reply	other threads:[~2017-02-24 16:14 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-02-24 10:06 Alan Hayward
2017-02-24 16:14 ` Yao Qi [this message]

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=86d1e77eh1.fsf@gmail.com \
    --to=qiyaoltc@gmail.com \
    --cc=Alan.Hayward@arm.com \
    --cc=gdb-patches@sourceware.org \
    /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