From: Segher Boessenkool <segher@kernel.crashing.org>
To: Tom Tromey <tromey@adacore.com>
Cc: Alexandre Oliva <oliva@adacore.com>,
gcc-patches@gcc.gnu.org, David Edelsohn <dje.gcc@gmail.com>,
Kewen Lin <linkw@gcc.gnu.org>, Jason Merrill <jason@redhat.com>,
Cary Coutant <ccoutant@gmail.com>,
Jakub Jelinek <jakub@redhat.com>
Subject: Re: [PATCH] [rs6000] adjust return_pc debug attrs
Date: Fri, 17 Mar 2023 11:58:05 -0500 [thread overview]
Message-ID: <20230317165805.GE25951@gate.crashing.org> (raw)
In-Reply-To: <87fsa3ibhp.fsf@tromey.com>
On Fri, Mar 17, 2023 at 10:33:22AM -0600, Tom Tromey wrote:
> >>>>> "Segher" == Segher Boessenkool <segher@kernel.crashing.org> writes:
>
> Segher> Yes. On most architectures you can get multiple machine instructions of
> Segher> course (for long calls for example), but on rs6000 (with some ABIs, in
> Segher> some circumstances) we generate a nop insn after calls, so that the
> Segher> linker has a spot to insert fixup code after calls (typically to restore
> Segher> the r2 contents, but it could be anything).
>
> FWIW I sent a gdb patch to work around this bug. However, in my
> examples, I only ever saw a nop following the call instruction -- so I
> had gdb check for this.
GCC inserts just a nop in most cases, but the linker or dynamic linker
can replace it.
> Patch is here:
>
> https://sourceware.org/pipermail/gdb-patches/2023-March/197951.html
>
> ... but I suppose I should change it to drop the nop check?
>
> It would of course be better not to have to have gdb work around this
> problem.
Yup.
Segher
next prev parent reply other threads:[~2023-03-17 17:00 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-03-03 18:00 Alexandre Oliva
2023-03-13 14:30 ` Segher Boessenkool
2023-03-17 16:33 ` Tom Tromey
2023-03-17 16:58 ` Segher Boessenkool [this message]
2023-03-24 16:21 ` Tom Tromey
2023-03-23 3:06 ` Alexandre Oliva
2023-03-24 17:55 ` Segher Boessenkool
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=20230317165805.GE25951@gate.crashing.org \
--to=segher@kernel.crashing.org \
--cc=ccoutant@gmail.com \
--cc=dje.gcc@gmail.com \
--cc=gcc-patches@gcc.gnu.org \
--cc=jakub@redhat.com \
--cc=jason@redhat.com \
--cc=linkw@gcc.gnu.org \
--cc=oliva@adacore.com \
--cc=tromey@adacore.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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).