* [PATCH] Enable multi-process mode in the NetBSD native target.
@ 2020-07-20 15:13 Kamil Rytarowski
2020-07-21 0:21 ` [PATCH v2] " Kamil Rytarowski
0 siblings, 1 reply; 5+ messages in thread
From: Kamil Rytarowski @ 2020-07-20 15:13 UTC (permalink / raw)
To: gdb-patches
gdb/ChangeLog:
* nbsd-nat.h (nbsd_nat_target::supports_multi_process): New
declaration.
* nbsd-nat.c (nbsd_nat_target::supports_multi_process): New
function.
---
gdb/ChangeLog | 7 +++++++
gdb/nbsd-nat.c | 8 ++++++++
gdb/nbsd-nat.h | 1 +
3 files changed, 16 insertions(+)
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 6d231f5d943..c1a62008477 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,3 +1,10 @@
+2020-07-20 Kamil Rytarowski <n54@gmx.com>
+
+ * nbsd-nat.h (nbsd_nat_target::supports_multi_process): New
+ declaration.
+ * nbsd-nat.c (nbsd_nat_target::supports_multi_process): New
+ function.
+
2020-07-18 Tom Tromey <tom@tromey.com>
* linux-nat.c (linux_multi_process): Remove.
diff --git a/gdb/nbsd-nat.c b/gdb/nbsd-nat.c
index 254a768eb37..e2725e01f68 100644
--- a/gdb/nbsd-nat.c
+++ b/gdb/nbsd-nat.c
@@ -837,3 +837,11 @@ nbsd_nat_target::set_syscall_catchpoint (int pid, bool needed,
are filtered by GDB rather than the kernel. */
return 0;
}
+
+/* Implement the "set_syscall_catchpoint" target_ops method. */
+
+bool
+nbsd_nat_target::supports_multi_process ()
+{
+ return true;
+}
diff --git a/gdb/nbsd-nat.h b/gdb/nbsd-nat.h
index 4a8b96026e6..0a7048ecf35 100644
--- a/gdb/nbsd-nat.h
+++ b/gdb/nbsd-nat.h
@@ -48,6 +48,7 @@ struct nbsd_nat_target : public inf_ptrace_target
gdb::array_view<const int> syscall_counts)
override;
+ bool supports_multi_process () override;
};
#endif /* nbsd-nat.h */
--
2.26.2
^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCH v2] Enable multi-process mode in the NetBSD native target.
2020-07-20 15:13 [PATCH] Enable multi-process mode in the NetBSD native target Kamil Rytarowski
@ 2020-07-21 0:21 ` Kamil Rytarowski
2020-07-21 2:00 ` Simon Marchi
2020-07-21 10:51 ` Pedro Alves
0 siblings, 2 replies; 5+ messages in thread
From: Kamil Rytarowski @ 2020-07-21 0:21 UTC (permalink / raw)
To: gdb-patches; +Cc: simark, Kamil Rytarowski
This enables proper support for multiple inferiors and ptrace(2)
assisted management of the inferior processes and their threads.
(gdb) info inferior
Num Description Connection Executable
* 1 process 14952 1 (native) /usr/bin/dig
2 <null> 1 (native)
3 process 25684 1 (native) /bin/ls
4 <null> 1 (native) /bin/ls
Without this patch, additional inferiors can be added, but not
properly controlled.
gdb/ChangeLog:
* nbsd-nat.h (nbsd_nat_target::supports_multi_process): New
declaration.
* nbsd-nat.c (nbsd_nat_target::supports_multi_process): New
function.
---
gdb/ChangeLog | 7 +++++++
gdb/nbsd-nat.c | 8 ++++++++
gdb/nbsd-nat.h | 1 +
3 files changed, 16 insertions(+)
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 6d231f5d943..c1a62008477 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,3 +1,10 @@
+2020-07-20 Kamil Rytarowski <n54@gmx.com>
+
+ * nbsd-nat.h (nbsd_nat_target::supports_multi_process): New
+ declaration.
+ * nbsd-nat.c (nbsd_nat_target::supports_multi_process): New
+ function.
+
2020-07-18 Tom Tromey <tom@tromey.com>
* linux-nat.c (linux_multi_process): Remove.
diff --git a/gdb/nbsd-nat.c b/gdb/nbsd-nat.c
index 254a768eb37..e2725e01f68 100644
--- a/gdb/nbsd-nat.c
+++ b/gdb/nbsd-nat.c
@@ -837,3 +837,11 @@ nbsd_nat_target::set_syscall_catchpoint (int pid, bool needed,
are filtered by GDB rather than the kernel. */
return 0;
}
+
+/* Implement the "set_syscall_catchpoint" target_ops method. */
+
+bool
+nbsd_nat_target::supports_multi_process ()
+{
+ return true;
+}
diff --git a/gdb/nbsd-nat.h b/gdb/nbsd-nat.h
index 4a8b96026e6..0a7048ecf35 100644
--- a/gdb/nbsd-nat.h
+++ b/gdb/nbsd-nat.h
@@ -48,6 +48,7 @@ struct nbsd_nat_target : public inf_ptrace_target
gdb::array_view<const int> syscall_counts)
override;
+ bool supports_multi_process () override;
};
#endif /* nbsd-nat.h */
--
2.26.2
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH v2] Enable multi-process mode in the NetBSD native target.
2020-07-21 0:21 ` [PATCH v2] " Kamil Rytarowski
@ 2020-07-21 2:00 ` Simon Marchi
2020-07-21 10:51 ` Pedro Alves
1 sibling, 0 replies; 5+ messages in thread
From: Simon Marchi @ 2020-07-21 2:00 UTC (permalink / raw)
To: Kamil Rytarowski, gdb-patches
On 2020-07-20 8:21 p.m., Kamil Rytarowski wrote:
> This enables proper support for multiple inferiors and ptrace(2)
> assisted management of the inferior processes and their threads.
>
> (gdb) info inferior
> Num Description Connection Executable
> * 1 process 14952 1 (native) /usr/bin/dig
> 2 <null> 1 (native)
> 3 process 25684 1 (native) /bin/ls
> 4 <null> 1 (native) /bin/ls
>
> Without this patch, additional inferiors can be added, but not
> properly controlled.
>
> gdb/ChangeLog:
>
> * nbsd-nat.h (nbsd_nat_target::supports_multi_process): New
> declaration.
> * nbsd-nat.c (nbsd_nat_target::supports_multi_process): New
> function.
Thanks for the commit message, this is OK.
Simon
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH v2] Enable multi-process mode in the NetBSD native target.
2020-07-21 0:21 ` [PATCH v2] " Kamil Rytarowski
2020-07-21 2:00 ` Simon Marchi
@ 2020-07-21 10:51 ` Pedro Alves
2020-07-21 12:42 ` Kamil Rytarowski
1 sibling, 1 reply; 5+ messages in thread
From: Pedro Alves @ 2020-07-21 10:51 UTC (permalink / raw)
To: Kamil Rytarowski, gdb-patches; +Cc: simark
On 7/21/20 1:21 AM, Kamil Rytarowski wrote:
> +/* Implement the "set_syscall_catchpoint" target_ops method. */
Wrong method mentioned here.
> +
> +bool
> +nbsd_nat_target::supports_multi_process ()
> +{
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH v2] Enable multi-process mode in the NetBSD native target.
2020-07-21 10:51 ` Pedro Alves
@ 2020-07-21 12:42 ` Kamil Rytarowski
0 siblings, 0 replies; 5+ messages in thread
From: Kamil Rytarowski @ 2020-07-21 12:42 UTC (permalink / raw)
To: Pedro Alves, gdb-patches; +Cc: simark
[-- Attachment #1.1: Type: text/plain, Size: 310 bytes --]
On 21.07.2020 12:51, Pedro Alves wrote:
> On 7/21/20 1:21 AM, Kamil Rytarowski wrote:
>> +/* Implement the "set_syscall_catchpoint" target_ops method. */
>
> Wrong method mentioned here.
>
Fixed and the commit was merged.
>> +
>> +bool
>> +nbsd_nat_target::supports_multi_process ()
>> +{
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2020-07-21 12:44 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-07-20 15:13 [PATCH] Enable multi-process mode in the NetBSD native target Kamil Rytarowski
2020-07-21 0:21 ` [PATCH v2] " Kamil Rytarowski
2020-07-21 2:00 ` Simon Marchi
2020-07-21 10:51 ` Pedro Alves
2020-07-21 12:42 ` Kamil Rytarowski
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).