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 v2] Add string cache and use it in cooked index
Date: Mon, 10 Mar 2025 13:51:07 -0600 [thread overview]
Message-ID: <87frjkslzo.fsf@tromey.com> (raw)
In-Reply-To: <8c3b216e-5c62-42ce-8983-ef8e5df29bd5@simark.ca> (Simon Marchi's message of "Mon, 10 Mar 2025 15:45:56 -0400")
>>>>> "Simon" == Simon Marchi <simark@simark.ca> writes:
Simon> I was thinking that maybe this woud actually be a good use case for an
Simon> obstack, since free'ing would probably be faster than freeing the
Simon> strings individually. But we have cases where the caller passes a
Simon> unique_xmalloc_ptr, in two cases we'd need an extra copy into the
Simon> obstack.
Yeah. Maybe it would still be better, I didn't try that approach. I
tend to suspect the speed of scanning is more important than the speed
of destroying the objects but I didn't measure it or anything. Anyway
it's easily done if someone needs it.
Tom
prev parent reply other threads:[~2025-03-10 19:51 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-03-10 19:38 Tom Tromey
2025-03-10 19:45 ` Simon Marchi
2025-03-10 19:51 ` 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=87frjkslzo.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