From: Andreas Arnez <arnez@linux.ibm.com>
To: Simon Marchi via Gdb-patches <gdb-patches@sourceware.org>
Subject: Re: [PATCH master + 11] gdb: don't set Linux-specific displaced stepping methods in s390_gdbarch_init
Date: Wed, 07 Jul 2021 17:08:36 +0200 [thread overview]
Message-ID: <m3wnq29n63.fsf@oc0404454431.ibm.com> (raw)
In-Reply-To: <20210707125736.2829336-1-simon.marchi@polymtl.ca> (Simon Marchi via Gdb-patches's message of "Wed, 7 Jul 2021 08:57:36 -0400")
On Wed, Jul 07 2021, Simon Marchi via Gdb-patches wrote:
[...]
> The Linux-specific callback was used
> even for non-Linux system. Maybe that was on purpose, because it would
> also happen to work in some other non-Linux case, or maybe it was simply
> a mistake. I'll assume that this was a small mistake when
> s390-tdep.{h,c} where factored out of s390-linux-tdep.c, in d6e589456475
> ("s390: Split up s390-linux-tdep.c into two files").
I agree that this is probably a mistake. It didn't cause any trouble
right away, because GDB doesn't really support any other s390 OSs. One
possible additional "OS" would have been the Linux kernel runtime, but
that hasn't manifested yet.
> Fix this by removing the setting of these displaced step callbacks from
> s390_gdbarch_init. Instead, pass num_disp_step_buffers=1 to
> linux_init_abi, in s390_linux_init_abi_any. Doing so will cause
> linux_init_abi to register these same callbacks. It will also mean that
> when debugging a bare-metal s390 executable or an executable on another
> OS that GDB doesn't know about, gdbarch_displaced_step_prepare won't be
> set, so displaced stepping won't be used.
Sounds good to me, and the patch looks good as well. Thanks!
--
Andreas
next prev parent reply other threads:[~2021-07-07 15:08 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-07-07 12:57 Simon Marchi
2021-07-07 13:23 ` Simon Marchi
2021-07-07 15:08 ` Andreas Arnez [this message]
2021-07-08 14:07 ` 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=m3wnq29n63.fsf@oc0404454431.ibm.com \
--to=arnez@linux.ibm.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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).