From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id VzJzHI4wG2Rn7BYAWB0awg (envelope-from ) for ; Wed, 22 Mar 2023 12:45:02 -0400 Received: by simark.ca (Postfix, from userid 112) id 6000A1E223; Wed, 22 Mar 2023 12:45:02 -0400 (EDT) Authentication-Results: simark.ca; dkim=pass (1024-bit key; secure) header.d=sourceware.org header.i=@sourceware.org header.a=rsa-sha256 header.s=default header.b=Ih8nes50; dkim-atps=neutral X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on simark.ca X-Spam-Level: X-Spam-Status: No, score=-7.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI, RDNS_DYNAMIC,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 Received: from sourceware.org (ip-8-43-85-97.sourceware.org [8.43.85.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by simark.ca (Postfix) with ESMTPS id C58751E110 for ; Wed, 22 Mar 2023 12:45:01 -0400 (EDT) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 691E73858C1F for ; Wed, 22 Mar 2023 16:45:01 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 691E73858C1F DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1679503501; bh=8y398sAf2kTuv3hhHTjOyVlO8L4oNVMmVOFTtXq3zuk=; h=Date:To:Cc:In-Reply-To:Subject:References:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From:Reply-To:From; b=Ih8nes50v6uDq4zJ7Fk2v0hODDEEdqrfJ1oXvPkGUxdXvsA0f56LP/IHE5V+Fu/4p /mD8Xp50pxRLISYqgty6gteBdhLmeFrYxa0ayIk0X+AUDd1WAWF2ZDxeOrDwXfZnu8 4o5w+etkm+s58zIIQdtWz1IjfcZajeIGkId0yE8g= Received: from eggs.gnu.org (eggs.gnu.org [IPv6:2001:470:142:3::10]) by sourceware.org (Postfix) with ESMTPS id F3FFD3858D3C for ; Wed, 22 Mar 2023 16:44:42 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org F3FFD3858D3C Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pf1Zo-00014v-Lb; Wed, 22 Mar 2023 12:44:40 -0400 Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pf1Zn-0000tK-B9; Wed, 22 Mar 2023 12:44:39 -0400 Date: Wed, 22 Mar 2023 18:44:53 +0200 Message-Id: <83o7ok68hm.fsf@gnu.org> To: Lancelot SIX Cc: gdb-patches@sourceware.org, lsix@lancelotsix.com In-Reply-To: <20230322163504.560986-4-lancelot.six@amd.com> (message from Lancelot SIX via Gdb-patches on Wed, 22 Mar 2023 16:35:04 +0000) Subject: Re: [PATCH v6 3/3] gdb/gcore: interrupt all threads to generate core in non-stop targets References: <2daa1736-57cb-3c5a-f1cd-48f5aa03d010@simark.ca> <20230322163504.560986-1-lancelot.six@amd.com> <20230322163504.560986-4-lancelot.six@amd.com> 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: , From: Eli Zaretskii via Gdb-patches Reply-To: Eli Zaretskii Errors-To: gdb-patches-bounces+public-inbox=simark.ca@sourceware.org Sender: "Gdb-patches" > CC: , Lancelot SIX > Date: Wed, 22 Mar 2023 16:35:04 +0000 > From: Lancelot SIX via Gdb-patches > > diff --git a/gdb/NEWS b/gdb/NEWS > index cc262f1f8a6..65ac722bd2e 100644 > --- a/gdb/NEWS > +++ b/gdb/NEWS > @@ -91,6 +91,14 @@ show always-read-ctf > $2 = 1 > (gdb) break func if $_shell("some command") == 0 > > +* Changed commands > + > +gcore > +generate-core-file > + For non-stop targets, GDB ensures that all threads are stopped before > + generating a core dump. At the end of the command, threads are restored > + to their previous state. > + > * MI changes This part is OK. > --- a/gdb/doc/gdb.texinfo > +++ b/gdb/doc/gdb.texinfo > @@ -13763,6 +13763,11 @@ Produce a core dump of the inferior process. The optional argument > specified, the file name defaults to @file{core.@var{pid}}, where > @var{pid} is the inferior process ID. > > +If the current inferior's target is non-stop, @value{GDBN} ensures that Please add a cross-reference after "non-stop" to where we describe that mode. Thanks. Reviewed-By: Eli Zaretskii