Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Pedro Alves <palves@redhat.com>
To: Simon Marchi <simon.marchi@efficios.com>, gdb-patches@sourceware.org
Subject: Re: [PATCH 2/2] gdb: make gdbarch_displaced_step_copy_insn return an std::unique_ptr
Date: Fri, 14 Feb 2020 19:47:00 -0000	[thread overview]
Message-ID: <a7db9528-4595-da48-96e5-c1707d8fe1f3@redhat.com> (raw)
In-Reply-To: <20200122151410.30012-2-simon.marchi@efficios.com>

On 1/22/20 3:14 PM, Simon Marchi wrote:
> This callback dynamically allocates a specialized displaced_step_closure, and
> gives the ownership of the object to its caller.  So I think it would make
> sense for the callback to return an std::unique_ptr, this is what this patch
> implements.
> 
>         * gdbarch.sh (displaced_step_copy_insn): Change return type to an
> 	std::unique_ptr.
>         * gdbarch.c: Re-generate.
>         * gdbarch.h: Re-generate.
>         * infrun.c (displaced_step_prepare_throw): Adjust to std::unique_ptr
> 	change.
>         * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Change return
> 	type to std::unique_ptr.
>         * aarch64-tdep.h (aarch64_displaced_step_copy_insn): Likewise.
>         * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
>         * amd64-tdep.h (amd64_displaced_step_copy_insn): Likewise.
>         * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn): Likewise.
>         * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn): Likewise.
>         * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
>         * i386-tdep.h (i386_displaced_step_copy_insn): Likewise.
>         * rs6000-tdep.c (ppc_displaced_step_copy_insn): Likewise.
>         * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.

Looks fine.

Thanks,
Pedro Alves


  reply	other threads:[~2020-02-14 19:47 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-01-22 15:14 [PATCH 1/2] gdb: cleanup of displaced_step_inferior_state::reset/displaced_step_clear Simon Marchi
2020-01-22 15:20 ` [PATCH 2/2] gdb: make gdbarch_displaced_step_copy_insn return an std::unique_ptr Simon Marchi
2020-02-14 19:47   ` Pedro Alves [this message]
2020-02-14 19:48     ` Pedro Alves
2020-02-14 20:31       ` Simon Marchi
2020-02-13 22:52 ` [PATCH 1/2] gdb: cleanup of displaced_step_inferior_state::reset/displaced_step_clear Simon Marchi
2020-02-14 19:39 ` Pedro Alves
2020-02-14 20:11   ` Simon Marchi

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=a7db9528-4595-da48-96e5-c1707d8fe1f3@redhat.com \
    --to=palves@redhat.com \
    --cc=gdb-patches@sourceware.org \
    --cc=simon.marchi@efficios.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