Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
To: "akamath996@gmail.com" <akamath996@gmail.com>,
	"tom@tromey.com" <tom@tromey.com>,
	"simon.marchi@polymtl.ca" <simon.marchi@polymtl.ca>
Cc: "gdb-patches@sourceware.org" <gdb-patches@sourceware.org>,
	SANGAMESH MALLAYYA <sangamesh.swamy@in.ibm.com>,
	Aditya Kamath <Aditya.Kamath1@ibm.com>
Subject: Re: [PATCH v2] Remove stale pre-AIX-7.2 compatibility guards
Date: Fri, 18 Sep 2026 13:58:24 +0000	[thread overview]
Message-ID: <df08d06f08715b95252da6c298fadcadf8ca766c.camel@de.ibm.com> (raw)
In-Reply-To: <20260918103650.36233-2-akamath996@gmail.com>

Aditya Vidyadhar Kamath <akamath996@gmail.com> wrote:

>       if (data->arch64)
> 	{
>-	  if (!ptrace64aix (PTT_READ_GPRS, tid,
>+	  if (!ptraceaix (PTT_READ_GPRS, tid,
> 			    (unsigned long) gprs64, 0, NULL))
> 	    memset (gprs64, 0, sizeof (gprs64));
> 	  memcpy (context->gpr, gprs64, sizeof(gprs64));
> 	}
>       else
> 	{
>-	  if (!ptrace32 (PTT_READ_GPRS, tid, (uintptr_t) gprs32, 0,
>NULL))
>+	  if (!ptraceaix (PTT_READ_GPRS, tid, (uintptr_t) gprs32, 0,
>NULL))
> 	    memset (gprs32, 0, sizeof (gprs32));
> 	  memcpy (context->gpr, gprs32, sizeof(gprs32));

I understand this may be a pre-existing problem, but that looks
weird now.  The "gprs64" and "gprs32" structures have different
layout and size, but you use the exact same call to fill them,
and then copy them to the same destination.

It looks to me there may be some confusion between 64/32-bit
inferiors and 64/32 GDB builds here ...

Bye,
Ulrich

      reply	other threads:[~2026-09-18 14:01 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-18 10:36 Aditya Vidyadhar Kamath
2026-09-18 13:58 ` Ulrich Weigand [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=df08d06f08715b95252da6c298fadcadf8ca766c.camel@de.ibm.com \
    --to=ulrich.weigand@de.ibm.com \
    --cc=Aditya.Kamath1@ibm.com \
    --cc=akamath996@gmail.com \
    --cc=gdb-patches@sourceware.org \
    --cc=sangamesh.swamy@in.ibm.com \
    --cc=simon.marchi@polymtl.ca \
    --cc=tom@tromey.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