From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 32184 invoked by alias); 17 Mar 2017 15:26:20 -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 32163 invoked by uid 89); 17 Mar 2017 15:26:19 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.7 required=5.0 tests=AWL,BAYES_00,KAM_LAZY_DOMAIN_SECURITY,RCVD_IN_DNSWL_NONE autolearn=no version=3.3.2 spammy=Hx-languages-length:1584, threadinfo, thread-group, H*f:sk:2b68f0b X-HELO: mail-wr0-f177.google.com Received: from mail-wr0-f177.google.com (HELO mail-wr0-f177.google.com) (209.85.128.177) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Fri, 17 Mar 2017 15:26:18 +0000 Received: by mail-wr0-f177.google.com with SMTP id g10so54235302wrg.2 for ; Fri, 17 Mar 2017 08:26:19 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:references:cc:from:message-id:date :user-agent:mime-version:in-reply-to:content-transfer-encoding; bh=Yc/v/ReVpFT37QerwyBPRIdnUIQB5Kc+8y4Iy5L0kNs=; b=DkImDY3xSEWRnP2sts+o15rwKC0gv/YBgBPxPAMCT9pMne7Hj9DUjMErViSkdYFk60 qEPRW/+0wE+XnBY40xEDxZFAcOKhl7bOyH85vRN1xu+kQGqhBrxCYG8ssc8+EYjxukX0 i0n531QKv45rpkyTak6cZGossyA4ZE2d+wB0tCNWcClQ4zcbvLo94xksMnUsAxu/msTj R/H29oPfoZhxonNkCUIpBISZs+fYRH9+5ArXAJ2ptot/hoSlXFbtBL+XXA/5KtNrpn3H +fy8JZsRfR1VsJ9apF68AWsmgNWJZ+ef/DBUht/IScg6cMDatY7z5ZaaZNltfwnP2p7w 1Cag== X-Gm-Message-State: AFeK/H331ug+v6FugJ6m4Cw2hP7zl2VCbZtbQZrs51/TdV6sE3CK3Glx4LOjEaiSDylyNR9n X-Received: by 10.223.148.193 with SMTP id 59mr12619688wrr.199.1489764377361; Fri, 17 Mar 2017 08:26:17 -0700 (PDT) Received: from [192.168.0.101] ([37.189.166.198]) by smtp.gmail.com with ESMTPSA id h76sm3006646wmd.33.2017.03.17.08.26.16 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 17 Mar 2017 08:26:16 -0700 (PDT) Subject: Re: [PATCH] Add "thread-group id" and "id in thread-group" info to -thread-info output To: Simon Marchi References: <20170119144130.4341-1-simon.marchi@ericsson.com> <7bbd57e2-f35d-88fe-8b44-4bb5dff9b60b@ericsson.com> <2b68f0be-721b-08da-079f-9c1e05ae98b7@redhat.com> <480e785582e3631a5f693080f9855d2a@polymtl.ca> Cc: Simon Marchi , gdb-patches@sourceware.org From: Pedro Alves Message-ID: Date: Fri, 17 Mar 2017 15:26:00 -0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.4.0 MIME-Version: 1.0 In-Reply-To: <480e785582e3631a5f693080f9855d2a@polymtl.ca> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit X-SW-Source: 2017-03/txt/msg00314.txt.bz2 On 02/24/2017 08:22 PM, Simon Marchi wrote: > While writing the documentation parts, these question popped to mind: > > - The type of the id-in-tg field (a string) assumes that a thread > belongs to a single group. Currently, the only kind of "thread-group" > we have is inferiors. The thread-group terminology suggests that in the > future we might have other kinds of thread groups, like user-defined > arbitrary groups. Otherwise, why would MI use "thread group" instead of > "inferior"? The concept of MI thread groups was added way before the concept of "inferiors" and inferior numbers was exposed to the user: https://sourceware.org/ml/gdb-patches/2008-11/msg00044.html Back then the thread list was global, and we were starting to add multi-process support to GDB. The OS we were targeting (from Ericsson, no less) had all processes running the same code (as if a bunch of forks), which was convenient as it allowed for incremental progress all the way until we got to real multi-inferior support a few releases later. Back then, MI thread groups mapped to "processes", and thread groups were only created when we'd attach to a process. Later on, when we added real GNU/Linux multi-inferior support (with the addition of program spaces), we exposed the "prototype inferior" concept to the user (i.e., the inferior now exists before the user types "run"), and "thread groups" were re-purposed. See: https://sourceware.org/ml/gdb-patches/2010-01/msg00358.html Thanks, Pedro Alves