From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 3631 invoked by alias); 22 Nov 2018 16:28:02 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 3603 invoked by uid 89); 22 Nov 2018 16:28:01 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-0.9 required=5.0 tests=BAYES_00,KAM_LAZY_DOMAIN_SECURITY,SPF_HELO_PASS autolearn=no version=3.3.2 spammy= X-HELO: mx1.redhat.com Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 22 Nov 2018 16:28:00 +0000 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 5560A85546 for ; Thu, 22 Nov 2018 16:27:59 +0000 (UTC) Received: from [127.0.0.1] (ovpn04.gateway.prod.ext.ams2.redhat.com [10.39.146.4]) by smtp.corp.redhat.com (Postfix) with ESMTP id E3A3910002B9 for ; Thu, 22 Nov 2018 16:27:58 +0000 (UTC) Subject: Re: [PATCH 0/3] Per-inferior thread list, multi-target prep To: GDB Patches References: <20181001103252.5150-1-palves@redhat.com> From: Pedro Alves Message-ID: Date: Thu, 22 Nov 2018 16:28:00 -0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 In-Reply-To: <20181001103252.5150-1-palves@redhat.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-SW-Source: 2018-11/txt/msg00370.txt.bz2 On 10/01/2018 11:32 AM, Pedro Alves wrote: > Here's another chunk split out from my multi-target branch (on > github). (It's the chunk that I mentioned would be next at the > Cauldron's multi-core BoF.) > > Patch #3 is the real deal. See its commit log for the full > description, but the gist is that it makes each inferior have its own > thread list, and replaces the ALL_THREADS / ALL_NON_EXITED_THREADS / > ALL_INFERIORS macros with (C++20-like) ranges and iterators, such that > you can instead naturaly iterate over threads/inferiors using > range-for, like e.g,.: > > // all threads, including THREAD_EXITED threads. > for (thread_info *tp : all_threads ()) > { .... } > > // all non-exited threads. > for (thread_info *tp : all_non_exited_threads ()) > { .... } > > // all non-exited threads of INF inferior. > for (thread_info *tp : inf->non_exited_threads ()) > { .... } > > Patches #1 and #2 fix latent problems exposed by patch #3. > > Pedro Alves (3): > Avoid find_thread_ptid with null_ptid > Fix follow_exec latent problem > Per-inferior thread list, thread ranges/iterators, down with > ALL_THREADS, etc. I've finally merged this to master. Thanks, Pedro Alves