From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm1-f41.google.com (mail-wm1-f41.google.com [209.85.128.41]) by sourceware.org (Postfix) with ESMTPS id 64F2D3858410 for ; Wed, 8 Feb 2023 18:10:43 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 64F2D3858410 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=palves.net Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-wm1-f41.google.com with SMTP id u10so10879273wmj.3 for ; Wed, 08 Feb 2023 10:10:43 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:content-language:in-reply-to:mime-version :user-agent:date:message-id:from:references:to:subject :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=6TtWTsPXJ88xwVNakBQU1o/AhTwDjzFxZ4QYMEyB78c=; b=l89F1EjNXAl50id4K8zCfmX0CKUk/RoMJA8cHsWw3lYkHy2QgmTcGLs8CehaDr+AWv BgvlxdR+tRR9o2ibyUb5wm/iUsR0+In1mq2fab0BdROK13v6O6kf6Jl4oVD/P3jbfLB6 cBCN2GWLOyo8axoYOj8lVAZmDHFtkUCeLaFMcw4gNthfw6RrnhjsOP2iwhc3YVMUcoZf 4NrK4EBtinKKJijjt7aK7IS0R5UiVLbdRpDAnUfGXTRncvM7hIpg+9AqtAWNlOqDcpv0 Pcj8MiaspCUYHH6oLU7x9aiVKoG3UNNQv9YGUJscWrNu4Ke7fN4CVl/pl2aomTO/hG8a 28sg== X-Gm-Message-State: AO0yUKV+yhbYfdpAP7IFwkDtjzzfUFDIY7VnF6IsYEw78JD1sDCLHtmB HCQvi81aes/XHei60+ucZqP+p77Fm6P36A== X-Google-Smtp-Source: AK7set+VQxXmYSwt5GftXTfpRl4SxtGtGJT/W0lWWxlf10e4pnBy6wr6AxVsm9tYfBR9SAhmT/V9FQ== X-Received: by 2002:a05:600c:3416:b0:3df:50eb:7ca6 with SMTP id y22-20020a05600c341600b003df50eb7ca6mr7563575wmp.15.1675879842149; Wed, 08 Feb 2023 10:10:42 -0800 (PST) Received: from ?IPv6:2001:8a0:f92b:9e00::1fe? ([2001:8a0:f92b:9e00::1fe]) by smtp.gmail.com with ESMTPSA id m13-20020a05600c4f4d00b003db06224953sm2729633wmq.41.2023.02.08.10.10.41 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 08 Feb 2023 10:10:41 -0800 (PST) Subject: Re: [PATCH 2/2] gdb: use -1 for breakpoint::task default value To: Andrew Burgess , gdb-patches@sourceware.org References: <6ab8502906e90c53dbb2a758f2e02acab05da4ee.1675869267.git.aburgess@redhat.com> From: Pedro Alves Message-ID: <0aec159e-085d-5e4b-636f-c46c287d2ddb@palves.net> Date: Wed, 8 Feb 2023 18:10:40 +0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.10.1 MIME-Version: 1.0 In-Reply-To: <6ab8502906e90c53dbb2a758f2e02acab05da4ee.1675869267.git.aburgess@redhat.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-4.7 required=5.0 tests=BAYES_00,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM,HEADER_FROM_DIFFERENT_DOMAINS,KAM_DMARC_STATUS,NICE_REPLY_A,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: On 2023-02-08 3:16 p.m., Andrew Burgess via Gdb-patches wrote: > Within the breakpoint struct we have two fields ::thread and ::task > which are used for thread or task specific breakpoints. When a > breakpoint doesn't have a specific thread or task then these fields > have the values -1 and 0 respectively. > > There's no particular reason (as far as I can tell) why these two > "default" values are different, and I find the difference a little > confusing. Long term I'd like to potentially fold these two fields > into a single field, but that isn't what this commit does. > > What this commit does is switch to using -1 as the "default" value for > both fields, this means that the default for breakpoint::task has > changed from 0 to -1. I've updated all the code I can find that > relied on the value of 0, and I see no test regressions, especially in > gdb.ada/tasks.exp, which still fully passes. > > There should be no user visible changes after this commit. This bothered me before as well. Thanks for doing this. Approved-By: Pedro Alves