From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca (simark.ca [158.69.221.121]) by sourceware.org (Postfix) with ESMTPS id ADD2038582AB for ; Thu, 11 May 2023 02:08:43 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org ADD2038582AB Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=simark.ca Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=simark.ca Received: from [10.0.0.170] (unknown [167.248.160.41]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by simark.ca (Postfix) with ESMTPSA id B21311E114; Wed, 10 May 2023 22:08:42 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=simark.ca; s=mail; t=1683770923; bh=tef9Nn2LmFRnKpZFu6u1/+unnI5rwenWwr22A6dimms=; h=Date:Subject:To:References:From:In-Reply-To:From; b=FBy2Cr++IxMH1jA0IVO86GzjAXhOy4BScRJx0JtG0uGLD4i7aFQDyjESuetkY8wLF mZrFEctCVA8RTaF31GwPRutK40Z9aU0zxpa9s0yoO7Hw7tZQksIOIuVR/kfM4Pz3rK VT7Ju2JRp+MZglwkEkO9JZwVZnPlthEYEJ1r5Q3o= Message-ID: Date: Wed, 10 May 2023 22:08:42 -0400 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.10.1 Subject: Re: [PATCH v5] [PR python/29603] Disable out-of-scope watchpoints Content-Language: fr To: Johnson Sun , LancelotSIX , gdb-patches@sourceware.org References: <1b60c407-1406-ed3c-7d64-a79c786ae9b7@gmail.com> <20230423095408.7638-1-j3.soon777@gmail.com> <1b0edc1f-0783-e262-2138-6982a18ddf97@gmail.com> From: Simon Marchi In-Reply-To: <1b0edc1f-0783-e262-2138-6982a18ddf97@gmail.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-6.5 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,SPF_HELO_PASS,SPF_PASS,TXREP,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: On 5/10/23 13:22, Johnson Sun wrote: > Hi, > > I just applied the patch to commit 39453f9d8cf03b382d34f3548706f1ae5916e34e, and tested with the following commands on a clean Ubuntu 22.04 LTS machine: > > make check TESTS="gdb.python/py-watchpoint.exp" > make check TESTS="gdb.python/py-watchpoint.exp" RUNTESTFLAGS="--target_board=native-gdbserver" > make check TESTS="gdb.python/py-watchpoint.exp" RUNTESTFLAGS="--target_board=native-extended-gdbserver" > > all 3 commands above passed the tests (10/10) on my machine. > > I'm unsure why the test times out on your machine. Could you provide information regarding the base commit that was used and the operating system installed? I just retested on latest master as of now (38b95a529385). Looking at the output of "set debug infrun", it looks like the program is making progress, just that it's really slow, since GDB is single stepping all instructions due to the software watchpoint. Is the printf necessary for the test? If not, we can remove it. If the loop executes just a few instructions, the program should execute relatively quickly, even if single stepping all the way through. Simon