From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from eggs.gnu.org (eggs.gnu.org [IPv6:2001:470:142:3::10]) by sourceware.org (Postfix) with ESMTPS id DB3DE3858428 for ; Wed, 1 Feb 2023 18:25:30 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org DB3DE3858428 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=gnu.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gnu.org 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 1pNHnW-0005z8-B7; Wed, 01 Feb 2023 13:25:30 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=QBaja6sdX531spawmEX13VQ+DenA+l7JZQn3MO+mLRM=; b=G1xxkr4UfTNW M9CrEAIZEDNS7yvJJDRGQobwisGojWwjFHBVveiwsx1tim88jHPTiwUYVcavcqi+NjY9TgeQc4Ord LlaBrynuYs8iQpkUcMkZyqHg/2yZKqM+ZXH2dKREEtkDLFbx9ae2BFcnl5QqoOzkER0aeFfhQ6xMe YEWq+Y4ZnZ92A7beFKxfuJz6b5UoTYfO/MdPGPEdGRYyuZ7bN0Nalv8IH2f+viTySoTR6uWQ6nfoW Opkh68Nihu3OV+4iKTwDHtnWSGFgcgCXm64tlfcZO3syD/8aQ8DdO3+JgO76LLcGUKiYsvi4ExND+ qnfFPD8G7cDQcrOXjxvDiQ==; 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 1pNHnT-0007Q3-Rf; Wed, 01 Feb 2023 13:25:29 -0500 Date: Wed, 01 Feb 2023 20:25:26 +0200 Message-Id: <83ilglz1ih.fsf@gnu.org> From: Eli Zaretskii To: Andrew Burgess Cc: gdb-patches@sourceware.org In-Reply-To: <87v8kls2ev.fsf@redhat.com> (message from Andrew Burgess on Wed, 01 Feb 2023 17:47:52 +0000) Subject: Re: [PATCHv3 02/13] gdb/doc: extend the documentation for conditional breakpoints References: <78764570698177ecf049fdab759908ca88fd7bd3.1675185990.git.aburgess@redhat.com> <83tu061stt.fsf@gnu.org> <87v8kls2ev.fsf@redhat.com> X-Spam-Status: No, score=1.9 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_BARRACUDACENTRAL,SPF_HELO_PASS,SPF_PASS,TXREP autolearn=no autolearn_force=no version=3.4.6 X-Spam-Level: * X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: > From: Andrew Burgess > Cc: gdb-patches@sourceware.org > Date: Wed, 01 Feb 2023 17:47:52 +0000 > > If a breakpoint condition calls a function in your program, then it is > possible that your program could stop for some reason while in the > called function. For example, @value{GDBN} might hit a breakpoint in > the called function, or the called function may receive a signal > (e.g.@ a @code{SIGSEGV}) as a result of some undefined behavior. If > this happens then @value{GDBN} will stop. Depending on the settings > @code{unwindonsignal} and @code{unwind-on-terminating-exception} > (@pxref{Calling,,Calling Program Functions}) @value{GDBN} may unwind > the stack back to the breakpoint location, or may leave the program at > the frame where the stop occurred. If @value{GDBN} remains in the > frame where the stop occurred then you can debug the inferior from > this point to understand why the called function failed. > > Does this address your concerns? Some. But I also think that the text should more explicitly explain that the various values of the unwind-* options are there precisely to tailor what happens to the needs of the debugging session. The text is now written as purely descriptional: if you set the option this way, what will happen is so-and-so. It would be better, I think, to turn the table and say: if you want to debug the called function when this happen, set the option to this value; OTOH if you want ignore that and continue debugging the inferior, set the option to that other value. Does this make sense?