From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mailout12.t-online.de (mailout12.t-online.de [194.25.134.22]) by sourceware.org (Postfix) with ESMTPS id 848793857818 for ; Fri, 21 Jan 2022 13:24:16 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 848793857818 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=t-online.de Authentication-Results: sourceware.org; spf=none smtp.mailfrom=t-online.de Received: from fwd87.dcpf.telekom.de (fwd87.aul.t-online.de [10.223.144.113]) by mailout12.t-online.de (Postfix) with SMTP id 3542D45F5; Fri, 21 Jan 2022 14:24:15 +0100 (CET) Received: from [192.168.178.21] ([84.173.66.226]) by fwd87.t-online.de with (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384 encrypted) esmtp id 1nAttm-0DkRc10; Fri, 21 Jan 2022 14:24:15 +0100 Message-ID: Date: Fri, 21 Jan 2022 14:23:14 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101 Thunderbird/91.5.0 Subject: Re: GDB Debugging multiple instances of the same application and continue simultaneous To: "Metzger, Markus T" , "gdb@sourceware.org" References: <7643924b-22fa-6c97-13b7-dfeb5495ca30@t-online.de> From: Nicholas Ford In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-TOI-EXPURGATEID: 150726::1642771455-00000271-08CC78A3/0/0 CLEAN NORMAL X-TOI-MSGID: e89e4fa0-579c-4681-898d-9b474003febb X-Spam-Status: No, score=-0.8 required=5.0 tests=BAYES_00, FREEMAIL_FROM, KAM_DMARC_STATUS, KAM_LAZY_DOMAIN_SECURITY, NICE_REPLY_A, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, SPF_HELO_NONE, SPF_NONE, TXREP autolearn=no autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org 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: , X-List-Received-Date: Fri, 21 Jan 2022 13:24:22 -0000 Hello Markus, thanks for the fast response. With the command it works. Thanks :) Regards, Nicholas Am 21.01.2022 um 12:13 schrieb Metzger, Markus T: > Hello Nicholas, > > Have you tried "set schedule-multiple on"? > > Regards, > Markus. > >> -----Original Message----- >> From: Gdb On >> Behalf Of Nicholas Ford >> Sent: Friday, January 21, 2022 12:08 PM >> To: gdb@sourceware.org >> Subject: GDB Debugging multiple instances of the same application and continue >> simultaneous >> >> Hello, >> >> >> I try to debug two instances of the same application and try to make >> them continue simultaneous. I used the following sequence of commands: >> >> (gdb) set target-async on >> (gdb) set non-stop on >> (gdb) attach >> (gdb) set scheduler-locking off >> (gdb) add-inferior >> (gdb) inferior 2 >> (gdb) attach >> (gdb) set scheduler-locking off >> (gdb) b hello-world.cpp:8 >> Breakpoint 1 at 0x557a557761fd: ../hello-world.cpp:8. (2 locations) >> (gdb) continue >> >> But only the process of the current inferior is continuing. I tried it >> with the following configurations: >> >> * Setting 1 >> o OS: Windows 10 Version 2004 >> o GDB: GNU gdb (GDB) 12.0.50.20220115-git >> o Behavior: not even possible to switch back to inferior 1: Is it >> a known issue that this is not working on Windows? >> * Setting 2 >> o OS: Windows 10 Version 2004 using WSL (Ubuntu) >> o GDB: GNU gdb (Ubuntu 9.2-0ubuntu1~20.04.1) 9.2 >> o Behavior: Only the currently selected inferior is continuing >> * Setting 3 >> o OS: Ubuntu 20.04.3 LTS >> o GDB: GNU gdb (Ubuntu 9.2-0ubuntu1~20.04) 9.2 >> o Behavior: Only the currently selected inferior is continuing >> >> Can you please guide me if I got it wrong (regarding the feature of >> running multiple processes simultaneous in GDB) or this specific feature >> is not available for the given OS versions (if yes which version should >> work)? >> >> Best regards, >> Nicholas Ford > Intel Deutschland GmbH > Registered Address: Am Campeon 10, 85579 Neubiberg, Germany > Tel: +49 89 99 8853-0, www.intel.de > Managing Directors: Christin Eisenschmid, Sharon Heck, Tiffany Doon Silva > Chairperson of the Supervisory Board: Nicole Lau > Registered Office: Munich > Commercial Register: Amtsgericht Muenchen HRB 186928