From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 33474 invoked by alias); 14 Jun 2018 11:06:31 -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 33463 invoked by uid 89); 14 Jun 2018 11:06:31 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.8 required=5.0 tests=AWL,BAYES_00,SPF_HELO_PASS autolearn=ham version=3.3.2 spammy= X-HELO: mx1.redhat.com Received: from mx3-rdu2.redhat.com (HELO mx1.redhat.com) (66.187.233.73) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 14 Jun 2018 11:06:30 +0000 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.rdu2.redhat.com [10.11.54.4]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id D38A2401EF39; Thu, 14 Jun 2018 11:06:28 +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 BFD9B2026DEF; Thu, 14 Jun 2018 11:06:27 +0000 (UTC) Subject: Re: [RFA 00/10] Remove standalone ptid functions To: Simon Marchi , Joel Brobecker References: <20180613215049.9691-1-tom@tromey.com> <20180613232228.GA2166@adacore.com> <49903166aff66528df83fbda26001be8@polymtl.ca> Cc: Tom Tromey , gdb-patches@sourceware.org From: Pedro Alves Message-ID: <64e82c8f-9647-2fb9-62f7-0b31660a41c6@redhat.com> Date: Thu, 14 Jun 2018 11:06:00 -0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.8.0 MIME-Version: 1.0 In-Reply-To: <49903166aff66528df83fbda26001be8@polymtl.ca> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-SW-Source: 2018-06/txt/msg00355.txt.bz2 On 06/14/2018 03:04 AM, Simon Marchi wrote: > On 2018-06-13 19:22, Joel Brobecker wrote: >>> This series removes the remaining standalone ptid functions in favor >>> of using methods on ptid_t. >>> >>> These patches were largely created by running a script. >> >> Looks like a very nice cleanup. I scanned through some of the patches, >> but not being the C++ expert in the group, I only did it out of >> curiosity for now. It looks fairly mechanical, as hinted by the fact >> that Tom said it was created by running a script. >> >> Anyone against the idea behind the change itself? Otherwise, I'd be >> inclined to allow Tom to self-review on that one. >> >> Thanks Tom! > > Yay, thanks Tom, I did not have the courage to do that!  I was just waiting for Pedro to eliminate ptid_t completely with his multi-target work :). I won't eliminate it completely. :-) > I sampled a few files, and it LGTM.  I also built the cross-compiled Linux configurations I have, and it went fine.  If there's a compilation failure resulting from this, it should be very easy to fix. I'm fine with this. I'm just not so sure about eliminating pid_to_ptid. I'd ran into uses of that where I had second thoughts on whether replacing it with a ptid_t ctor call is really a good idea. What I thought was, that when you're reading the code, a pid_to_ptid call more clearly shows that want to build a process-wide (sometimes a filter) ptid as opposed to a single thread ptid. It also helps with grepping, if you'd like to find such spots. But it's not a big deal, and I can certainly live with it. Thanks, Pedro Alves