public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
From: Tom Tromey <tom@tromey.com>
To: Denis Revunov via Gdb-patches <gdb-patches@sourceware.org>
Cc: Denis Revunov <rnovds@gmail.com>
Subject: Re: [RFC] [PATCH] Return intptr when dereferencing integer
Date: Thu, 27 Jul 2023 10:15:35 -0600	[thread overview]
Message-ID: <87lef1ib4o.fsf@tromey.com> (raw)
In-Reply-To: <20230726215205.3995028-1-rnovds@gmail.com> (Denis Revunov via Gdb-patches's message of "Thu, 27 Jul 2023 00:52:05 +0300")

>>>>> "Denis" == Denis Revunov via Gdb-patches <gdb-patches@sourceware.org> writes:

Denis> The code which makes default dereference type an int was intruduced in
Denis> gdb-3.4(1c997a4ae869) in 1989, 10 years before AMD64 was released. With
Denis> current adoption of 64-bit it makes sense to change default dereference
Denis> size to match the native address size, which will enable us to easily
Denis> inspect .got entries and follow chains of pointers on 64-bit systems
Denis> without excessive casting. This change won't affect 32-and-less bit
Denis> systems since intptr is the same as int there.

Does this impact any test?
If not, can a test be written for it?

I guess from context the scenario is something like: "print *23",
and here gdb acts like you typed "print *(int*)23"?

Tom

  reply	other threads:[~2023-07-27 16:15 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-07-26 21:52 Denis Revunov
2023-07-27 16:15 ` Tom Tromey [this message]
2023-07-29  0:14   ` Denis Revunov
2023-08-13 16:35     ` Revunov Denis

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=87lef1ib4o.fsf@tromey.com \
    --to=tom@tromey.com \
    --cc=gdb-patches@sourceware.org \
    --cc=rnovds@gmail.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).