You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
testsuite: avoid leftover process from gdb.rocm/gcore-after-attach
The gcore-after-attach process does start a process outside of the
debugger, attach to it, generate a core dump of the process and then
restarts GDB to load the core dump back.
The restart part is done using clean_restart, which kills GDB and
restarts a new session. Because we attached to the process, GDB is not
using the PTRACE_O_EXITKILL option, so when we kill the debugger, the
process is free to continue execution. Since the process has an
infinite loop (to make it easier to ensure GPU activity at the moment we
attach), it continues execution until runtest eventually completes and
kills it. A consequence is that the gcore-after-attach processes are
going to be present when running any test after the
gcore-after-attach.exp, which is not the intent.
This patch makes sure that no process is left over after running the
gcore-after-attach.exp testcase by explicitly killing and reaping the
process.
Bug: SWDEV-469646
Change-Id: I70c923004f70ef200ee4be825d2d4a6b48dbc123
(cherry picked from commit 851c124)
0 commit comments