Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Tom Tromey <tom@tromey.com>
To: Simon Marchi <simark@simark.ca>
Cc: Tom Tromey <tom@tromey.com>,  gdb-patches@sourceware.org
Subject: Re: [PATCH] Make blockvector a little more self-contained
Date: Wed, 19 Nov 2025 10:42:21 -0700	[thread overview]
Message-ID: <87jyzl9awy.fsf@tromey.com> (raw)
In-Reply-To: <86f2f3e7-15a5-4752-b2d6-4dc6ff7690a0@simark.ca> (Simon Marchi's message of "Wed, 19 Nov 2025 00:17:05 -0500")

>>>>> "Simon" == Simon Marchi <simark@simark.ca> writes:

Simon> I honestly think that this typedef could be removed, that it would be
Simon> clearer to see "std::vector<CORE_ADDR>" in the code.

I'll send a separate patch to remove it.
Some spots should be using an array view anyway IMO.

>> +  /* We only want to iterate over the local symbols, not any
>> +     symbols in included symtabs.  */
>> +  for (struct symbol *sym : multidict_symbols ())
>> +    sym->relocate (objfile, offsets);

Simon> Do you know what the comment above refers to?  What are we doing special
Simon> to avoid iterating on the symbols in included symtabs?

I do not know.  I've removed this comment.

>> +  void relocate (struct objfile *objfile, const section_offsets &offsets);

Simon> The comment says "this blockvector", looks like a copy-pasto.

Yep.

Simon> Also, a struct symbol already knows its objfile (it has an objfile()
Simon> method) if it is objfile-owned, which should be the case here.  So it
Simon> seems superfluous to pass the objfile here.  Actually, the objfile
Simon> parameter is not even used in symbol::relocate.

I removed the parameter.

I'll check this in soon.

Tom

      reply	other threads:[~2025-11-19 17:42 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-11-19  3:30 Tom Tromey
2025-11-19  5:17 ` Simon Marchi
2025-11-19 17:42   ` Tom Tromey [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=87jyzl9awy.fsf@tromey.com \
    --to=tom@tromey.com \
    --cc=gdb-patches@sourceware.org \
    --cc=simark@simark.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