From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id aI/WD8rM3mI6YBoAWB0awg (envelope-from ) for ; Mon, 25 Jul 2022 13:03:06 -0400 Received: by simark.ca (Postfix, from userid 112) id 2FBF51E9E9; Mon, 25 Jul 2022 13:03:06 -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=W3y5/WvP; 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=-3.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,NICE_REPLY_A,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 8EE431E21F for ; Mon, 25 Jul 2022 13:03:05 -0400 (EDT) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 1AF65383A34E for ; Mon, 25 Jul 2022 17:03:05 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 1AF65383A34E DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1658768585; bh=CcnJZRclmBcbRNq6pOapCrEMjAM+lQzBvmyUjayfXZY=; h=Date:Subject:To:References:In-Reply-To:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To: From; b=W3y5/WvPCbXTQ/IRWWeGbLTaT+PpRmMGvVTqdhd2QDSjmc9vqmiqAAM7F2f1eATU7 A5C9rZHadR3uYeMtK91pBDy4haTAckKzxQDEO3ozSNqTH/2EQPXkcJFCxHMv4+DWKl 9o0yXXqdXKi8gvqmHQJ3a1NVbLPJl9SJx3myqz3s= Received: from simark.ca (simark.ca [158.69.221.121]) by sourceware.org (Postfix) with ESMTPS id 50968385840F for ; Mon, 25 Jul 2022 17:02:46 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 50968385840F Received: from [10.0.0.11] (192-222-157-6.qc.cable.ebox.net [192.222.157.6]) (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 14CE31E21F; Mon, 25 Jul 2022 13:02:45 -0400 (EDT) Message-ID: <7663ddf6-82f7-5d4f-836a-e0a93daa0f2b@simark.ca> Date: Mon, 25 Jul 2022 13:02:45 -0400 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.11.0 Subject: Re: [PATCH] gdb: Fix missing first breakpoint in schedule-multiple mode Content-Language: en-US To: Ciaran Woodward , gdb-patches@sourceware.org References: <20220725162231.4473-1-ciaranwoodward@xmos.com> In-Reply-To: <20220725162231.4473-1-ciaranwoodward@xmos.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit 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: Simon Marchi via Gdb-patches Reply-To: Simon Marchi Errors-To: gdb-patches-bounces+public-inbox=simark.ca@sourceware.org Sender: "Gdb-patches" On 2022-07-25 12:22, Ciaran Woodward wrote: > Rationale/background: > When using schedule-multiple (sched_multi) in gdb, all inferiors > are set to continue when the c command is used. However, before > this patch, only the 'current' inferior would have its > control->stop_soon field cleared. This field causes certain stops > to be ignored, and is only intended for initial attach. > > By not clearing this field before continue, continuing with inferior 2 > in focus and with inferior 1 hitting the next breakpoint, would cause > gdb to ignore the breakpoint and any attempt to stop the target with > Ctrl-C following that - even though the target was already stopped. > The only fix was to quit GDB and restart. > > Solution: > With this patch, all inferiors being resumed have their > control->stop_soon fields cleared, so gdb does not ignore the > breakpoints of any inferior inadvertently. Hi Ciaran, Can you please provide some reproducing steps? Some simple test programs along with the sequence of GDB commands to use. This way, we'll be sure we look at the same problem. Simon