From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id hbJNHR/2hGGIFAAAWB0awg (envelope-from ) for ; Fri, 05 Nov 2021 05:15:11 -0400 Received: by simark.ca (Postfix, from userid 112) id 6659F1F40C; Fri, 5 Nov 2021 05:15:11 -0400 (EDT) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on simark.ca X-Spam-Level: X-Spam-Status: No, score=-0.7 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,MAILING_LIST_MULTI,RDNS_DYNAMIC,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.2 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 817C71F0B9 for ; Fri, 5 Nov 2021 05:15:10 -0400 (EDT) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 525C03857C74 for ; Fri, 5 Nov 2021 09:15:09 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 525C03857C74 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1636103709; bh=k6LTfuCSA40723nwDUBalj0G+sq3M/ZHmrxz2Ovt3sA=; h=To:References:Subject:Date:In-Reply-To:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To: From; b=m8wVJi7UvbwY2GTl1YwzNUF2tm1F3T3sXc9m17f6D2Gk3+r+/NGUDUWHzZNyGUKnL dYAfovxo1xK2k53FpoyV8Jv8Kw5CUqZyBFZUeejC0yUZNhDZQoRznEIJCtY23lRlFs cPxI/WORV/gyyqUgSRJSVqPbYs2aaJ7+zebsFiV0= Received: from eggs.gnu.org (eggs.gnu.org [IPv6:2001:470:142:3::10]) by sourceware.org (Postfix) with ESMTPS id 63A633858D35 for ; Fri, 5 Nov 2021 09:14:43 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 63A633858D35 Received: from fencepost.gnu.org ([2001:470:142:3::e]:49426) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mivJ4-0004D3-U5 for gdb@sourceware.org; Fri, 05 Nov 2021 05:14:42 -0400 Received: from ip5f5a8d68.dynamic.kabel-deutschland.de ([95.90.141.104]:64274 helo=[192.168.111.41]) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mivJ4-0008AL-Jo for gdb@sourceware.org; Fri, 05 Nov 2021 05:14:42 -0400 To: gdb@sourceware.org References: <60c53fa8bf160533a2eddf1da280eb50c7461a6a.camel@fit.cvut.cz> Subject: Is there a way to know about current "until"/"advance" execution? Message-ID: <6640cbc8-38d7-5138-d28e-8fd94f486704@gnu.org> Date: Fri, 5 Nov 2021 10:14:36 +0100 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Thunderbird/78.14.0 MIME-Version: 1.0 In-Reply-To: <60c53fa8bf160533a2eddf1da280eb50c7461a6a.camel@fit.cvut.cz> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit X-BeenThere: gdb@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , From: Simon Sobisch via Gdb Reply-To: Simon Sobisch Errors-To: gdb-bounces+public-inbox=simark.ca@sourceware.org Sender: "Gdb" For a silent breakpoint the following commands are very useful break something command silent do_something continue end or the similar version in a python script using the silent attribute and continue as a command. I've recently seen a problem with this the first time - it break any active "until" break 120 command silent continue end break 140 until 123 will execute until 140 (with a function that just executes each line), while the user "intended" to go until line 123. Similar applies to "advance". The workaround as a user: instead of using "until": create a temporary maintenance breakpoint in line 123 and "continue". ... but as the break 120 in the sample above is scripted and not executed by a user this cannot be applied. Questions: * Is there a more direct way to "preserve" the running "until"/"advance" in GDB scripting or with Python? * Is there a way in Python to know about the current active "until" (so this can be re-done instead of "continue"/"until" in the above example)? * If there isn't an option for this, can you please consider this as a Feature Request for the Python API of GDB? Thanks, Simon