From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail.baldwin.cx (bigwig.baldwin.cx [IPv6:2607:f138:0:13::2]) by sourceware.org (Postfix) with ESMTPS id 562CB383B82E for ; Tue, 27 Jul 2021 17:42:50 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 562CB383B82E Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=FreeBSD.org Authentication-Results: sourceware.org; spf=fail smtp.mailfrom=FreeBSD.org Received: from ralph.com (ralph.baldwin.cx [66.234.199.215]) by mail.baldwin.cx (Postfix) with ESMTPSA id D60CA1A84BC2 for ; Tue, 27 Jul 2021 13:42:48 -0400 (EDT) From: John Baldwin To: gdb-patches@sourceware.org Subject: [PATCH v2 0/5] A few fixes to OpenBSD's native target Date: Tue, 27 Jul 2021 10:41:05 -0700 Message-Id: <20210727174110.62480-1-jhb@FreeBSD.org> X-Mailer: git-send-email 2.31.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.6.4 (mail.baldwin.cx [0.0.0.0]); Tue, 27 Jul 2021 13:42:49 -0400 (EDT) X-Virus-Scanned: clamav-milter 0.103.1 at mail.baldwin.cx X-Virus-Status: Clean X-Spam-Status: No, score=-1.8 required=5.0 tests=BAYES_00, FORGED_SPF_HELO, KAM_DMARC_STATUS, KHOP_HELO_FCRDNS, SPF_HELO_PASS, SPF_SOFTFAIL, TXREP autolearn=no autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 27 Jul 2021 17:42:51 -0000 This addresses some feedback from Simon but also adds two additional patches that allow some simple fork following to mostly work for me on OpenBSD/amd64 6.9. The one remaining issue I see is that if I disable detach on fork and allow a child process to run to completion then go back and continue the parent process, the parent process is killed with a SIGHUP. I think this is probably an issue in OpenBSD's kernel though rather than GDB and I don't plan on investigating that further. John Baldwin (5): Don't compile x86 debug register support on OpenBSD. x86-bsd-nat: Only define gdb_ptrace when using debug registers. obsd-nat: Various fixes to obsd_nat_target::wait. obsd-nat: Various fixes for fork following. obsd-nat: Report both thread and PID in ::pid_to_str. gdb/configure.nat | 5 +-- gdb/obsd-nat.c | 112 +++++++++++++++------------------------------- gdb/obsd-nat.h | 2 - gdb/x86-bsd-nat.c | 16 +++---- gdb/x86-bsd-nat.h | 9 +++- 5 files changed, 53 insertions(+), 91 deletions(-) -- 2.31.1