Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Tom Tromey <tom@tromey.com>
To: Eli Zaretskii <eliz@gnu.org>
Cc: simon.marchi@polymtl.ca,  gdb-patches@sourceware.org
Subject: Re: [PATCH v2] gdb/corelow: mark bytes unavailable when reading from unavailable mapping
Date: Wed, 04 Mar 2026 09:38:10 -0700	[thread overview]
Message-ID: <87ikbbpn2l.fsf@tromey.com> (raw)
In-Reply-To: <864imyz8r4.fsf@gnu.org> (Eli Zaretskii's message of "Mon, 02 Mar 2026 15:00:31 +0200")

>>>>> "Eli" == Eli Zaretskii <eliz@gnu.org> writes:

>> (gdb) p data
>> $1 = (int *) 0x78bf26e00000
>> (gdb) p data[5]
>> ❌️ Cannot access memory at address 0x78bf26e00014
>> 
>> After:
>> 
>> (gdb) p data
>> $1 = (int *) 0x78bf26e00000
>> (gdb) p data[5]
>> $2 = <unavailable>

Eli> I wonder whether <unavailable> is really better here.  You don't
Eli> explain why "cannot access memory" needs improvement -- can you tell
Eli> what is wrong with that?

Eli> If anything, I'd say something more specific, like "could not be read
Eli> from core file".

There is a difference between "unavailable" (nobody saved the data) and
"failed" (the pointer is bad, you have some kind of bug).  Pointing this
out when possible seems like an improvement to me.

I agree that the wording could be more precise in some cases.
At the same time I feel that's a separate issue from this patch.

thanks,
Tom

  parent reply	other threads:[~2026-03-04 16:39 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-02-28  2:20 [PATCH] " Simon Marchi
2026-03-02  3:23 ` [PATCH v2] " simon.marchi
2026-03-02 13:00   ` Eli Zaretskii
2026-03-02 15:49     ` Aktemur, Tankut Baris
2026-03-02 20:01       ` Simon Marchi
2026-03-02 19:54     ` Simon Marchi
2026-03-04 16:38     ` Tom Tromey [this message]
2026-03-04 16:36   ` Tom Tromey
2026-03-09 18:37     ` 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=87ikbbpn2l.fsf@tromey.com \
    --to=tom@tromey.com \
    --cc=eliz@gnu.org \
    --cc=gdb-patches@sourceware.org \
    --cc=simon.marchi@polymtl.ca \
    /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