From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id NVf5EneF7mBOJQAAWB0awg (envelope-from ) for ; Wed, 14 Jul 2021 02:34:31 -0400 Received: by simark.ca (Postfix, from userid 112) id 3F5081EDEE; Wed, 14 Jul 2021 02:34:31 -0400 (EDT) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on simark.ca X-Spam-Level: X-Spam-Status: No, score=-1.1 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,MAILING_LIST_MULTI,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.2 Received: from sourceware.org (server2.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 78BB21E54D for ; Wed, 14 Jul 2021 02:34:30 -0400 (EDT) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 00BC83972832 for ; Wed, 14 Jul 2021 06:34:30 +0000 (GMT) Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.220.28]) by sourceware.org (Postfix) with ESMTPS id 6D4AC3857C52 for ; Wed, 14 Jul 2021 06:34:18 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 6D4AC3857C52 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=suse.de Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=suse.de Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id 8DF9922958; Wed, 14 Jul 2021 06:34:17 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1626244457; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=UuaFdRwAKc8FhHFxiD/fDQLg3Vbnofn2doOMFn2WzE0=; b=zsyZUl3jLEuaTDZ9N6WTaVaE4pGIMoBUITJX3grvlwTLyvSdR31lUBZJHOMAzx9jWewUBl t8CVNf+W6ZjJaFyD66KIJxlgJ4p1qpvKNAtd4xihJ2N5rkj9vDGqBrPDdJ36S+tlWiOtY7 zekT0AFn7pcMxybEY/Jmi7XbOZuqVhA= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1626244457; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=UuaFdRwAKc8FhHFxiD/fDQLg3Vbnofn2doOMFn2WzE0=; b=mJziCOBfMcR+Gh/IQ75xu8iy7/mzWpJdY4gUX7PWsBMpcJsPNyzDZON2z7F9JDQ2EMYHVN q+JP0DYLQ/5f5jDg== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id 61DB913BE4; Wed, 14 Jul 2021 06:34:17 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id OT88FmmF7mBBbQAAMHmgww (envelope-from ); Wed, 14 Jul 2021 06:34:17 +0000 Subject: Re: [PATCH 03/11] gdb: make inferior_list use intrusive_list To: Pedro Alves , Simon Marchi , gdb-patches@sourceware.org References: <20210622165704.2404007-1-simon.marchi@polymtl.ca> <20210622165704.2404007-4-simon.marchi@polymtl.ca> <41c21f12-6343-e957-0769-4f3bc5b29433@palves.net> From: Tom de Vries Message-ID: <4bfa12c2-38ec-4424-689d-6476a20e7fe6@suse.de> Date: Wed, 14 Jul 2021 08:34:16 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.11.0 MIME-Version: 1.0 In-Reply-To: <41c21f12-6343-e957-0769-4f3bc5b29433@palves.net> Content-Type: text/plain; charset=utf-8 Content-Language: en-US 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: , Cc: Simon Marchi Errors-To: gdb-patches-bounces+public-inbox=simark.ca@sourceware.org Sender: "Gdb-patches" On 7/5/21 5:44 PM, Pedro Alves wrote: > On 2021-06-22 5:56 p.m., Simon Marchi wrote: >> From: Pedro Alves >> >> Change inferior_list, the global list of inferiors, to use >> intrusive_list. I think most other changes are somewhat obvious >> fallouts from this change. >> >> There is a small change in behavior in scoped_mock_context. Before this >> patch, constructing a scoped_mock_context would replace the whole >> inferior list with only the new mock inferior. Tests using two >> scoped_mock_contexts therefore needed to manually link the two inferiors >> together, as the second scoped_mock_context would bump the first mock >> inferior from the thread list. With this patch, a scoped_mock_context >> adds its mock inferior to the inferior list on construction, and removes >> it on destruction. This means that tests run with mock inferiors in the >> inferior list in addition to any pre-existing inferiors (there is always >> at least one). There is no possible pid clash problem, since each >> scoped mock inferior uses its own process target, and pids are per >> process target. > Starting this commit, I see this FAIL: ... (gdb) PASS: gdb.threads/fork-plus-threads.exp: detach-on-fork=off: no threads left info inferiors Num Description Connection Executable * 1 /home/vries/gdb_versions/devel/build/gdb/testsuite/outputs/gdb.threads/fork-plus-threads/fork-plus-threads 2 /home/vries/gdb_versions/devel/build/gdb/testsuite/outputs/gdb.threads/fork-plus-threads/fork-plus-threads 3 /home/vries/gdb_versions/devel/build/gdb/testsuite/outputs/gdb.threads/fork-plus-threads/fork-plus-threads 4 /home/vries/gdb_versions/devel/build/gdb/testsuite/outputs/gdb.threads/fork-plus-threads/fork-plus-threads 5 /home/vries/gdb_versions/devel/build/gdb/testsuite/outputs/gdb.threads/fork-plus-threads/fork-plus-threads 6 /home/vries/gdb_versions/devel/build/gdb/testsuite/outputs/gdb.threads/fork-plus-threads/fork-plus-threads 7 /home/vries/gdb_versions/devel/build/gdb/testsuite/outputs/gdb.threads/fork-plus-threads/fork-plus-threads 8 /home/vries/gdb_versions/devel/build/gdb/testsuite/outputs/gdb.threads/fork-plus-threads/fork-plus-threads 9 /home/vries/gdb_versions/devel/build/gdb/testsuite/outputs/gdb.threads/fork-plus-threads/fork-plus-threads 10 /home/vries/gdb_versions/devel/build/gdb/testsuite/outputs/gdb.threads/fork-plus-threads/fork-plus-threads 11 /home/vries/gdb_versions/devel/build/gdb/testsuite/outputs/gdb.threads/fork-plus-threads/fork-plus-threads (gdb) FAIL: gdb.threads/fork-plus-threads.exp: detach-on-fork=off: only inferior 1 left ... The test fails because it expects only inferior 1. Is this a regression? Thanks, - Tom