From: Pedro Franco de Carvalho via Gdb-patches <gdb-patches@sourceware.org>
To: cel@us.ibm.com, gdb-patches@sourceware.org
Cc: ulrich.weigand@de.ibm.com, tom@tromey.com
Subject: Re: [PATCH] kill all threadapply processes at end of test
Date: Tue, 18 May 2021 18:56:38 -0300 [thread overview]
Message-ID: <87cztn7lk9.fsf@linux.ibm.com> (raw)
In-Reply-To: <74a4549303369eda07c3488ad0bf9dcfef9e00bc.camel@us.ibm.com>
Hello,
I didn't review the patch in detail, but one concern is that this could
cause a pid recycling issue. After expect gets the pid from the stopped
inferior, and the gdb under expect detaches from the inferior, it could
happen that the inferior finishes, there's lots and lots of processes in
the test system, and that same pid might get reused for a completely
different process, which GDB would attach to and kill, assuming it has
ptrace privileges over it. This might be unlikely, but it would be bad
for the testsuite to kill a random process in the system. I'm not sure
if there's an easy and portable solution to this.
Apart from that, it might be simpler to do the attaching and killing
inside proc thr_apply_detach.
Thanks,
Pedro Franco de Carvalho
next prev parent reply other threads:[~2021-05-18 21:57 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-05-12 16:36 Carl Love via Gdb-patches
2021-05-13 14:30 ` Simon Marchi via Gdb-patches
2021-05-13 15:44 ` Tom Tromey
2021-05-13 18:10 ` Carl Love via Gdb-patches
2021-05-18 15:29 ` Carl Love via Gdb-patches
2021-05-18 21:56 ` Pedro Franco de Carvalho via Gdb-patches [this message]
2021-05-19 0:11 ` Pedro Franco de Carvalho via Gdb-patches
2021-05-20 15:42 ` Carl Love via Gdb-patches
2021-05-20 16:01 ` Carl Love via Gdb-patches
2021-05-24 15:30 ` Carl Love via Gdb-patches
2021-05-29 1:48 ` Simon Marchi via Gdb-patches
2021-06-01 15:42 ` Carl Love via Gdb-patches
2021-06-01 16:08 ` Simon Marchi via Gdb-patches
2021-06-02 15:08 ` Carl Love via Gdb-patches
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=87cztn7lk9.fsf@linux.ibm.com \
--to=gdb-patches@sourceware.org \
--cc=cel@us.ibm.com \
--cc=pedromfc@linux.ibm.com \
--cc=tom@tromey.com \
--cc=ulrich.weigand@de.ibm.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