From: Kamil Rytarowski <n54@gmx.com>
To: Simon Marchi <simark@simark.ca>, John Baldwin <jhb@FreeBSD.org>,
gdb-patches@sourceware.org
Subject: Re: [PATCH] Implement nbsd_nat_target::thread_alive
Date: Thu, 26 Mar 2020 05:00:38 +0100 [thread overview]
Message-ID: <e225f13d-f1f4-35da-af8e-aea31801a2de@gmx.com> (raw)
In-Reply-To: <e384ddfc-1de5-1d8f-4781-4a35d758d89f@simark.ca>
On 25.03.2020 22:08, Simon Marchi wrote:
> On 2020-03-25 5:01 p.m., Kamil Rytarowski wrote:
>> On 25.03.2020 21:42, John Baldwin wrote:
>>> Given that you have nearly identical code both here and in the thread_name
>>> method in your other patch, perhaps it makes sense to have a single
>>> "gdb::unique_xmalloc_ptr <struct kinfo_lwp> fetch_kinfo_lwp(ptid_t ptid)"
>>> helper function that the other routines could share? Perhaps instead of
>>> just returning the pointer to the array of structures it could take a lamda
>>> function that is invoked on the matching 'kl' instance with the correct lwp?
>>>
>>
>> I can do it. I will submit these two patches in one go. I will also add
>> a third similar function to list threads within a process.
>>
>> Normally, I would go for PT_LWPSTATUS, but it is available since NetBSD
>>> 10 and for the time being sysctl(3) is more portable.
>
> And let me mention the same thing I've told John :). Please add a meaningful
> commit message, explaining why you do this change. It's easy to see _what_
> it does, but not _why_ you needed to do it. Does it enable some feature, does
> it fix some test case, something else? What impact does it have?
>
> Simon
>
Done in [PATCH v2] Implement basic threading support in the NetBSD target.
Please review.
prev parent reply other threads:[~2020-03-26 4:02 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-03-25 19:36 Kamil Rytarowski
2020-03-25 20:42 ` John Baldwin
2020-03-25 21:01 ` Kamil Rytarowski
2020-03-25 21:08 ` Simon Marchi
2020-03-26 4:00 ` Kamil Rytarowski [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=e225f13d-f1f4-35da-af8e-aea31801a2de@gmx.com \
--to=n54@gmx.com \
--cc=gdb-patches@sourceware.org \
--cc=jhb@FreeBSD.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